简体   繁体   中英

TPROXY - Get the accurate destination/remote IP address

Using the latest TPROXY with the Linux Kernel, how would I get the IP address of the remote/destination machine? I am assuming that the local/source endpoint is returned from accept() .

The original (before rerouting) remote destination will be in getsockname() . accept() will return the local (local enough BUT NOT an interface on the computer) source address.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM