Skip to content

Commit

Permalink
Add AF_NETLINK to set of allowed socket address families
Browse files Browse the repository at this point in the history
contrib/unbound{,_portable}.service.in:
With the changes introduced in f6a527c
it is now necessary to also allow access to the AF_NETLINK socket
address family to be able to get information from interfaces.

Without the AF_NETLINK address family the systemd service errors with:

```
error: failed to list interfaces: getifaddrs: Address family not
supported by protocol
```

Fixes NLnetLabs#350
  • Loading branch information
dvzrv committed Nov 21, 2020
1 parent b891fe1 commit c48f014
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion contrib/unbound.service.in
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ ProtectSystem=strict
RuntimeDirectory=unbound
ConfigurationDirectory=unbound
StateDirectory=unbound
RestrictAddressFamilies=AF_INET AF_INET6 AF_UNIX
RestrictAddressFamilies=AF_INET AF_INET6 AF_NETLINK AF_UNIX
RestrictRealtime=true
SystemCallArchitectures=native
SystemCallFilter=~@clock @cpu-emulation @debug @keyring @module mount @obsolete @resources
Expand Down
2 changes: 1 addition & 1 deletion contrib/unbound_portable.service.in
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ ProtectSystem=strict
RuntimeDirectory=unbound
ConfigurationDirectory=unbound
StateDirectory=unbound
RestrictAddressFamilies=AF_INET AF_INET6 AF_UNIX
RestrictAddressFamilies=AF_INET AF_INET6 AF_NETLINK AF_UNIX
RestrictRealtime=true
SystemCallArchitectures=native
SystemCallFilter=~@clock @cpu-emulation @debug @keyring @module mount @obsolete @resources
Expand Down

0 comments on commit c48f014

Please sign in to comment.