1

I'm trying to set the IP_TRANSPARENT option on my socket but I'm always getting OSError: [Errno 92] Protocol not available.

Is there any way to fix this? ( I can use setsockopt to change the value of TCP_WINDOW CLAMP )

My python version is 3.6.4 and I'm working on Fedora

Akshit
  • 187
  • 9
  • This option requires super user priviledges, and that TProxy is configured. Maybe [this](https://stackoverflow.com/q/42738588/3545273) could help... – Serge Ballesta Mar 29 '18 at 12:09

1 Answers1

1

Serge Ballesta is right, although I was making another mistake. Instead of SOL_SOCKET in the setsockopt(), SOL_IP should be used.

so the command would be

setsockopt(socket.SOL_IP,socket.IP_TRANSPARENT,1)

Although, I am not sure what the difference is between SOL_IP and SOL_IPPROTO_IP (both of them allow the usage of IP_TRANSPARENT)

Akshit
  • 187
  • 9