mirror of
https://github.com/nmap/nmap.git
synced 2025-12-06 04:31:29 +00:00
Add TCP window/MSS ratio feature for IPv6 OS detection. http://seclists.org/nmap-dev/2015/q2/103 #224
This commit is contained in:
@@ -912,8 +912,8 @@ static struct feature_node *vectorize(const FingerPrintResultsIPv6 *FPR) {
|
||||
|
||||
tcp = find_tcp(resps[probe_name].getPacket());
|
||||
if (tcp == NULL) {
|
||||
/* 48 TCP features. */
|
||||
idx += 48;
|
||||
/* 49 TCP features. */
|
||||
idx += 49;
|
||||
continue;
|
||||
}
|
||||
features[idx++].value = tcp->getWindow();
|
||||
@@ -951,6 +951,10 @@ static struct feature_node *vectorize(const FingerPrintResultsIPv6 *FPR) {
|
||||
features[idx++].value = mss;
|
||||
features[idx++].value = sackok;
|
||||
features[idx++].value = wscale;
|
||||
if (mss != 0 && mss != -1)
|
||||
features[idx++].value = (float)tcp->getWindow() / mss;
|
||||
else
|
||||
features[idx++].value = -1;
|
||||
}
|
||||
assert(idx == nr_feature);
|
||||
|
||||
|
||||
1757
FPModel.cc
1757
FPModel.cc
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user