sternenseemann / spacecookie

gopher library & server written in Haskell
https://sternenseemann.github.io/spacecookie/
GNU General Public License v3.0
47 stars 5 forks source link

Bind only to a link local address #13

Closed sternenseemann closed 3 years ago

sternenseemann commented 4 years ago

This behavior can already be achieved when using a systemd based setup, but we should probably support it also in a systemd-less scenario. Binding to a specified address could be how to solve it, but link local is the most important in case you want to proxy spacecookie somehow or point a TOR hidden service to it without leaking the gopher space on the regular address.

sternenseemann commented 3 years ago

This would for example eliminate the need for sandboxing/containerizing spacecookie like this for hidden service only setups: hyperrealgopher/docker-spacecookie.

sternenseemann commented 3 years ago

This is now possible using the following configuration snippet.

{
  "listen": {
    "addr": "::1",
    "port": 70
  }
}

For the library cListenAddress must be Just "::1" or similar.