mirror of
https://gitlab.com/chrony/chrony.git
synced 2025-12-03 16:25:07 -05:00
conf: rework allow/deny parser
Refactor the (cmd)allow/deny parser and make it more strict in what input it accepts. Check the scanned numbers and require whole input to be processed. Move the parser to cmdparse to make it available to the client.
This commit is contained in:
@@ -39,6 +39,9 @@ typedef struct {
|
||||
/* Parse a command to add an NTP server or peer */
|
||||
extern int CPS_ParseNTPSourceAdd(char *line, CPS_NTP_Source *src);
|
||||
|
||||
/* Parse a command to allow/deny access */
|
||||
extern int CPS_ParseAllowDeny(char *line, int *all, IPAddr *ip, int *subnet_bits);
|
||||
|
||||
/* Parse a command to enable local reference */
|
||||
extern int CPS_ParseLocal(char *line, int *stratum, int *orphan, double *distance);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user