diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2009-11-22 23:30:06 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2009-11-22 23:30:06 +0000 |
commit | 69b817b48b100b10e82e17cd6f7bdd98a29be1c0 (patch) | |
tree | ba6b953614d5e1a1a98727b59215575820fa999f /usr.sbin | |
parent | 4b4170d43b95e4ea821b7573a0db0c5631089bca (diff) |
Move from the PF_RULESET_FILTER world order to PF_TRANS_RULESET
due to the standard henning+oga commit-and-run-for-beer problem.
ok claudio
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/ftp-proxy/filter.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/usr.sbin/ftp-proxy/filter.c b/usr.sbin/ftp-proxy/filter.c index c1d81dc1d35..16c3cd25573 100644 --- a/usr.sbin/ftp-proxy/filter.c +++ b/usr.sbin/ftp-proxy/filter.c @@ -1,4 +1,4 @@ -/* $OpenBSD: filter.c,v 1.10 2009/11/21 13:59:31 claudio Exp $ */ +/* $OpenBSD: filter.c,v 1.11 2009/11/22 23:30:05 deraadt Exp $ */ /* * Copyright (c) 2004, 2005 Camiel Dobbelaar, <cd@sentia.nl> @@ -40,7 +40,7 @@ #define satosin6(sa) ((struct sockaddr_in6 *)(sa)) int add_addr(struct sockaddr *, int); -int prepare_rule(u_int32_t, int, struct sockaddr *, struct sockaddr *, +int prepare_rule(u_int32_t, struct sockaddr *, struct sockaddr *, u_int16_t); int server_lookup4(struct sockaddr_in *, struct sockaddr_in *, struct sockaddr_in *); @@ -83,7 +83,7 @@ add_nat(u_int32_t id, struct sockaddr *src, struct sockaddr *dst, return (-1); } - if (prepare_rule(id, PF_RULESET_FILTER, src, dst, d_port) == -1) + if (prepare_rule(id, src, dst, d_port) == -1) return (-1); if (add_addr(nat, PF_NAT) == -1) @@ -108,7 +108,7 @@ add_rdr(u_int32_t id, struct sockaddr *src, struct sockaddr *dst, return (-1); } - if (prepare_rule(id, PF_RULESET_FILTER, src, dst, d_port) == -1) + if (prepare_rule(id, src, dst, d_port) == -1) return (-1); if (add_addr(rdr, PF_RDR) == -1) @@ -176,7 +176,7 @@ prepare_commit(u_int32_t id) getpid(), id); memset(&pfte, 0, sizeof pfte); strlcpy(pfte.anchor, an, PF_ANCHOR_NAME_SIZE); - pfte.rs_num = PF_RULESET_FILTER; + pfte.type = PF_TRANS_RULESET; if (ioctl(dev, DIOCXBEGIN, &pft) == -1) return (-1); @@ -185,7 +185,7 @@ prepare_commit(u_int32_t id) } int -prepare_rule(u_int32_t id, int rs_num, struct sockaddr *src, +prepare_rule(u_int32_t id, struct sockaddr *src, struct sockaddr *dst, u_int16_t d_port) { char an[PF_ANCHOR_NAME_SIZE]; |