[cfg] Add "none" as "trusted_networks" option
This commit is contained in:
parent
bcdd3b2f65
commit
be1bacf278
|
@ -40,8 +40,8 @@ general {
|
|||
|
||||
# Sets who is allowed to connect without authorisation. This applies to
|
||||
# client types like Remotes, DAAP clients (iTunes) and to the web
|
||||
# interface. Options are "any", "lan", "localhost" or the prefix to one
|
||||
# or more ipv4/6 networks. The default is { "lan" }
|
||||
# interface. Options are "any", "lan", "localhost", "none" or the prefix
|
||||
# to one or more ipv4/6 networks. The default is { "lan" }
|
||||
# trusted_networks = { "lan" }
|
||||
|
||||
# Enable/disable IPv6
|
||||
|
|
|
@ -239,7 +239,7 @@ net_peer_address_is_trusted(union net_sockaddr *naddr)
|
|||
{
|
||||
network = cfg_getnstr(section, "trusted_networks", i);
|
||||
|
||||
if (!network || network[0] == '\0')
|
||||
if (!network || network[0] == '\0' || strcmp(network, "none") == 0)
|
||||
return false;
|
||||
|
||||
if (strcmp(network, "any") == 0)
|
||||
|
|
Loading…
Reference in New Issue