#How to connect client to remote server without VPN

1 messages · Page 1 of 1 (latest)

opaque abyss
#

I have to host server side of application of my university's server and client should be on my personal machine.

My university provides OpenVPN config to connect to its server so that the server appears as if it was on my local network. I have been able to successfully to connect client and server while using this OpenVPN config.

But I wonder if there is a way to connect client to a remote server? Like if it was a real world scenario, how would client side of application connect to server without a vpn?

I have tried to do it this way:

spice vectorBOT
#

<@&987246399047479336> please have a look, thanks.

#

You can use </chatgpt:1108714622413963314> to ask ChatGPT about your question while you wait for a human to respond.

opaque abyss
#

/ChatGPT

#

/chatgpt

dark drift
#

if the client doesn't have the vpn the only way is that the server lefts open the communication ports, in a real world scenario tho, the client will need to have the vpn

pearl fog
opaque abyss
#

What does that mean "exposed publicly"?

pearl fog
#

like

opaque abyss
#

I can ping it from my pc

#

without vpn

pearl fog
#

has servers that are hosted on some ips

#

and have some open ports

#

and that means you can talk to them

pearl fog
opaque abyss
#

There is public host name that I can ping without vpn, but cannot connect to it for some reason with sockets.

And when I use vpn, I put in its local IP 192.168.10.80 in Socket's constructor and everything works fine

#

So, I cannot connect to the server with my java application without vpn

pearl fog
#

okay

#

so

opaque abyss
#

But I can ping it from console

pearl fog
#

when you connect, what port do you use?

opaque abyss
#

I picked 55123 arbitrarily

pearl fog
#

is that port exposed on your university's server

#

try pinging <ip address>:55123

opaque abyss
#

One sec

pearl fog
#

or <domain name>:55123 whatever you have

opaque abyss
#

ah

#

Says "Name or service not known"

#

So if the port I use was exposed, I would have been able to connect to this server without vpn?

pearl fog
#

yes

opaque abyss