[SOLVED] TCP fortune example didn't work properly on Centos



  • hallo,

    i tried to ran both fortuneclient and fortuneserver example on centos in different pc. when i connected fortuneclient application to fortuneclient application, i got error QAbstractSocket::NetworkError. Then, i tried to ran fortuneclient application on centos and fortuneserver application on ubuntu and everything work properly.

    is anyone know why?

    • i am using Qt 4.74 version

    thanks
    Miftah


  • Moderators

    Do you have a portfilter/firewall set up on centos?



  • yes, i have my firewall turned on. Then, i tried to turned it off and everything work properly now.

    But, i wonder is there any risk if i turned firewall off?

    thanks
    Miftah


  • Moderators

    Without a firewall everybody (depending on your setup that is "everybody in your local network" or "everybody on the internet") can connect to any open port on your machine

    If you have the firewall on, then only those ports the firewall allows through can be reached from outside your machine. That will of course stop any network services you set up on your machine from working (e.g. the fortuneserver).

    Of course you can also configure the firewall allow certain ports while blocking others.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.