mirror of
https://github.com/nmap/nmap.git
synced 2026-01-03 13:19:04 +00:00
Move osscan-related structs to osscan.h from global_structures.h
This commit is contained in:
@@ -127,62 +127,6 @@
|
||||
#ifndef GLOBAL_STRUCTURES_H
|
||||
#define GLOBAL_STRUCTURES_H
|
||||
|
||||
#include <vector>
|
||||
|
||||
struct AVal {
|
||||
const char *attribute;
|
||||
const char *value;
|
||||
|
||||
bool operator<(const AVal& other) const {
|
||||
return strcmp(attribute, other.attribute) < 0;
|
||||
}
|
||||
};
|
||||
|
||||
struct OS_Classification {
|
||||
const char *OS_Vendor;
|
||||
const char *OS_Family;
|
||||
const char *OS_Generation; /* Can be NULL if unclassified */
|
||||
const char *Device_Type;
|
||||
std::vector<const char *> cpe;
|
||||
};
|
||||
|
||||
/* A description of an operating system: a human-readable name and a list of
|
||||
classifications. */
|
||||
struct FingerMatch {
|
||||
int line; /* For reference prints, the line # in nmap-os-db */
|
||||
char *OS_name;
|
||||
std::vector<OS_Classification> OS_class;
|
||||
|
||||
FingerMatch() {
|
||||
line = -1;
|
||||
OS_name = NULL;
|
||||
}
|
||||
};
|
||||
|
||||
struct FingerTest {
|
||||
const char *name;
|
||||
std::vector<struct AVal> results;
|
||||
bool operator<(const FingerTest& other) const {
|
||||
return strcmp(name, other.name) < 0;
|
||||
}
|
||||
};
|
||||
|
||||
struct FingerPrint {
|
||||
FingerMatch match;
|
||||
std::vector<FingerTest> tests;
|
||||
FingerPrint();
|
||||
void sort();
|
||||
};
|
||||
|
||||
/* This structure contains the important data from the fingerprint
|
||||
database (nmap-os-db) */
|
||||
struct FingerPrintDB {
|
||||
FingerPrint *MatchPoints;
|
||||
std::vector<FingerPrint *> prints;
|
||||
|
||||
FingerPrintDB();
|
||||
~FingerPrintDB();
|
||||
};
|
||||
|
||||
struct seq_info {
|
||||
int responses;
|
||||
|
||||
Reference in New Issue
Block a user