NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

kern/39854: tcp_new_iss1 is used for both ipv4 and ipv6



>Number:         39854
>Category:       kern
>Synopsis:       tcp_new_iss1 is used for both ipv4 and ipv6
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sun Nov 02 15:45:00 +0000 2008
>Originator:     Darren Reed
>Release:        NetBSD 4.0_STABLE
>Organization:
NetBSD
>Environment:
        
        
System: NetBSD narn.netbsd.org 4.0_STABLE NetBSD 4.0_STABLE (NBMAIL) #1: Fri 
Sep 5 16:31:35 UTC 2008 root@ADMIN:/usr/obj/sys/arch/i386/compile.i386/NBMAIL 
i386
Architecture: i386
Machine: i386
>Description:

In /sys/dist/ipf/netinet/ip_fil_netbsd.c, we find this code:
#ifdef INET
        return tcp_new_iss1((void *)&fin->fin_src, (void *)&fin->fin_dst,
                            fin->fin_sport, fin->fin_dport, asz, 0);
#else
        return ENOSYS;
#endif


...which is clearly wrong if we are to use sys/netinet/tcp_subr.c as
a guide - it calls tcp_new_iss1() for both ipv4 and ipv6. So clearly
the #ifdef's here need to vaporise... or change to be
#if defined(INET) || defined(INET6)
... but then it isn't clear why ipfilter would be in the kernel if
this was the case.

>How-To-Repeat:
        
>Fix:
        

>Unformatted:
        
        


Home | Main Index | Thread Index | Old Index