Search Unity

  1. Unity 2019.1 is now released.
    Dismiss Notice

Can using the IPv4 address of your computer for a server be safe?

Discussion in 'Connected Games' started by kennethcarrington2018, Nov 29, 2018.

  1. kennethcarrington2018

    kennethcarrington2018

    Joined:
    Apr 12, 2018
    Posts:
    88
    I am building a server system that uses the IPv4 address of the computer that it is running off of. Is it safe to give out the IPv4 address of your computer or should I use something else to prevent hackers from messing with my computer?

    Also what about port forwarding the server? Do I have to switch the IP to the default gateway? is that safe?
     
  2. Joe-Censored

    Joe-Censored

    Joined:
    Mar 26, 2013
    Posts:
    5,223
    If your server is behind a NAT router, why would you give out the server's internal network IP address? That would be useless to clients. Just port forward only the ports needed by the clients for your game.
     
  3. kennethcarrington2018

    kennethcarrington2018

    Joined:
    Apr 12, 2018
    Posts:
    88
    The IPv4 address would be used by LAN parties. It is for those who just want to play with people nearby.
     
  4. Joe-Censored

    Joe-Censored

    Joined:
    Mar 26, 2013
    Posts:
    5,223
    So what kind of hacking are you concerned about at LAN parties then? Why would you be doing any port forwarding or messing with your default gateway if everyone is on the same subnet? I have a feeling you don't understand what any of those terms mean.

    If you do any communication over IP with other computers on your internal LAN, you are by definition giving out your IP address. That is how the IP protocol works. If they don't have your IP address they can't talk to your computer over IP.
     
  5. kennethcarrington2018

    kennethcarrington2018

    Joined:
    Apr 12, 2018
    Posts:
    88
    The system currently uses LAN but will later be port forwardable. Sorry if I did not clarify.