Should listen *:443 bind to IPv4 and IPv6 ?

Maxim Dounin mdounin at mdounin.ru
Wed Jun 13 12:19:59 UTC 2018


Hello!

On Wed, Jun 13, 2018 at 11:01:09AM +0200, Ralph Seichter wrote:

> I wonder if I missed an announcement for a change in nginx behaviour
> or if some local issue is causing me problems. The configuration
> 
>   server {
>     listen *:443 ssl default_server;
>   }
> 
> used to bind to both 0.0.0.0:443 and [::]:443, but since I updated to
> nginx 1.15.0 it only binds to IPv4 but no longer to IPv6. When I add
> a second listen directive
> 
>   server {
>     listen *:443 ssl default_server;
>     listen [::]:443 ssl default_server;
>   }
> 
> the server can be reached via both IPv6 and IPv4 again. Was this a
> deliberate change?

The "listen *:443" snippet always created only IPv4 listening 
socket.  Though I think I've seen some distributions patching 
nginx to create IPv6+IPv4 sockets instead.

-- 
Maxim Dounin
http://mdounin.ru/


More information about the nginx mailing list