mirror of
https://github.com/openbsd/src.git
synced 2025-01-10 06:47:55 -08:00
remove trailing spaces and tabs; no binary change.
written with help from henning@, who suggested ensuring that there are no changes in the digests for object files, thanks! ok henning@
This commit is contained in:
parent
c6c609d539
commit
3cc742f358
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: parse.y,v 1.591 2010/08/03 18:42:40 henning Exp $ */
|
||||
/* $OpenBSD: parse.y,v 1.592 2010/09/02 14:01:04 sobrado Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2001 Markus Friedl. All rights reserved.
|
||||
@ -152,7 +152,7 @@ enum { PF_STATE_OPT_MAX, PF_STATE_OPT_NOSYNC, PF_STATE_OPT_SRCTRACK,
|
||||
PF_STATE_OPT_MAX_SRC_STATES, PF_STATE_OPT_MAX_SRC_CONN,
|
||||
PF_STATE_OPT_MAX_SRC_CONN_RATE, PF_STATE_OPT_MAX_SRC_NODES,
|
||||
PF_STATE_OPT_OVERLOAD, PF_STATE_OPT_STATELOCK,
|
||||
PF_STATE_OPT_TIMEOUT, PF_STATE_OPT_SLOPPY,
|
||||
PF_STATE_OPT_TIMEOUT, PF_STATE_OPT_SLOPPY,
|
||||
PF_STATE_OPT_PFLOW };
|
||||
|
||||
enum { PF_SRCTRACK_NONE, PF_SRCTRACK, PF_SRCTRACK_GLOBAL, PF_SRCTRACK_RULE };
|
||||
@ -822,7 +822,7 @@ anchorrule : ANCHOR anchorname dir quick interface af proto fromto
|
||||
pf_anchor_setup(&r,
|
||||
&pf->astack[pf->asd]->ruleset,
|
||||
$2 ? $2 : pf->alast->name);
|
||||
|
||||
|
||||
if (r.anchor == NULL)
|
||||
err(1, "anchorrule: unable to "
|
||||
"create ruleset");
|
||||
@ -2060,7 +2060,7 @@ pfrule : action dir logquick interface af proto fromto
|
||||
if (($8.rroute.rdr = calloc(1,
|
||||
sizeof(*$8.rroute.rdr))) == NULL)
|
||||
err(1, "$8.rroute.rdr");
|
||||
$8.rroute.rdr->host = $8.route.host;
|
||||
$8.rroute.rdr->host = $8.route.host;
|
||||
}
|
||||
if ($8.queues.qname != NULL) {
|
||||
if (strlcpy(r.qname, $8.queues.qname,
|
||||
@ -2103,7 +2103,7 @@ pfrule : action dir logquick interface af proto fromto
|
||||
r.divert.addr =
|
||||
$8.divert.addr->addr.v.a.addr;
|
||||
}
|
||||
}
|
||||
}
|
||||
r.divert_packet.port = $8.divert_packet.port;
|
||||
|
||||
expand_rule(&r, 0, $4, &$8.nat, &$8.rdr, &$8.rroute, $6,
|
||||
@ -4549,7 +4549,7 @@ collapse_redirspec(struct pf_pool *rpool, struct pf_rule *r,
|
||||
return (1);
|
||||
} else if (i == 1) { /* only one address */
|
||||
for (h = rs->rdr->host; h != NULL; h = h->next)
|
||||
if (!h->af || !r->af || r->af == h->af)
|
||||
if (!h->af || !r->af || r->af == h->af)
|
||||
break;
|
||||
rpool->addr = h->addr;
|
||||
if (!allow_if && h->ifname) {
|
||||
@ -4559,7 +4559,7 @@ collapse_redirspec(struct pf_pool *rpool, struct pf_rule *r,
|
||||
if (h->ifname && strlcpy(rpool->ifname, h->ifname,
|
||||
sizeof(rpool->ifname)) >= sizeof(rpool->ifname))
|
||||
errx(1, "collapse_redirspec: strlcpy");
|
||||
|
||||
|
||||
return (0);
|
||||
} else { /* more than one address */
|
||||
if (rs->pool_opts.type &&
|
||||
@ -4850,7 +4850,7 @@ expand_rule(struct pf_rule *r, int keeprule, struct node_if *interfaces,
|
||||
":0 in a binat-to rule");
|
||||
error++;
|
||||
}
|
||||
if (PF_AZERO(&r->src.addr.v.a.mask, af) ||
|
||||
if (PF_AZERO(&r->src.addr.v.a.mask, af) ||
|
||||
PF_AZERO(&r->nat.addr.v.a.mask, af)) {
|
||||
yyerror ("source and redir addresess must have "
|
||||
"a matching network mask in binat-rule");
|
||||
@ -5333,7 +5333,7 @@ top:
|
||||
if (next == '=')
|
||||
return (NE);
|
||||
lungetc(next);
|
||||
break;
|
||||
break;
|
||||
case '<':
|
||||
next = lgetc(0);
|
||||
if (next == '>') {
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: pf_print_state.c,v 1.56 2010/01/13 00:57:49 mcbride Exp $ */
|
||||
/* $OpenBSD: pf_print_state.c,v 1.57 2010/09/02 14:01:04 sobrado Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2001 Daniel Hartmeier
|
||||
@ -219,14 +219,14 @@ print_state(struct pfsync_state *s, int opts)
|
||||
dst = &s->dst;
|
||||
sk = &s->key[PF_SK_STACK];
|
||||
nk = &s->key[PF_SK_WIRE];
|
||||
if (s->proto == IPPROTO_ICMP || s->proto == IPPROTO_ICMPV6)
|
||||
if (s->proto == IPPROTO_ICMP || s->proto == IPPROTO_ICMPV6)
|
||||
sk->port[0] = nk->port[0];
|
||||
} else {
|
||||
src = &s->dst;
|
||||
dst = &s->src;
|
||||
sk = &s->key[PF_SK_WIRE];
|
||||
nk = &s->key[PF_SK_STACK];
|
||||
if (s->proto == IPPROTO_ICMP || s->proto == IPPROTO_ICMPV6)
|
||||
if (s->proto == IPPROTO_ICMP || s->proto == IPPROTO_ICMPV6)
|
||||
sk->port[1] = nk->port[1];
|
||||
}
|
||||
printf("%s ", s->ifname);
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: pfctl.c,v 1.301 2010/08/11 10:03:29 jsg Exp $ */
|
||||
/* $OpenBSD: pfctl.c,v 1.302 2010/09/02 14:01:04 sobrado Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2001 Daniel Hartmeier
|
||||
@ -669,7 +669,7 @@ int
|
||||
pfctl_id_kill_states(int dev, const char *iface, int opts)
|
||||
{
|
||||
struct pfioc_state_kill psk;
|
||||
|
||||
|
||||
if (state_killers != 2 || (strlen(state_kill[1]) == 0)) {
|
||||
warnx("no id specified");
|
||||
usage();
|
||||
@ -762,7 +762,7 @@ pfctl_show_rules(int dev, char *path, int opts, enum pfctl_show format,
|
||||
* Truncate a trailing / and * on an anchorname before searching for
|
||||
* the ruleset, this is syntactic sugar that doesn't actually make it
|
||||
* to the kernel.
|
||||
*/
|
||||
*/
|
||||
if ((p = strrchr(anchorname, '/')) != NULL &&
|
||||
p[1] == '*' && p[2] == '\0') {
|
||||
p[0] = '\0';
|
||||
@ -1072,12 +1072,12 @@ pfctl_add_rule(struct pfctl *pf, struct pf_rule *r, const char *anchor_call)
|
||||
|
||||
rs = &pf->anchor->ruleset;
|
||||
if (anchor_call[0] && r->anchor == NULL) {
|
||||
/*
|
||||
/*
|
||||
* Don't make non-brace anchors part of the main anchor pool.
|
||||
*/
|
||||
if ((r->anchor = calloc(1, sizeof(*r->anchor))) == NULL)
|
||||
err(1, "pfctl_add_rule: calloc");
|
||||
|
||||
|
||||
pf_init_ruleset(&r->anchor->ruleset);
|
||||
r->anchor->ruleset.anchor = r->anchor;
|
||||
if (strlcpy(r->anchor->path, anchor_call,
|
||||
@ -1436,7 +1436,7 @@ pfctl_init_options(struct pfctl *pf)
|
||||
if (sysctl(mib, 2, &mem, &size, NULL, 0) == -1)
|
||||
err(1, "sysctl");
|
||||
if (mem <= 100*1024*1024)
|
||||
pf->limit[PF_LIMIT_TABLE_ENTRIES] = PFR_KENTRY_HIWAT_SMALL;
|
||||
pf->limit[PF_LIMIT_TABLE_ENTRIES] = PFR_KENTRY_HIWAT_SMALL;
|
||||
|
||||
pf->debug = LOG_ERR;
|
||||
pf->debug_set = 0;
|
||||
@ -1912,7 +1912,7 @@ pfctl_state_load(int dev, const char *file)
|
||||
err(1, "DIOCADDSTATE");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fclose(f);
|
||||
}
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: pfctl_parser.c,v 1.269 2010/07/13 13:11:57 sthen Exp $ */
|
||||
/* $OpenBSD: pfctl_parser.c,v 1.270 2010/09/02 14:01:04 sobrado Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2001 Daniel Hartmeier
|
||||
@ -328,11 +328,11 @@ const char *
|
||||
loglevel_to_string(int level)
|
||||
{
|
||||
CODE *c;
|
||||
|
||||
|
||||
for (c = prioritynames; c->c_name; c++)
|
||||
if (c->c_val == level)
|
||||
return (c->c_name);
|
||||
|
||||
|
||||
return ("unknown");
|
||||
}
|
||||
|
||||
@ -1447,7 +1447,7 @@ host(const char *s)
|
||||
if ((if_name = strrchr(ps, '@')) != NULL) {
|
||||
if_name[0] = '\0';
|
||||
if_name++;
|
||||
}
|
||||
}
|
||||
|
||||
if ((p = strrchr(ps, '/')) != NULL) {
|
||||
if ((r = strdup(ps)) == NULL)
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: authpf.c,v 1.114 2010/01/27 15:36:17 todd Exp $ */
|
||||
/* $OpenBSD: authpf.c,v 1.115 2010/09/02 14:01:04 sobrado Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (C) 1998 - 2007 Bob Beck (beck@openbsd.org).
|
||||
@ -147,7 +147,7 @@ main(int argc, char *argv[])
|
||||
|
||||
login_close(lc);
|
||||
|
||||
if (strcmp(shell, PATH_AUTHPF_SHELL) &&
|
||||
if (strcmp(shell, PATH_AUTHPF_SHELL) &&
|
||||
strcmp(shell, PATH_AUTHPF_SHELL_NOIP)) {
|
||||
syslog(LOG_ERR, "wrong shell for user %s, uid %u",
|
||||
pw->pw_name, pw->pw_uid);
|
||||
@ -272,7 +272,7 @@ main(int argc, char *argv[])
|
||||
pidfp = NULL;
|
||||
pidfd = -1;
|
||||
} while (1);
|
||||
|
||||
|
||||
/* whack the group list */
|
||||
gid = getegid();
|
||||
if (setgroups(1, &gid) == -1) {
|
||||
@ -498,7 +498,7 @@ allowed_luser(struct passwd *pw)
|
||||
matched = 0;
|
||||
|
||||
while ((buf = fgetln(f, &len))) {
|
||||
|
||||
|
||||
if (buf[len - 1] == '\n')
|
||||
buf[len - 1] = '\0';
|
||||
else {
|
||||
@ -515,7 +515,7 @@ allowed_luser(struct passwd *pw)
|
||||
matched++;
|
||||
} else if (buf[0] == '%') {
|
||||
/* check group membership */
|
||||
int cnt;
|
||||
int cnt;
|
||||
struct group *group;
|
||||
|
||||
if ((group = getgrnam(buf + 1)) == NULL) {
|
||||
@ -531,7 +531,7 @@ allowed_luser(struct passwd *pw)
|
||||
pw->pw_gid, groups, &ngroups);
|
||||
gl_init++;
|
||||
}
|
||||
|
||||
|
||||
for ( cnt = 0; cnt < ngroups; cnt++) {
|
||||
if (group->gr_gid == groups[cnt]) {
|
||||
matched++;
|
||||
|
Loading…
Reference in New Issue
Block a user