/freebsd-10.0-release/tools/regression/usr.bin/yacc/ |
H A D | undefined.y | 1 %type <int> rule 3 rule: label
|
/freebsd-10.0-release/contrib/libarchive/tar/ |
H A D | subst.c | 72 struct subst_rule *rule; local 83 rule = malloc(sizeof(*rule)); 84 if (rule == NULL) 86 rule->next = NULL; 89 subst->first_rule = rule; 91 subst->last_rule->next = rule; 92 subst->last_rule = rule; 106 if ((r = regcomp(&rule->re, pattern, REG_BASIC)) != 0) { 108 regerror(r, &rule 215 struct subst_rule *rule; local 311 struct subst_rule *rule; local [all...] |
/freebsd-10.0-release/contrib/ofed/libsdp/src/ |
H A D | match.c | 54 struct use_family_rule *rule, 60 char *target = __sdp_get_family_str( rule->target_family ); 61 char *prog = rule->prog_name_expr; 63 /* TODO: handle IPv6 in rule */ 64 if ( rule->match_by_addr ) { 65 if ( rule->prefixlen != 32 ) 66 sprintf( addr_buf, "%s/%d", inet_ntoa( rule->ipv4 ), 67 rule->prefixlen ); 69 sprintf( addr_buf, "%s", inet_ntoa( rule->ipv4 ) ); 74 if ( rule 53 get_rule_str( struct use_family_rule *rule, char *buf, size_t len ) argument 87 match_ipv4_addr( struct use_family_rule *rule, const struct sockaddr_in *sin ) argument 97 match_ip_addr_and_port( struct use_family_rule *rule, const struct sockaddr *addr_in, const socklen_t addrlen ) argument 173 struct use_family_rule *rule; local 239 struct use_family_rule *rule; local [all...] |
/freebsd-10.0-release/lib/libugidfw/ |
H A D | ugidfw.h | 38 int bsde_rule_to_string(struct mac_bsdextended_rule *rule, char *buf, 43 struct mac_bsdextended_rule *rule, size_t buflen, char *errstr); 45 struct mac_bsdextended_rule *rule, size_t buflen, char *errstr); 49 int bsde_get_rule(int rulenum, struct mac_bsdextended_rule *rule, 52 int bsde_set_rule(int rulenum, struct mac_bsdextended_rule *rule, 54 int bsde_add_rule(int *rulename, struct mac_bsdextended_rule *rule,
|
H A D | ugidfw.c | 60 bsde_rule_to_string(struct mac_bsdextended_rule *rule, char *buf, size_t buflen) argument 65 char *cur, type[sizeof(rule->mbr_object.mbo_type) * CHAR_BIT + 1]; 78 if (rule->mbr_subject.mbs_flags) { 79 if (rule->mbr_subject.mbs_neg == MBS_ALL_FLAGS) { 90 if (!notdone && (rule->mbr_subject.mbs_neg & MBO_UID_DEFINED)) { 97 if (rule->mbr_subject.mbs_flags & MBO_UID_DEFINED) { 98 pwd = getpwuid(rule->mbr_subject.mbs_uid_min); 108 rule->mbr_subject.mbs_uid_min); 114 if (rule->mbr_subject.mbs_uid_min != 115 rule 994 bsde_parse_rule(int argc, char *argv[], struct mac_bsdextended_rule *rule, size_t buflen, char *errstr) argument 1065 bsde_parse_rule_string(const char *string, struct mac_bsdextended_rule *rule, size_t buflen, char *errstr) argument 1177 bsde_get_rule(int rulenum, struct mac_bsdextended_rule *rule, size_t errlen, char *errstr) argument 1217 struct mac_bsdextended_rule rule; local 1248 bsde_set_rule(int rulenum, struct mac_bsdextended_rule *rule, size_t buflen, char *errstr) argument 1281 bsde_add_rule(int *rulenum, struct mac_bsdextended_rule *rule, size_t buflen, char *errstr) argument [all...] |
/freebsd-10.0-release/sbin/devfs/ |
H A D | Makefile | 4 SRCS= devfs.c rule.c
|
/freebsd-10.0-release/sys/security/mac_portacl/ |
H A D | mac_portacl.c | 120 struct rule { struct 126 TAILQ_ENTRY(rule) r_entries; 135 * Text format for the rule string is that a rule consists of a 142 static TAILQ_HEAD(rulehead, rule) rule_head; 148 struct rule *rule; local 150 while ((rule = TAILQ_FIRST(head)) != NULL) { 151 TAILQ_REMOVE(head, rule, r_entries); 152 free(rule, M_PORTAC 180 parse_rule_element(char *element, struct rule **rule) argument 386 struct rule *rule; local [all...] |
/freebsd-10.0-release/sys/security/mac_bsdextended/ |
H A D | mac_bsdextended.c | 84 "BSD Extended MAC rule"); 95 &rule_slots, 0, "Number of used rule slots\n"); 109 * between the new mode (first rule matches) and the old functionality (all 115 "Disable/enable match first rule functionality"); 118 ugidfw_rule_valid(struct mac_bsdextended_rule *rule) argument 121 if ((rule->mbr_subject.mbs_flags | MBS_ALL_FLAGS) != MBS_ALL_FLAGS) 123 if ((rule->mbr_subject.mbs_neg | MBS_ALL_FLAGS) != MBS_ALL_FLAGS) 125 if ((rule->mbr_object.mbo_flags | MBO_ALL_FLAGS) != MBO_ALL_FLAGS) 127 if ((rule->mbr_object.mbo_neg | MBO_ALL_FLAGS) != MBO_ALL_FLAGS) 129 if ((rule 229 ugidfw_rulecheck(struct mac_bsdextended_rule *rule, struct ucred *cred, struct vnode *vp, struct vattr *vap, int acc_mode) argument [all...] |
/freebsd-10.0-release/sys/kern/ |
H A D | kern_rctl.c | 82 * 'rctl_rule_link' connects a rule with every racct it's related to. 83 * For example, rule 'user:X:openfiles:deny=N/process' is linked 173 static int rctl_rule_fully_specified(const struct rctl_rule *rule); 174 static void rctl_rule_to_sbuf(struct sbuf *sb, const struct rctl_rule *rule); 219 * hitting 'rule'. 222 rctl_available_resource(const struct proc *p, const struct rctl_rule *rule) argument 230 resource = rule->rr_resource; 231 switch (rule->rr_per) { 233 available = rule->rr_amount - 237 available = rule 262 rctl_would_exceed(const struct proc *p, const struct rctl_rule *rule, int64_t amount) argument 282 struct rctl_rule *rule; local 329 struct rctl_rule *rule; local 456 struct rctl_rule *rule; local 484 struct rctl_rule *rule; local 521 rctl_rule_matches(const struct rctl_rule *rule, const struct rctl_rule *filter) argument 634 rctl_racct_add_rule(struct racct *racct, struct rctl_rule *rule) argument 651 rctl_racct_add_rule_locked(struct racct *racct, struct rctl_rule *rule) argument 696 rctl_rule_acquire_subject(struct rctl_rule *rule) argument 722 rctl_rule_release_subject(struct rctl_rule *rule) argument 750 struct rctl_rule *rule; local 770 rctl_rule_duplicate(const struct rctl_rule *rule, int flags) argument 793 rctl_rule_acquire(struct rctl_rule *rule) argument 804 struct rctl_rule *rule; local 819 rctl_rule_release(struct rctl_rule *rule) argument 838 rctl_rule_fully_specified(const struct rctl_rule *rule) argument 882 struct rctl_rule *rule; local 1000 rctl_rule_add(struct rctl_rule *rule) argument 1171 rctl_rule_to_sbuf(struct sbuf *sb, const struct rctl_rule *rule) argument 1538 struct rctl_rule *rule; local 1755 struct rctl_rule *rule; local [all...] |
/freebsd-10.0-release/sys/netpfil/ipfw/ |
H A D | ip_fw_sockopt.c | 77 * Find the smallest rule >= key, id. 149 * Add a new rule to the list. Copy the rule into a malloc'ed area, then 150 * possibly create a rule number and add the rule to the list. 158 struct ip_fw *rule; local 166 rule = malloc(l, M_IPFW, M_WAITOK | M_ZERO); 170 free(rule, M_IPFW); 174 bcopy(input_rule, rule, l); 176 rule 219 struct ip_fw *rule; local 255 keep_rule(struct ip_fw *rule, uint8_t cmd, uint8_t set, uint32_t n) argument 281 struct ip_fw *rule; local 437 clear_counters(struct ip_fw *rule, int log_only) argument 459 struct ip_fw *rule; local 520 check_ipfw_struct(struct ip_fw *rule, int size) argument 881 struct ip_fw *rule, *dst; local 946 struct ip_fw *buf, *rule; local 1335 convert_rule_to_7(struct ip_fw *rule) argument 1390 convert_rule_to_8(struct ip_fw *rule) argument [all...] |
H A D | ip_fw_dynamic.c | 33 * Dynamic rule support for ipfw 88 * with the mask defined for the rule, then hashed, then matched 105 * Each dynamic rule holds a pointer to the parent ipfw rule so 107 * the parent rule is deleted. XXX we should make them survive. 116 ipfw_dyn_rule *head; /* Pointer to first rule */ 162 * seconds of lifetime of a rule. 303 * Lookup a dynamic rule, locked version. 464 * @p - pointer to dynamic rule 561 * the third parameter is the parent rule an 565 add_dyn_rule(struct ipfw_flow_id *id, int i, u_int8_t dyn_type, struct ip_fw *rule) argument 612 lookup_dyn_parent(struct ipfw_flow_id *pkt, int *pindex, struct ip_fw *rule) argument 655 ipfw_install_state(struct ip_fw *rule, ipfw_insn_limit *cmd, struct ip_fw_args *args, uint32_t tablearg) argument 1022 check_dyn_rules(struct ip_fw_chain *chain, struct ip_fw *rule, int set, int check_ka, int timer) argument 1299 ipfw_expire_dyn_rules(struct ip_fw_chain *chain, struct ip_fw *rule, int set) argument [all...] |
/freebsd-10.0-release/usr.bin/rctl/ |
H A D | rctl.c | 98 resolve_ids(char *rule) argument 104 subject = strsep(&rule, ":"); 105 textid = strsep(&rule, ":"); 107 errx(1, "error in rule specification -- no subject"); 108 if (rule != NULL) 109 rest = rule; 145 expand_amount(char *rule) argument 151 copy = strdup(rule); 164 return (rule); 189 humanize_ids(char *rule) argument 243 humanize_amount(char *rule) argument 294 char *rule; local 308 add_rule(char *rule) argument 464 char *rule = NULL; local [all...] |
/freebsd-10.0-release/contrib/pf/ftp-proxy/ |
H A D | filter.c | 70 pfr.rule.direction = dir; 103 pfr.rule.rpool.proxy_port[0] = nat_range_low; 104 pfr.rule.rpool.proxy_port[1] = nat_range_high; 136 pfr.rule.rpool.proxy_port[0] = rdr_port; 258 /* Generic for all rule types. */ 259 pfr.rule.af = src->sa_family; 260 pfr.rule.proto = IPPROTO_TCP; 261 pfr.rule.src.addr.type = PF_ADDR_ADDRMASK; 262 pfr.rule.dst.addr.type = PF_ADDR_ADDRMASK; 264 memcpy(&pfr.rule [all...] |
/freebsd-10.0-release/contrib/pf/tftp-proxy/ |
H A D | filter.c | 74 pfr.rule.direction = dir; 107 pfr.rule.rpool.proxy_port[0] = nat_range_low; 108 pfr.rule.rpool.proxy_port[1] = nat_range_high; 140 pfr.rule.rpool.proxy_port[0] = rdr_port; 267 /* Generic for all rule types. */ 268 pfr.rule.af = src->sa_family; 269 pfr.rule.proto = proto; 270 pfr.rule.src.addr.type = PF_ADDR_ADDRMASK; 271 pfr.rule.dst.addr.type = PF_ADDR_ADDRMASK; 273 memcpy(&pfr.rule [all...] |
/freebsd-10.0-release/usr.sbin/ugidfw/ |
H A D | ugidfw.c | 75 struct mac_bsdextended_rule rule; local 78 error = bsde_parse_rule(argc, argv, &rule, BUFSIZ, errstr); 84 error = bsde_add_rule(&rulenum, &rule, BUFSIZ, errstr); 89 if (bsde_rule_to_string(&rule, charstr, BUFSIZ) == -1) 90 warnx("Added rule, but unable to print string."); 99 struct mac_bsdextended_rule rule; local 104 warnx("unable to get rule slots; mac_bsdextended.ko " 116 error = bsde_get_rule(i, &rule, BUFSIZ, errstr); 121 warnx("rule %d: %s", i, errstr); 127 if (bsde_rule_to_string(&rule, charst 138 struct mac_bsdextended_rule rule; local [all...] |
/freebsd-10.0-release/contrib/byacc/ |
H A D | closure.c | 20 int rule; local 29 for (rule = *sp; rule > 0; rule = *++sp) 31 symbol = ritem[rrhs[rule]]; 58 int rule; local 85 while ((rule = *rp++) >= 0) 87 SETBIT(rrow, rule);
|
H A D | graph.c | 55 int rule; local 68 rule = -(*sp); 69 fprintf(graph_file, " %s -> ", symbol_pname[rlhs[rule]]); 71 for (sp = ritem + rrhs[rule]; sp < sp1; sp++)
|
/freebsd-10.0-release/contrib/ipfilter/rules/ |
H A D | ipmon.conf | 22 rule = 12, logtag = 101, direction = in, result = block,
|
/freebsd-10.0-release/sys/netpfil/pf/ |
H A D | pf_ioctl.c | 217 /* default rule should never be garbage collected */ 275 struct pf_rule *rule; local 289 rule = TAILQ_LAST(ruleset->rules[rs_num].active.ptr, 292 rule = TAILQ_FIRST(ruleset->rules[rs_num].active.ptr); 298 rule = TAILQ_LAST(ruleset->rules[rs_num].inactive.ptr, 301 rule = TAILQ_FIRST(ruleset->rules[rs_num].inactive.ptr); 304 while ((rule != NULL) && (rule->nr != rule_number)) 305 rule = TAILQ_NEXT(rule, entrie 346 pf_unlink_rule(struct pf_rulequeue *rulequeue, struct pf_rule *rule) argument 360 pf_free_rule(struct pf_rule *rule) argument 709 struct pf_rule *rule; local 731 struct pf_rule *rule; local 791 pf_hash_rule(MD5_CTX *ctx, struct pf_rule *rule) argument 833 struct pf_rule *rule, **old_array; local 891 struct pf_rule *rule; local 1121 struct pf_rule *rule, *tail; local 1303 struct pf_rule *rule; local 1918 struct pf_rule *rule; local [all...] |
/freebsd-10.0-release/tools/regression/mac/mac_bsdextended/ |
H A D | test_ugidfw.c | 57 * rule<->string routines to confirm they work approximately as desired. 155 struct mac_bsdextended_rule rule; local 173 error = bsde_parse_rule_string(test_strings[i], &rule, 178 error = bsde_rule_to_string(&rule, rulestr, sizeof(rulestr)); 180 errx(-1, "bsde_rule_to_string: rule for '%s' " 223 * policy for basic state. We want the rule count to be 0 before
|
/freebsd-10.0-release/sys/sys/ |
H A D | rctl.h | 55 * in the rule are met. There is no global list of rules; instead, 57 * they apply to - for example, a rule of type "user" is linked to the 61 * pointing to the rule. 64 * structures, to subjects. In order to change a rule, add a new rule 137 struct rctl_rule *rctl_rule_duplicate(const struct rctl_rule *rule, int flags); 138 void rctl_rule_acquire(struct rctl_rule *rule); 139 void rctl_rule_release(struct rctl_rule *rule); 140 int rctl_rule_add(struct rctl_rule *rule);
|
/freebsd-10.0-release/usr.sbin/ppp/ |
H A D | filter.h | 47 * There's a struct filterent for each possible filter rule. The 75 /* f_action values [0..MAXFILTERS) specify the next filter rule, others are: */ 81 struct filterent rule[MAXFILTERS]; /* incoming packet filter */ member in struct:filter
|
/freebsd-10.0-release/sbin/pfctl/ |
H A D | pfctl.c | 775 pfctl_print_rule_counters(struct pf_rule *rule, int opts) argument 784 if (rule->skip[i].nr == rule->nr + 1) 787 if (rule->skip[i].nr == -1) 790 printf("%u ", rule->skip[i].nr); 795 rule->qname, rule->qid, rule->pqname, rule->pqid); 800 (unsigned long long)rule 1190 struct pf_rule *rule; local [all...] |
/freebsd-10.0-release/contrib/subversion/subversion/libsvn_subr/ |
H A D | date.c | 30 /* Valid rule actions */ 47 typedef struct rule struct 49 char key; /* The template char that this rule matches */ 50 const char *valid; /* String of valid chars for this rule */ 51 enum rule_action action; /* What action to take when the rule is matched */ 55 } rule; typedef in typeref:struct:rule 68 should be processed, using a rule for each valid symbol. */ 69 static const rule 93 /* Return the rule associated with TCHAR, or NULL if there 94 is no such rule [all...] |
/freebsd-10.0-release/sys/netinet/ |
H A D | ip_fw.h | 32 * The default rule number. By the design of ip_fw, the default rule 34 * allowed for a rule. The ip_fw code relies on both meanings of this 61 * Call stack currently is an uint16_t array with rule numbers. 167 O_SKIPTO, /* arg1=next rule number */ 217 O_CALLRETURN, /* arg1=called rule number */ 472 * Here we have the structure representing an ipfw rule. 478 * Given a rule pointer r: 482 * once a rule matched). 486 * + if a rule ha 558 struct ip_fw *rule; /* pointer to rule */ member in struct:_ipfw_dyn_rule [all...] |