mirror of
https://github.com/nmap/nmap.git
synced 2026-08-04 14:49:29 +00:00
Avoid using commonly-spoofed-closed ports as ping/timing ports
This commit is contained in:
parent
02e3add66e
commit
6680f5648d
1 changed files with 7 additions and 0 deletions
|
|
@ -1796,6 +1796,13 @@ static unsigned int pingprobe_score(const probespec *pspec, int state) {
|
|||
score = 2;
|
||||
else if (pspec->pd.tcp.flags == TH_SYN && (state == PORT_OPEN || state == PORT_UNKNOWN))
|
||||
score = 3;
|
||||
else if (pspec->pd.tcp.dport == 25 ||
|
||||
pspec->pd.tcp.dport == 113 ||
|
||||
pspec->pd.tcp.dport == 135 ||
|
||||
pspec->pd.tcp.dport == 139 ||
|
||||
pspec->pd.tcp.dport == 445)
|
||||
/* Frequently spoofed port numbers */
|
||||
score = 5;
|
||||
else
|
||||
score = 6;
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue