/dports/net-mgmt/pads/pads-1.2/src/ |
H A D | packet.c | 203 if((ntohs(tcph->th_dport) == 20) && (ntohs(tcph->th_sport) > 1024)) in process_tcp() 205 if((ntohs(tcph->th_dport) == 21) && (ntohs(tcph->th_sport) > 1024)) in process_tcp() 209 if(check_tcp_asset(ip_src, tcph->th_sport)) { in process_tcp() 210 add_asset(ip_src, tcph->th_sport, in process_tcp() 214 print_stat(ip_src, tcph->th_sport, IPPROTO_TCP); in process_tcp() 228 if(tcp_identify(ip_src, tcph->th_sport, payload, in process_tcp()
|
/dports/net/nast/nast-0.2.0/ncurses/ |
H A D | n_rst.c | 89 …r_add(ip_src,ip_dst,htons(tcp->th_sport),htons(tcp->th_dport),htonl (tcp->th_seq), htonl (tcp->th_… in rst_connection_db() 95 r_del(ip_src,ip_dst,htons(tcp->th_sport),htons(tcp->th_dport),Rst); in rst_connection_db() 98 …r_add(ip_src,ip_dst,htons(tcp->th_sport),htons(tcp->th_dport),htonl (tcp->th_seq), htonl (tcp->th_… in rst_connection_db() 101 …r_add(ip_src,ip_dst,htons(tcp->th_sport),htons(tcp->th_dport),htonl (tcp->th_seq), htonl (tcp->th_… in rst_connection_db() 104 r_del(ip_src,ip_dst,htons(tcp->th_sport),htons(tcp->th_dport),Fin); in rst_connection_db() 106 r_del(ip_src,ip_dst,htons(tcp->th_sport),htons(tcp->th_dport),Rst); in rst_connection_db() 122 …r_add(ip_dst,ip_src,htons(tcp->th_sport),htons(tcp->th_dport),htonl (tcp->th_seq), htonl (tcp->th_… in rst_connection_db() 125 …r_add(ip_dst,ip_src,htons(tcp->th_sport),htons(tcp->th_dport),htonl (tcp->th_seq), htonl (tcp->th_… in rst_connection_db() 128 r_del(ip_dst,ip_src,htons(tcp->th_sport),htons(tcp->th_dport),Rst); in rst_connection_db() 137 r_del(ip_dst,ip_src,htons(tcp->th_sport),htons(tcp->th_dport),Fin); in rst_connection_db() [all …]
|
H A D | n_conn.c | 102 add(ip_src,ip_dst,htons(tcp->th_sport),htons(tcp->th_dport)); in connection() 107 del(ip_src,ip_dst,htons(tcp->th_sport),htons(tcp->th_dport),Rst); in connection() 114 del(ip_src,ip_dst,htons(tcp->th_sport),htons(tcp->th_dport),Fin); in connection() 116 del(ip_src,ip_dst,htons(tcp->th_sport),htons(tcp->th_dport),Rst); in connection() 129 add(ip_dst,ip_src,htons(tcp->th_sport),htons(tcp->th_dport)); in connection() 134 del(ip_dst,ip_src,htons(tcp->th_sport),htons(tcp->th_dport),Rst); in connection() 141 del(ip_dst,ip_src,htons(tcp->th_sport),htons(tcp->th_dport),Fin); in connection() 143 del(ip_dst,ip_src,htons(tcp->th_sport),htons(tcp->th_dport),Rst); in connection()
|
/dports/net/ndisc6/ndisc6-1.0.5/src/ |
H A D | trace-tcp.c | 60 packet->th.th_sport = sport; in send_syn_probe() 80 || (pth->th_sport != port) in parse_syn_resp() 104 || (pth->th_sport != sport) in parse_syn_error() 138 packet->th.th_sport = sport; in send_ack_probe() 158 || (pth->th_sport != port) in parse_ack_resp() 183 || (pth->th_sport != sport) in parse_ack_error()
|
/dports/net-mgmt/bpft/bpft/trafd/ |
H A D | traffic.c | 213 u_short th_sport, u_short th_dport, int proto in calcPortAndServer() argument 216 th_sport = ntohs(th_sport); in calcPortAndServer() 218 if( th_sport < th_dport ) { in calcPortAndServer() 219 *p_port = th_sport; in calcPortAndServer() 222 else if( th_sport > th_dport ) { in calcPortAndServer() 226 else if( th_sport == th_dport ) { in calcPortAndServer() 227 *p_port = th_sport; in calcPortAndServer() 233 *p_port = th_sport; in calcPortAndServer() 240 if (th_sport == th_dport) *who_srv = 3; in calcPortAndServer() 266 tp->th_sport,tp->th_dport,IPPROTO_TCP, [all …]
|
/dports/net/wireshark/wireshark-3.6.1/ui/ |
H A D | tap-tcp-stream.c | 54 tg->dst_port = tcphdr->th_sport; in tapall_tcpip_packet() 60 tcphdr->th_sport, tcphdr->th_dport, in tapall_tcpip_packet() 77 segment->th_sport = tcphdr->th_sport; in tapall_tcpip_packet() 178 tmp->th_sport, tmp->th_dport, in get_num_dsegs() 196 tmp->th_sport, tmp->th_dport, in get_num_acks() 224 stored->th_sport, stored->th_dport, in tap_tcpip_packet() 226 header->th_sport, stored->th_dport, in tap_tcpip_packet()
|
/dports/net/wireshark-lite/wireshark-3.6.1/ui/ |
H A D | tap-tcp-stream.c | 54 tg->dst_port = tcphdr->th_sport; in tapall_tcpip_packet() 60 tcphdr->th_sport, tcphdr->th_dport, in tapall_tcpip_packet() 77 segment->th_sport = tcphdr->th_sport; in tapall_tcpip_packet() 178 tmp->th_sport, tmp->th_dport, in get_num_dsegs() 196 tmp->th_sport, tmp->th_dport, in get_num_acks() 224 stored->th_sport, stored->th_dport, in tap_tcpip_packet() 226 header->th_sport, stored->th_dport, in tap_tcpip_packet()
|
/dports/net/tshark/wireshark-3.6.1/ui/ |
H A D | tap-tcp-stream.c | 54 tg->dst_port = tcphdr->th_sport; in tapall_tcpip_packet() 60 tcphdr->th_sport, tcphdr->th_dport, in tapall_tcpip_packet() 77 segment->th_sport = tcphdr->th_sport; in tapall_tcpip_packet() 178 tmp->th_sport, tmp->th_dport, in get_num_dsegs() 196 tmp->th_sport, tmp->th_dport, in get_num_acks() 224 stored->th_sport, stored->th_dport, in tap_tcpip_packet() 226 header->th_sport, stored->th_dport, in tap_tcpip_packet()
|
/dports/net/tshark-lite/wireshark-3.6.1/ui/ |
H A D | tap-tcp-stream.c | 54 tg->dst_port = tcphdr->th_sport; in tapall_tcpip_packet() 60 tcphdr->th_sport, tcphdr->th_dport, in tapall_tcpip_packet() 77 segment->th_sport = tcphdr->th_sport; in tapall_tcpip_packet() 178 tmp->th_sport, tmp->th_dport, in get_num_dsegs() 196 tmp->th_sport, tmp->th_dport, in get_num_acks() 224 stored->th_sport, stored->th_dport, in tap_tcpip_packet() 226 header->th_sport, stored->th_dport, in tap_tcpip_packet()
|
/dports/net/nast/nast-0.2.0/ |
H A D | bcount.c | 270 … conn_len(ip->ip_src.s_addr,ip->ip_dst.s_addr,htons(tcph->th_sport),htons(tcph->th_dport),tot); in n_bytecounting() 273 … conn_len(ip->ip_src.s_addr,ip->ip_dst.s_addr,htons(tcph->th_sport),htons(tcph->th_dport),tot); in n_bytecounting() 276 … conn_len(ip->ip_src.s_addr,ip->ip_dst.s_addr,htons(tcph->th_sport),htons(tcph->th_dport),tot); in n_bytecounting() 279 … conn_len(ip->ip_src.s_addr,ip->ip_dst.s_addr,htons(tcph->th_sport),htons(tcph->th_dport),tot); in n_bytecounting() 282 … conn_len(ip->ip_src.s_addr,ip->ip_dst.s_addr,htons(tcph->th_sport),htons(tcph->th_dport),tot); in n_bytecounting() 285 … conn_len(ip->ip_src.s_addr,ip->ip_dst.s_addr,htons(tcph->th_sport),htons(tcph->th_dport),tot); in n_bytecounting() 288 … conn_len(ip->ip_src.s_addr,ip->ip_dst.s_addr,htons(tcph->th_sport),htons(tcph->th_dport),tot); in n_bytecounting() 291 … conn_len(ip->ip_src.s_addr,ip->ip_dst.s_addr,htons(tcph->th_sport),htons(tcph->th_dport),tot); in n_bytecounting()
|
H A D | tcp.c | 42 service = getservbyport(htons(ntohs(tcp->th_sport)), "tcp"); in handle_TCP() 43 …n_print("princ",line_s=line_s+2,row_s,lg,"%s:%d(%s)",inet_ntoa(ip->ip_src),ntohs(tcp->th_sport),(s… in handle_TCP() 119 service = getservbyport(htons(ntohs(tcp->th_sport)), "tcp"); in handle_TCP() 120 …fprintf(ldd, "%s:%d(%s) -> ",inet_ntoa(ip->ip_src),ntohs(tcp->th_sport),(service) ? service->s_nam… in handle_TCP()
|
H A D | rst.c | 84 if ((tcp->th_sport != htons(sport)) || (tcp->th_dport != htons(dport))) in rst() 90 if ((tcp->th_sport != htons(sport))) in rst() 101 sport = htons (tcp->th_sport); in rst()
|
H A D | stream.c | 68 …if ( ip->ip_src.s_addr == ip_src && ip->ip_dst.s_addr == ip_dst && tcp->th_sport == htons(sport) &… in stream() 75 …else if ( ip->ip_src.s_addr == ip_dst && ip->ip_dst.s_addr == ip_src && tcp->th_sport == htons(dpo… in stream()
|
/dports/ftp/ftpsesame/ftpsesame-0.95/ |
H A D | state.c | 95 s->s_port = tcp->th_sport; in state_new() 118 if (tcp->th_sport > tcp->th_dport) in state_find() 128 s.s_port = tcp->th_sport; in state_find() 134 s.d_port = tcp->th_sport; in state_find()
|
/dports/net/tcpillust/tcpillust/ |
H A D | binread.c | 196 if ((ntohs(tcp->th_sport) != port1 || in dumpip() 198 (ntohs(tcp->th_sport) != port2 || in dumpip() 226 port1 = ntohs(tcp->th_sport); in dumpip() 258 tpacket[pktcount -1].src_port = ntohs(tcp->th_sport); in dumpip() 337 if ((ntohs(tcp->th_sport) != port1 || in dumpip6() 339 (ntohs(tcp->th_sport) != port2 || in dumpip6() 367 port1 = ntohs(tcp->th_sport); in dumpip6() 401 tpacket[pktcount -1].src_port = ntohs(tcp->th_sport); in dumpip6()
|
/dports/net/zmap/zmap-2.1.1/src/probe_modules/ |
H A D | module_tcp_synscan.c | 58 tcp_header->th_sport = htons(get_src_port(num_ports, in synscan_make_packet() 77 ntohs(tcph->th_sport), in synscan_print_packet() 98 uint16_t sport = tcp->th_sport; in synscan_validate_packet() 122 fs_add_uint64(fs, "sport", (uint64_t) ntohs(tcp->th_sport)); in synscan_process_packet()
|
/dports/security/snort3/snort3-3.1.19.0/src/protocols/ |
H A D | tcp.h | 74 uint16_t th_sport; /* source port */ member 95 { return ntohs(th_sport); } in src_port() 144 { return th_sport; } in raw_src_port()
|
/dports/net/icmpinfo/icmpinfo-1.11/ |
H A D | print.c | 126 ntohs(tp->th_sport),ntohs(tp->th_dport), 129 if ((servent=getservbyport(ntohs(tp->th_sport),NULL))) 131 ntohs(tp->th_sport),servent->s_name); 133 sprintf(prbuf+strlen(prbuf)," sp=%d",tp->th_sport);
|
/dports/net/nepenthes/nepenthes-0.2.2/modules/module-honeytrap/ |
H A D | TrapSocket.cpp | 565 logInfo("Got RST packet from localhost:%i %i\n",ntohs(tcp->th_sport),tcp->th_sport); in doRecv_PCAP() 757 ntohs(tcp->th_sport), in printIPpacket() 790 port = ntohs(tcp->th_sport); // pcap mode in createListener() 812 if ( g_ModuleHoneytrap->socketExists((uint32_t)ip->ip_src.s_addr, ntohs(tcp->th_sport), in createListener() 815 POLLSocket *ps = new PCAPSocket((uint32_t)ip->ip_src.s_addr, ntohs(tcp->th_sport) , in createListener() 820 g_ModuleHoneytrap->socketAdd((uint32_t)ip->ip_src.s_addr, ntohs(tcp->th_sport), in createListener()
|
/dports/net/packter-agent/PackterAgent-2.5/src/ |
H A D | pt_tcp.c | 78 srcip, ntohs(th->th_sport), dstip, ntohs(th->th_dport)); in packter_tcp() 81 packter_mesg(mesg, srcip, dstip, ntohs(th->th_sport),ntohs(th->th_dport), flag, mesgbuf); in packter_tcp()
|
/dports/security/tcpcrypt/tcpcrypt-0.5/src/ |
H A D | cygwin.c | 147 struct conmap *c = find_conmap(tcp->th_sport); in redirect() 153 c->src.sin_port = tcp->th_sport; in redirect() 180 } else if (ntohs(tcp->th_sport) == REDIRECT_PORT) { in redirect() 188 &tcp->th_sport, 80); in redirect() 389 struct conmap *c = find_conmap(tcp->th_sport); in divert_orig_dest()
|
H A D | rdr.c | 207 ipaddr, ntohs(tcp->th_sport), in ip_tuple() 324 port = tcp->th_sport; in send_rst() 325 tcp->th_sport = tcp->th_dport; in send_rst() 492 from.sin_port = tcp->th_sport; in add_connection() 590 tcp->th_sport = s->to.sin_port; in send_syn_ack() 603 if (ntohs(tcp->th_sport) == REDIRECT_PORT in handle_syn_ack() 621 && s->from.sin_port == tcp->th_sport) in get_sock() 739 inet_ntoa(ip->ip_src), ntohs(tcp->th_sport)); in pcap_in_handler()
|
/dports/security/fragrouter/fragrouter-1.6/ |
H A D | tcp_seg.c | 200 libnet_build_tcp(ntohs(tcph->th_sport), ntohs(tcph->th_dport), in tcp_seg_interleave_syns() 240 libnet_build_tcp(ntohs(tcph->th_sport), ntohs(tcph->th_dport), in tcp_seg_prepend_fakeclose() 257 libnet_build_tcp(ntohs(tcph->th_sport), ntohs(tcph->th_dport), in tcp_seg_prepend_fakeclose() 289 libnet_build_tcp(ntohs(tcph->th_sport), ntohs(tcph->th_dport), in tcp_seg_prepend_connection() 306 libnet_build_tcp(ntohs(tcph->th_sport), ntohs(tcph->th_dport), in tcp_seg_prepend_connection() 349 libnet_build_tcp(ntohs(tcph->th_sport), ntohs(tcph->th_dport), in tcp_seg_prepend_junk()
|
/dports/net-mgmt/tcpreplay/tcpreplay-4.3.4/src/tcpedit/ |
H A D | portmap.c | 324 newport = map_port(portmap, tcp_hdr->th_sport); in rewrite_ports() 325 if (newport != tcp_hdr->th_sport) { in rewrite_ports() 326 csum_replace2(&tcp_hdr->th_sum, tcp_hdr->th_sport, newport); in rewrite_ports() 327 tcp_hdr->th_sport = newport; in rewrite_ports()
|
/dports/net/py-libdnet/libdnet-1.13/test/dnet/ |
H A D | tcp.c | 45 tcp->th_sport = rand() & 0xffff; in tcp_main() 59 if (port_aton(value, &tcp->th_sport) < 0) in tcp_main()
|