J
Just
Hi everybody
I was wondering if it is possible to use SendTo to send a whole IP package
including header to another IP than specified in the package. Say I have a
complete package and in it the destination IP is set to 10.0.0.3, but now I
want to send the package to a server which has destination IP 10.0.0.2
The reason for this is that the server has to act as a router and find the
best route for the package, and therefore the original IP in the package
cannot be altered.
My plan was to do following.
Sock.SetSocketOption(SocketOptionName.IP, SocketOptionLevel.HeaderIncluded,
1);
Sock.sendTo( ServerEndpoint, IPpackage );
But is this possible, or do I have to do something else?
Any help would be appreciated, Thanks.
/Just
I was wondering if it is possible to use SendTo to send a whole IP package
including header to another IP than specified in the package. Say I have a
complete package and in it the destination IP is set to 10.0.0.3, but now I
want to send the package to a server which has destination IP 10.0.0.2
The reason for this is that the server has to act as a router and find the
best route for the package, and therefore the original IP in the package
cannot be altered.
My plan was to do following.
Sock.SetSocketOption(SocketOptionName.IP, SocketOptionLevel.HeaderIncluded,
1);
Sock.sendTo( ServerEndpoint, IPpackage );
But is this possible, or do I have to do something else?
Any help would be appreciated, Thanks.
/Just