View | Details | Raw Unified | Return to bug 255388
Collapse All | Expand All

(-)b/sys/netinet/ip_input.c (-6 / +8 lines)
Lines 736-747 ip_input(struct mbuf *m) Link Here
736
		}
736
		}
737
		ia = NULL;
737
		ia = NULL;
738
	}
738
	}
739
	/* RFC 3927 2.7: Do not forward datagrams for 169.254.0.0/16. */
740
	if (IN_LINKLOCAL(ntohl(ip->ip_dst.s_addr))) {
741
		IPSTAT_INC(ips_cantforward);
742
		m_freem(m);
743
		return;
744
	}
745
	if (IN_MULTICAST(ntohl(ip->ip_dst.s_addr))) {
739
	if (IN_MULTICAST(ntohl(ip->ip_dst.s_addr))) {
746
		if (V_ip_mrouter) {
740
		if (V_ip_mrouter) {
747
			/*
741
			/*
Lines 779-784 ip_input(struct mbuf *m) Link Here
779
	if (ip->ip_dst.s_addr == INADDR_ANY)
773
	if (ip->ip_dst.s_addr == INADDR_ANY)
780
		goto ours;
774
		goto ours;
781
775
776
	/* RFC 3927 2.7: Do not forward datagrams for 169.254.0.0/16. */
777
	if (IN_LINKLOCAL(ntohl(ip->ip_src.s_addr)) ||
778
		IN_LINKLOCAL(ntohl(ip->ip_dst.s_addr))) {
779
		IPSTAT_INC(ips_cantforward);
780
		m_freem(m);
781
		return;
782
	}
783
782
	/*
784
	/*
783
	 * Not for us; forward if possible and desirable.
785
	 * Not for us; forward if possible and desirable.
784
	 */
786
	 */

Return to bug 255388