mirror of
https://github.com/samba-team/samba.git
synced 2025-07-31 20:22:15 +03:00
fix byte ordering when using CIDR notation in hosts allow/deny; spotted by Eloy Paris
(This used to be commit 6155144b9f
)
This commit is contained in:
@ -40,6 +40,10 @@ static BOOL masked_match(const char *tok, const char *slash, const char *s)
|
||||
DEBUG(0,("access: bad net/mask access control: %s\n", tok));
|
||||
return (False);
|
||||
}
|
||||
|
||||
/* convert to network byte order */
|
||||
mask = htonl(mask);
|
||||
|
||||
return ((addr & mask) == net);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user