[BACK]Return to raw_ip.c CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / sys / netinet

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /src/sys/netinet/raw_ip.c between version 1.107.2.1 and 1.112.6.1

version 1.107.2.1, 2009/05/04 08:14:17 version 1.112.6.1, 2012/02/18 07:35:39
Line 94  __KERNEL_RCSID(0, "$NetBSD$");
Line 94  __KERNEL_RCSID(0, "$NetBSD$");
 #include <netinet/in_proto.h>  #include <netinet/in_proto.h>
 #include <netinet/in_var.h>  #include <netinet/in_var.h>
   
 #include <machine/stdarg.h>  #ifdef KAME_IPSEC
   
 #ifdef IPSEC  
 #include <netinet6/ipsec.h>  #include <netinet6/ipsec.h>
 #include <netinet6/ipsec_private.h>  #include <netinet6/ipsec_private.h>
 #endif /* IPSEC */  #endif /* KAME_IPSEC */
   
 #ifdef FAST_IPSEC  #ifdef FAST_IPSEC
 #include <netipsec/ipsec.h>  #include <netipsec/ipsec.h>
Line 119  int  rip_bind(struct inpcb *, struct mbu
Line 117  int  rip_bind(struct inpcb *, struct mbu
 int      rip_connect(struct inpcb *, struct mbuf *);  int      rip_connect(struct inpcb *, struct mbuf *);
 void     rip_disconnect(struct inpcb *);  void     rip_disconnect(struct inpcb *);
   
   static void sysctl_net_inet_raw_setup(struct sysctllog **);
   
 /*  /*
  * Nominal space allocated to a raw ip socket.   * Nominal space allocated to a raw ip socket.
  */   */
Line 136  void
Line 136  void
 rip_init(void)  rip_init(void)
 {  {
   
           sysctl_net_inet_raw_setup(NULL);
         in_pcbinit(&rawcbtable, 1, 1);          in_pcbinit(&rawcbtable, 1, 1);
 }  }
   
Line 207  rip_input(struct mbuf *m, ...)
Line 208  rip_input(struct mbuf *m, ...)
                         continue;                          continue;
                 if (last == NULL)                  if (last == NULL)
                         ;                          ;
 #if defined(IPSEC) || defined(FAST_IPSEC)  #if defined(KAME_IPSEC) || defined(FAST_IPSEC)
                 /* check AH/ESP integrity. */                  /* check AH/ESP integrity. */
                 else if (ipsec4_in_reject_so(m, last->inp_socket)) {                  else if (ipsec4_in_reject_so(m, last->inp_socket)) {
                         IPSEC_STATINC(IPSEC_STAT_IN_POLVIO);                          IPSEC_STATINC(IPSEC_STAT_IN_POLVIO);
Line 221  rip_input(struct mbuf *m, ...)
Line 222  rip_input(struct mbuf *m, ...)
                 }                  }
                 last = inp;                  last = inp;
         }          }
 #if defined(IPSEC) || defined(FAST_IPSEC)  #if defined(KAME_IPSEC) || defined(FAST_IPSEC)
         /* check AH/ESP integrity. */          /* check AH/ESP integrity. */
         if (last != NULL && ipsec4_in_reject_so(m, last->inp_socket)) {          if (last != NULL && ipsec4_in_reject_so(m, last->inp_socket)) {
                 m_freem(m);                  m_freem(m);
Line 531  rip_usrreq(struct socket *so, int req,
Line 532  rip_usrreq(struct socket *so, int req,
 #endif  #endif
   
         if (req == PRU_CONTROL)          if (req == PRU_CONTROL)
                 return (in_control(so, (long)m, (void *)nam,                  return in_control(so, (long)m, nam, (struct ifnet *)control, l);
                     (struct ifnet *)control, l));  
   
         s = splsoftnet();          s = splsoftnet();
   
Line 551  rip_usrreq(struct socket *so, int req,
Line 551  rip_usrreq(struct socket *so, int req,
         if (req != PRU_SEND && req != PRU_SENDOOB && control)          if (req != PRU_SEND && req != PRU_SENDOOB && control)
                 panic("rip_usrreq: unexpected control mbuf");                  panic("rip_usrreq: unexpected control mbuf");
 #endif  #endif
         if (inp == 0 && req != PRU_ATTACH) {          if (inp == NULL && req != PRU_ATTACH) {
                 error = EINVAL;                  error = EINVAL;
                 goto release;                  goto release;
         }          }
Line 696  release:
Line 696  release:
         return (error);          return (error);
 }  }
   
 SYSCTL_SETUP(sysctl_net_inet_raw_setup, "sysctl net.inet.raw subtree setup")  static void
   sysctl_net_inet_raw_setup(struct sysctllog **clog)
 {  {
   
         sysctl_createv(clog, 0, NULL, NULL,          sysctl_createv(clog, 0, NULL, NULL,

Legend:
Removed from v.1.107.2.1  
changed lines
  Added in v.1.112.6.1

CVSweb <webmaster@jp.NetBSD.org>