[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#34617: 27.0.50; Can't bind a server process to all interfaces?
From: |
Robert Pluim |
Subject: |
bug#34617: 27.0.50; Can't bind a server process to all interfaces? |
Date: |
Fri, 22 Feb 2019 15:00:17 +0100 |
Lars Ingebrigtsen <larsi@gnus.org> writes:
> I'm looking to bind a server process to all interfaces on the machine.
> If I say:
>
> (make-network-process
> :name name
> :family 'ipv4
> :service port
> :host (system-name)
> :server t))
>
> then the process won't be listening to the localhost address, and if I
> say :host nil, it'll only be listening to the localhost address.
>
> Am I missing something, or does Emacs just not have a way to listen to
> INADDR_ANY?
>
Does :host "0.0.0.0" not work? Seems ok to me:
(setq proc (make-network-process
:name "foo"
:family 'ipv4
:service 6666
:host "0.0.0.0"
:server t))
M-x list-processes
foo -- listen -- -- Main
(network server on 0.0.0.0)
foo <127.0.0... -- open foo <127.0.0.1:63650> -- Main
(network connection to 127.0.0.1)
foo <172.26.... -- open foo <172.26.128.66:63605> -- Main
(network connection to 172.26.128.66)
foo <172.26.... -- open foo <172.26.148.3:63628> -- Main
(network connection to 172.26.148.3)
Robert
bug#34617: 27.0.50; Can't bind a server process to all interfaces?,
Robert Pluim <=