#include "dhcpd.h"Go to the source code of this file.
Functions | |
| isc_result_t | readconf () |
| isc_result_t | read_conf_file (const char *filename, struct group *group, int group_type, int leasep) |
| isc_result_t | conf_file_subparse (struct parse *cfile, struct group *group, int group_type) |
| isc_result_t | lease_file_subparse (struct parse *cfile) |
| int | parse_statement (struct parse *cfile, struct group *group, int type, struct host_decl *host_decl, int declaration) |
| void | get_permit (struct parse *cfile, struct permit **permit_head, int is_allow, TIME *valid_from, TIME *valid_until) |
| Parse allow and deny statements. More... | |
| int | permit_list_match (struct permit *lhs, struct permit *rhs) |
| void | parse_pool_statement (struct parse *cfile, struct group *group, int type) |
| Parse a pool statement. More... | |
| int | parse_lbrace (struct parse *cfile) |
| void | parse_host_declaration (struct parse *cfile, struct group *group) |
| int | parse_class_declaration (struct class **cp, struct parse *cfile, struct group *group, int type) |
| void | parse_shared_net_declaration (struct parse *cfile, struct group *group) |
| void | parse_subnet_declaration (struct parse *cfile, struct shared_network *share) |
| void | parse_subnet6_declaration (struct parse *cfile, struct shared_network *share) |
| void | parse_group_declaration (struct parse *cfile, struct group *group) |
| int | parse_fixed_addr_param (struct option_cache **oc, struct parse *cfile, enum dhcp_token type) |
| int | parse_lease_declaration (struct lease **lp, struct parse *cfile) |
| void | parse_address_range (struct parse *cfile, struct group *group, int type, struct pool *inpool, struct lease **lpchain) |
| int | parse_allow_deny (struct option_cache **oc, struct parse *cfile, int flag) |
| void | parse_ia_na_declaration (struct parse *cfile) |
| void | parse_ia_ta_declaration (struct parse *cfile) |
| void | parse_ia_pd_declaration (struct parse *cfile) |
Definition at line 250 of file confpars.c.
| void get_permit | ( | struct parse * | cfile, |
| struct permit ** | permit_head, | ||
| int | is_allow, | ||
| TIME * | valid_from, | ||
| TIME * | valid_until | ||
| ) |
Parse allow and deny statements.
This function handles the common processing code for permit and deny statements in the parse_pool_statement and parse_pool6_statement functions. It reads in the configuration and constructs a new permit structure that it attachs to the permit_head passed in from the caller.
The allow or deny token should already be consumed, this function expects one of the following: known-clients; unknown-clients; known clients; unknown clients; authenticated clients; unauthenticated clients; all clients; dynamic bootp clients; members of <class name>="">; after <date>;
| [in] | cfile | = the configuration file being parsed |
| [in] | permit_head | = the head of the permit list (permit or prohibit) to which to attach the newly created permit structure |
| [in] | is_allow | = 1 if this is being invoked for an allow statement = 0 if this is being invoked for a deny statement |
| [in] | valid_from | = pointers to the time values from the enclosing pool |
| [in] | valid_until | or pond structure. One of them will be filled in if the configuration includes an "after" clause |
Definition at line 1550 of file confpars.c.
| isc_result_t lease_file_subparse | ( | struct parse * | cfile | ) |
Definition at line 277 of file confpars.c.
| void parse_address_range | ( | struct parse * | cfile, |
| struct group * | group, | ||
| int | type, | ||
| struct pool * | inpool, | ||
| struct lease ** | lpchain | ||
| ) |
Definition at line 3762 of file confpars.c.
| int parse_allow_deny | ( | struct option_cache ** | oc, |
| struct parse * | cfile, | ||
| int | flag | ||
| ) |
Definition at line 4659 of file confpars.c.
| int parse_class_declaration | ( | struct class ** | cp, |
| struct parse * | cfile, | ||
| struct group * | group, | ||
| int | type | ||
| ) |
Definition at line 2215 of file confpars.c.
| int parse_fixed_addr_param | ( | struct option_cache ** | oc, |
| struct parse * | cfile, | ||
| enum dhcp_token | type | ||
| ) |
Definition at line 3054 of file confpars.c.
Definition at line 2961 of file confpars.c.
Definition at line 1951 of file confpars.c.
| void parse_ia_na_declaration | ( | struct parse * | cfile | ) |
Definition at line 4727 of file confpars.c.
| void parse_ia_pd_declaration | ( | struct parse * | cfile | ) |
Definition at line 5599 of file confpars.c.
| void parse_ia_ta_declaration | ( | struct parse * | cfile | ) |
Definition at line 5163 of file confpars.c.
Definition at line 1933 of file confpars.c.
Definition at line 3125 of file confpars.c.
Parse a pool statement.
Pool statements are used to group declarations and permit & deny information with a specific address range. They must be declared within a shared network or subnet and there may be multiple pools withing a shared network or subnet. Each pool may have a different set of permit or deny options.
| [in] | cfile | = the configuration file being parsed |
| [in] | group | = the group structure for this pool |
| [in] | type | = the type of the enclosing statement. This must be SHARED_NET_DECL or SUBNET_DECL for this function. |
Definition at line 1724 of file confpars.c.
Definition at line 2595 of file confpars.c.
| int parse_statement | ( | struct parse * | cfile, |
| struct group * | group, | ||
| int | type, | ||
| struct host_decl * | host_decl, | ||
| int | declaration | ||
| ) |
Definition at line 364 of file confpars.c.
| void parse_subnet6_declaration | ( | struct parse * | cfile, |
| struct shared_network * | share | ||
| ) |
Definition at line 2840 of file confpars.c.
| void parse_subnet_declaration | ( | struct parse * | cfile, |
| struct shared_network * | share | ||
| ) |
Definition at line 2752 of file confpars.c.
Definition at line 1680 of file confpars.c.
| isc_result_t read_conf_file | ( | const char * | filename, |
| struct group * | group, | ||
| int | group_type, | ||
| int | leasep | ||
| ) |
Definition at line 79 of file confpars.c.
| isc_result_t readconf | ( | void | ) |
Definition at line 64 of file confpars.c.