Lines Matching +defs:match +defs:line

4   * addresses (or network numbers), or on terminal line names in case of
49 /* login_access - match username/group and host/tty with access control file */
56 char line[BUFSIZ];
60 int match = NO;
66 * Process the table one line at a time and stop at the first match.
74 while (!match && fgets(line, sizeof(line), fp)) {
76 if (line[end = strlen(line) - 1] != '\n') {
77 syslog(LOG_ERR, "%s: line %d: missing newline or line too long",
81 if (line[0] == '#')
82 continue; /* comment line */
83 while (end > 0 && isspace(line[end - 1]))
85 line[end] = 0; /* strip trailing whitespace */
86 if (line[0] == 0) /* skip blank lines */
88 if (!(perm = strtok(line, fieldsep))
92 syslog(LOG_ERR, "%s: line %d: bad field count", login_access_opts->accessfile,
97 syslog(LOG_ERR, "%s: line %d: bad first field", login_access_opts->accessfile,
101 match = (list_match(froms, from, from_match, login_access_opts)
108 return (match == 0 || (line[0] == '+'));
111 /* list_match - match an item against a list of tokens with exceptions */
119 int match = NO;
125 * a match, look for an "EXCEPT" list and recurse to determine whether
126 * the match is affected by any exceptions.
132 if ((match = (*match_fn)(tok, item, login_access_opts)) != 0) /* YES */
137 if (match != NO) {
143 return (match);
149 /* netgroup_match - match group against machine or user */
176 /* group_match - match a group against one token */
210 /* user_match - match a username against one token */
221 * If a token has the magic value "ALL" the match always succeeds.
236 } else if (string_match(tok, string)) { /* ALL or exact match */
244 /* from_match - match a host or tty against a list of tokens */
254 * If a token has the magic value "ALL" the match always succeeds. Return
264 } else if (string_match(tok, string)) { /* ALL or exact match */
266 } else if (tok[0] == '.') { /* domain: match last fields */
280 /* string_match - match a string against one token */
287 * If the token has the magic value "ALL" the match always succeeds.
293 } else if (strcasecmp(tok, string) == 0) { /* try exact match */