Changeset 736
- Timestamp:
- 01/12/07 11:01:02 (2 years ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
nepenthes/trunk/modules/module-honeytrap/TrapSocket.cpp
r691 r736 783 783 printIPpacket(data,size); 784 784 785 uint16_t port; 786 787 if ( tcp->th_flags & TH_SYN && !(tcp->th_flags & TH_ACK) ) 788 port = ntohs(tcp->th_dport); // inline mode 789 else 790 port = ntohs(tcp->th_sport); // pcap mode 791 785 792 if (1)// isPortListening(ntohs(tcp->th_dport),*(uint32_t *)&(ip->ip_dst)) == false ) 786 793 { 787 logInfo("Connection to unbound port %i requested, binding port\n", ntohs(tcp->th_dport));788 789 Socket *sock = g_Nepenthes->getSocketMgr()->bindTCPSocket(INADDR_ANY, ntohs(tcp->th_dport),60,60);794 logInfo("Connection to unbound port %i requested, binding port\n",port); 795 796 Socket *sock = g_Nepenthes->getSocketMgr()->bindTCPSocket(INADDR_ANY,port,60,60); 790 797 if ( sock != NULL && (sock->getDialogst()->size() == 0 && sock->getFactories()->size() == 0) ) 791 798 {
