Forum Discussion

sudarshan_cheru's avatar
sudarshan_cheru
Icon for Altostratus rankAltostratus
Mar 30, 2016

how to insert client IP address in tcp profile for FTP connections

I am having only tcp profile. the application don't use http/https connections. it uses only a ftp connection port 22. But i need the client ip address to be collected at server side. i guess there is no option in tcp profile for inserting the client IP like does in http header insert in http profile. I feel irule can do the job.

 

  • Do you need SNAT for this case? if you do not need it, when VS doesn't have to SNAT, the client IP reaches to the server instead of the float IP.

     

    Otherwise, how do you expect to catch the client IP information over the FTP transport?

     

    Regards.

     

  • There is no such thing as an "X-forwarded-for" header in FTP. The only chance to retain the original client IP on the server side connection is not using SNAT.

     

    If you need to only log the original client IP (e.g. for accounting or so), you could generate a syslog entry on the f5 that contains the original client IP and forward this to your centralized management using normal syslog mechanisms.

     

  • if you do not need it, when VS doesn't have to SNAT, the client IP reaches to the server instead of the float IP.

     

    ....

     

    Should we make the default gateways of pool members the self-IP for this to work? And, add IP forwarding for misc/aux traffic - DNS/SNMP/Syslog/NTP.

  • Yes, if you do not need SNAT to be enabled and send actual client IP address to the pool members, the default gateway of pool members should be F5. Then only session will get established.

     

    Mayur