---------- X-Sun-Data-Type: default X-Sun-Data-Description: default X-Sun-Data-Name: Argus-1.5.patch X-Sun-Charset: us-ascii X-Sun-Content-Lines: 232 *** clients/services.c.ORIG Fri Oct 4 11:51:12 1996 --- clients/services.c Fri Oct 4 11:55:46 1996 *************** *** 184,190 **** struct writeStruct *ptr; double seconds; { - if (!(ptr->status & DETAIL)) do_stats (ptr, NULL, 0, seconds); } --- 184,189 ---- *************** *** 199,205 **** { double seconds; ! if ((ptr->status & CON_ESTABLISHED) && (ptr->status & (SAW_SYN_SENT | SAW_SYN ))) { seconds = (double)(((double)(ptr->lasttime.tv_sec-ptr->startime.tv_sec)) + ((ptr->lasttime.tv_usec - ptr->startime.tv_usec)/1000000.0)); --- 198,205 ---- { double seconds; ! if ((!(ptr->status & DETAIL)) && (ptr->status & CON_ESTABLISHED) ! && (ptr->status & (SAW_SYN_SENT | SAW_SYN ))) { seconds = (double)(((double)(ptr->lasttime.tv_sec-ptr->startime.tv_sec)) + ((ptr->lasttime.tv_usec - ptr->startime.tv_usec)/1000000.0)); *************** *** 248,254 **** } else stats = &total_stats; ! if (ptr->src_bytes > 0) { do_particular_stats (ptr, stats, seconds); if ((index == DST) || !(net_obj)) --- 248,254 ---- } else stats = &total_stats; ! if (ptr->src_bytes || ptr->dst_bytes) { do_particular_stats (ptr, stats, seconds); if ((index == DST) || !(net_obj)) *************** *** 549,566 **** if (start = port) { do { ! if (port->stats.src.bytes != 0) { ! switch (port->proto) { ! case TCP: servstr = tcpport_string(port->port); ! protostr = "tcp"; break; ! case UDP: servstr = udpport_string(port->port); ! protostr = "udp"; break; ! default: servstr = " "; ! protostr = "unk"; break; ! } ! sprintf (str, "\n%s %s %6.6s ", string, protostr, servstr); ! print_stats_data (str, &port->stats); } port = port->nxt; } while (port != start); } --- 549,564 ---- if (start = port) { do { ! switch (port->proto) { ! case TCP: servstr = tcpport_string(port->port); ! protostr = "tcp"; break; ! case UDP: servstr = udpport_string(port->port); ! protostr = "udp"; break; ! default: servstr = " "; ! protostr = "unk"; break; } + sprintf (str, "\n%s %s %6.6s ", string, protostr, servstr); + print_stats_data (str, &port->stats); port = port->nxt; } while (port != start); } *** configure.ORIG Mon May 8 23:13:03 1995 --- configure Thu Oct 10 10:54:01 1996 *************** *** 2,10 **** if ( ! -f lib/libpcap.a || ! -d libpcap ) then if ( ! -d libpcap || ! -r libpcap/libpcap.a ) then set libpcapdir ! set dir=`ls .. | egrep '^libpcap-[0-9]*\.[0-9ab]*$'` if ( $#dir > 1 ) set dir="$dir[$#dir]" ! foreach d ( /usr/lib /usr/local/lib ../libpcap ../$dir ) if ( -d $d && -r $d/libpcap.a ) then set libpcapdir=$d break --- 2,10 ---- if ( ! -f lib/libpcap.a || ! -d libpcap ) then if ( ! -d libpcap || ! -r libpcap/libpcap.a ) then set libpcapdir ! set dir=`ls .. | egrep '^libpcap-[0-9]*\.[0-9]*\.[0-9ab]*$'` if ( $#dir > 1 ) set dir="$dir[$#dir]" ! foreach d ( ../libpcap ../$dir /usr/lib /usr/local/lib ) if ( -d $d && -r $d/libpcap.a ) then set libpcapdir=$d break *************** *** 36,42 **** if ( ! -d wrapper || ! -r wrapper/libwrap.a ) then set dir=`ls .. | egrep '^wrapper$|^tcp_wrappers$|^tcp_wrappers[_-.][0-9]*\.[0-9ab]*$'| sort -ru | sed 's/^/..\//'` # if ( $#dir > 1 ) set dir="$dir[$#dir]" ! foreach d ( /usr/lib /usr/local/lib $dir ) if ( -d $d && -r $d/libwrap.a && -r $d/patchlevel.h) then set tcp_wrapperdir=$d break --- 36,42 ---- if ( ! -d wrapper || ! -r wrapper/libwrap.a ) then set dir=`ls .. | egrep '^wrapper$|^tcp_wrappers$|^tcp_wrappers[_-.][0-9]*\.[0-9ab]*$'| sort -ru | sed 's/^/..\//'` # if ( $#dir > 1 ) set dir="$dir[$#dir]" ! foreach d ( $dir /usr/lib /usr/local/lib ) if ( -d $d && -r $d/libwrap.a && -r $d/patchlevel.h) then set tcp_wrapperdir=$d break *** server/Makefile.in.ORIG Tue Oct 8 16:15:05 1996 --- server/Makefile.in Tue Oct 8 16:15:54 1996 *************** *** 99,104 **** --- 99,106 ---- #have-tcpwrapper-7.0#TVERS = -DWRAPVERS7 #have-tcpwrapper-7.1#TVERS = -DWRAPVERS7 #have-tcpwrapper-7.2#TVERS = -DWRAPVERS7 + #have-tcpwrapper-7.3#TVERS = -DWRAPVERS7 + #have-tcpwrapper-7.4#TVERS = -DWRAPVERS7 TFLAGS = $(TVERS) -DPARANOID -DHOSTS_ACCESS -DKILL_IP_OPTIONS #have-sunos#TFLAGS = $(TVERS) -DPARANOID -DHOSTS_ACCESS *** clients/ra.c.ORIG Mon May 8 23:12:58 1995 --- clients/ra.c Fri Oct 25 15:23:23 1996 *************** *** 281,288 **** char *icmptypestr[ICMP_MAXTYPE + 1] = { ! "ECR", " ", " ", "UR", "SRC", "RED", ! " ", " ", "ECO", " ", " ", "TIM", "PAR", "TST", "TSR", "IRQ", "IRR", "MAS", "MSR", }; --- 281,288 ---- char *icmptypestr[ICMP_MAXTYPE + 1] = { ! "ECR", " 1", " 2", "UR", "SRC", "RED", ! " 6", " 7", "ECO", " 9", " 10", "TIM", "PAR", "TST", "TSR", "IRQ", "IRR", "MAS", "MSR", }; *************** *** 306,312 **** if (ptr) { icmp = (struct icmpStruct *) &ptr->src_count; bzero (icmptype, sizeof (icmptype)); ! strcpy (icmptype, icmptypestr[icmp->type]); esrcString = etheraddr_string ((char *) &ptr->ethersrc); edstString = etheraddr_string ((char *) &ptr->etherdst); srcString = ipaddr_string (&ptr->addr.src); --- 306,315 ---- if (ptr) { icmp = (struct icmpStruct *) &ptr->src_count; bzero (icmptype, sizeof (icmptype)); ! if (icmp->type > ICMP_MAXTYPE) ! sprintf(icmptype, "%d", icmp->type); ! else ! strcpy (icmptype, icmptypestr[icmp->type]); esrcString = etheraddr_string ((char *) &ptr->ethersrc); edstString = etheraddr_string ((char *) &ptr->etherdst); srcString = ipaddr_string (&ptr->addr.src); *************** *** 320,328 **** if (Iflag) if (icmp->dstaddr.s_addr) { u_long addr = icmp->dstaddr.s_addr; ! sprintf (&icmptype[strlen(icmptype)], " %s", ! getnetname (getnetnumber (addr & ! ipaddrtonetmask (addr)))); } break; case ICMP_UNREACH_HOST: *** common/argus_parse.c.ORIG Mon May 8 23:13:04 1995 --- common/argus_parse.c Tue Nov 12 14:00:16 1996 *************** *** 632,643 **** if (tmp->status & IPPROTOMASK) { tmp->status |= IPPROTO; ! if ((dport > sport) && (sport != 0)) { ! tmp->status |= REVERSE; ! sport = ((unsigned short *) &tmp->addr.port)[1]; ! dport = ((unsigned short *) &tmp->addr.port)[0]; ! } switch (tmp->status & IPPROTOMASK) { case TCPPROTO: if (dport == 20) --- 632,649 ---- if (tmp->status & IPPROTOMASK) { tmp->status |= IPPROTO; ! if (!((tmp->status & TCPPROTO) && ! ((tmp->status & SAW_SYN) || ! (tmp->status & SAW_SYN_SENT)))) ! ! if ((dport > sport) && (sport != 0)) { ! tmp->status |= REVERSE; ! sport = ((unsigned short *) &tmp->addr.port)[1]; ! dport = ((unsigned short *) &tmp->addr.port)[0]; ! } + + switch (tmp->status & IPPROTOMASK) { case TCPPROTO: if (dport == 20)