In the first computer, a network is defined with 2 addresses:
1. 192.168.10.12
2. (a virtual address) 182.0.0.1

In the second computer, a network is defined with 2 addresses:
1. 192.168.10.13
2. (a virtual address) 192.0.0.1

in the route table I added lines :
192.0.0.1 ..... (interface) 192.168.10.12
182.0.0.1 ........(interface) 192.168.10.13

I sent packets from first computer to second computer. A second computer receives socket with 192.168.10.12 source address.
I need that in the socket will be written virtual address 182.0.0.1.
How to do it?
Thanks

What is your C++ question?

commented: A thread with no question :P +10

whether it's possible to write in the socket that will send a virtual address? (182.0.0.1)

Are you trying to do this?
http://vnat-linux.sourceforge.net/

I can't install any new software in my computer (for security reasons). So may be do you have a different solution?
thanks

Quote:

What is your C++ question?

And let it say me again:
What is actually your C++ question?
It's pretty much difficult to solve a C++ problem, if we even don't know the problem :P

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.