/* these are the changes that were made to /usr/src/sys/netinet/ip_input.c */


/* this includes our header file which contains our function pointers */
#include "/home/jeremiah/networking/choke_module.h"

/* This enables our ipchoke sysctl variable */
int     ipchoke = 0;
/* This is the Macro to define a sysctl */
SYSCTL_INT(_net_inet_ip,242, chokeing, CTLFLAG_RW,
	&ipchoke, 0, "");

/* this is the definition of our function pointer */
ip_choke_t *ip_choke_ptr;

/* This is the enterance to our module, It first checks to see if it's enabled, if so, it gets called. If the return value is less than zero the packet is dropped, and we return from ip_input.c which starts the process all over again */
    if (ipchoke){
      i = (*ip_choke_ptr)(&m);
      if (i < 0){
	m_freem(m);
	return;
      }
      
    }
