Post by Callan ThamI have tried to specify the --port assignment in the config files for
both server and client, but the client is still using a high port to
connect to the server.
I should have explained earlier that my configuration tunnels over TCP,
and even though I have read that it is not a good idea to tunnel IP over
TCP, I need to configure it that way. Is it still possible to fix both
the client and server to use the same ports over TCP?
You're right. I always use udp and there you can bind the source port
using --port or --lport.
In tcp-client mode OpenVPN does not seem to bind the source port
regardless of these options.
I did a quick test to change line 880 in socket.c to sock->bind_local=true
instead of false. Then the initial connection is bound atleast. Didn't do
anymore testing if it accually works. This however causes openvpn to
always bind the source port regardless of the --port and --lport options,
so a better patch should be made to support both modes.
--
_____________________________________________________________
Mathias Sundman (^) ASCII Ribbon Campaign
NILINGS AB X NO HTML/RTF in e-mail
Tel: +46-(0)8-666 32 28 / \ NO Word docs in e-mail