aio-libs/aiohttp-remotes

(X-)Forwarded not compatible with AF_INET6

ameyah opened this issue · 1 comments

Hello,

The X-Forwarded and Forwarded middleware is not compatible with sockets created by AF_INET6. As per the sockets documentation, for AF_INET6 a 4-tuple is used. The current middleware only handles 2-tuple case when sockets are created by AF_INET.

Since we only require the peer_ip, we would just take the first item of the tuple returned.

0.1.2 release is out