ip6_forward.c (253571) | ip6_forward.c (253970) |
---|---|
1/*- 2 * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project. 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 16 unchanged lines hidden (view full) --- 25 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 27 * SUCH DAMAGE. 28 * 29 * $KAME: ip6_forward.c,v 1.69 2001/05/17 03:48:30 itojun Exp $ 30 */ 31 32#include <sys/cdefs.h> | 1/*- 2 * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project. 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 16 unchanged lines hidden (view full) --- 25 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 27 * SUCH DAMAGE. 28 * 29 * $KAME: ip6_forward.c,v 1.69 2001/05/17 03:48:30 itojun Exp $ 30 */ 31 32#include <sys/cdefs.h> |
33__FBSDID("$FreeBSD: head/sys/netinet6/ip6_forward.c 253571 2013-07-23 14:14:24Z ae $"); | 33__FBSDID("$FreeBSD: head/sys/netinet6/ip6_forward.c 253970 2013-08-05 20:13:02Z hrs $"); |
34 35#include "opt_inet.h" 36#include "opt_inet6.h" 37#include "opt_ipfw.h" 38#include "opt_ipsec.h" 39#include "opt_ipstealth.h" 40 41#include <sys/param.h> --- 90 unchanged lines hidden (view full) --- 132 * Do not forward packets with unspecified source. It was discussed 133 * in July 2000, on the ipngwg mailing list. 134 */ 135 if ((m->m_flags & (M_BCAST|M_MCAST)) != 0 || 136 IN6_IS_ADDR_MULTICAST(&ip6->ip6_dst) || 137 IN6_IS_ADDR_UNSPECIFIED(&ip6->ip6_src)) { 138 IP6STAT_INC(ip6s_cantforward); 139 /* XXX in6_ifstat_inc(rt->rt_ifp, ifs6_in_discard) */ | 34 35#include "opt_inet.h" 36#include "opt_inet6.h" 37#include "opt_ipfw.h" 38#include "opt_ipsec.h" 39#include "opt_ipstealth.h" 40 41#include <sys/param.h> --- 90 unchanged lines hidden (view full) --- 132 * Do not forward packets with unspecified source. It was discussed 133 * in July 2000, on the ipngwg mailing list. 134 */ 135 if ((m->m_flags & (M_BCAST|M_MCAST)) != 0 || 136 IN6_IS_ADDR_MULTICAST(&ip6->ip6_dst) || 137 IN6_IS_ADDR_UNSPECIFIED(&ip6->ip6_src)) { 138 IP6STAT_INC(ip6s_cantforward); 139 /* XXX in6_ifstat_inc(rt->rt_ifp, ifs6_in_discard) */ |
140 if (V_ip6_log_time + V_ip6_log_interval < time_second) { 141 V_ip6_log_time = time_second; | 140 if (V_ip6_log_time + V_ip6_log_interval < time_uptime) { 141 V_ip6_log_time = time_uptime; |
142 log(LOG_DEBUG, 143 "cannot forward " 144 "from %s to %s nxt %d received on %s\n", 145 ip6_sprintf(ip6bufs, &ip6->ip6_src), 146 ip6_sprintf(ip6bufd, &ip6->ip6_dst), 147 ip6->ip6_nxt, 148 if_name(m->m_pkthdr.rcvif)); 149 } --- 250 unchanged lines hidden (view full) --- 400#ifdef IPSEC 401 && !ipsecrt 402#endif 403 ) { 404 IP6STAT_INC(ip6s_cantforward); 405 IP6STAT_INC(ip6s_badscope); 406 in6_ifstat_inc(rt->rt_ifp, ifs6_in_discard); 407 | 142 log(LOG_DEBUG, 143 "cannot forward " 144 "from %s to %s nxt %d received on %s\n", 145 ip6_sprintf(ip6bufs, &ip6->ip6_src), 146 ip6_sprintf(ip6bufd, &ip6->ip6_dst), 147 ip6->ip6_nxt, 148 if_name(m->m_pkthdr.rcvif)); 149 } --- 250 unchanged lines hidden (view full) --- 400#ifdef IPSEC 401 && !ipsecrt 402#endif 403 ) { 404 IP6STAT_INC(ip6s_cantforward); 405 IP6STAT_INC(ip6s_badscope); 406 in6_ifstat_inc(rt->rt_ifp, ifs6_in_discard); 407 |
408 if (V_ip6_log_time + V_ip6_log_interval < time_second) { 409 V_ip6_log_time = time_second; | 408 if (V_ip6_log_time + V_ip6_log_interval < time_uptime) { 409 V_ip6_log_time = time_uptime; |
410 log(LOG_DEBUG, 411 "cannot forward " 412 "src %s, dst %s, nxt %d, rcvif %s, outif %s\n", 413 ip6_sprintf(ip6bufs, &ip6->ip6_src), 414 ip6_sprintf(ip6bufd, &ip6->ip6_dst), 415 ip6->ip6_nxt, 416 if_name(m->m_pkthdr.rcvif), if_name(rt->rt_ifp)); 417 } --- 264 unchanged lines hidden --- | 410 log(LOG_DEBUG, 411 "cannot forward " 412 "src %s, dst %s, nxt %d, rcvif %s, outif %s\n", 413 ip6_sprintf(ip6bufs, &ip6->ip6_src), 414 ip6_sprintf(ip6bufd, &ip6->ip6_dst), 415 ip6->ip6_nxt, 416 if_name(m->m_pkthdr.rcvif), if_name(rt->rt_ifp)); 417 } --- 264 unchanged lines hidden --- |