mirror of
https://github.com/nmap/nmap.git
synced 2026-08-04 06:40:48 +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:
parent
7fc4687e28
commit
f257fa592e
3 changed files with 906 additions and 863 deletions
|
|
@ -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
|
|
@ -3,8 +3,8 @@
|
|||
|
||||
extern struct model FPModel;
|
||||
extern double FPscale[][2];
|
||||
extern double FPmean[][676];
|
||||
extern double FPvariance[][676];
|
||||
extern double FPmean[][689];
|
||||
extern double FPvariance[][689];
|
||||
extern FingerMatch FPmatches[];
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue