Major code cleanup
Converted some not popular protocols to NDPI_PROTOCOL_GENERIC with category detection
This commit is contained in:
+1
-1
@@ -2,7 +2,7 @@
|
||||
|
||||
NDPI_MAJOR="2"
|
||||
NDPI_MINOR="3"
|
||||
NDPI_PATCH="0"
|
||||
NDPI_PATCH="1"
|
||||
NDPI_VERSION_SHORT="$NDPI_MAJOR.$NDPI_MINOR.$NDPI_PATCH"
|
||||
|
||||
rm -f configure config.h config.h.in src/lib/Makefile.in
|
||||
|
||||
+1
-1
@@ -119,7 +119,7 @@ AC_ARG_ENABLE([debug-messages],
|
||||
|
||||
AC_CHECK_LIB(pthread, pthread_setaffinity_np, AC_DEFINE_UNQUOTED(HAVE_PTHREAD_SETAFFINITY_NP, 1, [libc has pthread_setaffinity_np]))
|
||||
|
||||
AC_CONFIG_FILES([Makefile src/lib/Makefile example/Makefile tests/Makefile libndpi.pc src/include/ndpi_define.h])
|
||||
AC_CONFIG_FILES([Makefile example/Makefile tests/Makefile libndpi.pc src/include/ndpi_define.h])
|
||||
AC_CONFIG_HEADERS(src/include/ndpi_config.h)
|
||||
AC_SUBST(GIT_RELEASE)
|
||||
AC_SUBST(NDPI_MAJOR)
|
||||
|
||||
+2
-2
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* ndpi_util.h
|
||||
*
|
||||
* Copyright (C) 2011-16 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* nDPI is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU Lesser General Public License as published by
|
||||
@@ -24,7 +24,7 @@
|
||||
* If you concern about performance or have to integrate nDPI in your
|
||||
* application, you could need to reimplement them yourself.
|
||||
*
|
||||
* WARNING: this API is unstable! Use it at your own risk!
|
||||
* WARNING: this API is just a demo od nDPI usage: Use it at your own risk!
|
||||
*/
|
||||
#ifndef __NDPI_UTIL_H__
|
||||
#define __NDPI_UTIL_H__
|
||||
|
||||
@@ -606,7 +606,7 @@ extern "C" {
|
||||
void ndpi_set_automa(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
void* automa);
|
||||
|
||||
#ifdef NDPI_PROTOCOL_HTTP
|
||||
/* NDPI_PROTOCOL_HTTP */
|
||||
/**
|
||||
* Retrieve information for HTTP flows
|
||||
*
|
||||
@@ -639,9 +639,8 @@ extern "C" {
|
||||
*/
|
||||
char* ndpi_get_http_content_type(struct ndpi_detection_module_struct *ndpi_mod,
|
||||
struct ndpi_flow_struct *flow);
|
||||
#endif
|
||||
|
||||
#ifdef NDPI_PROTOCOL_TOR
|
||||
/* NDPI_PROTOCOL_TOR */
|
||||
/**
|
||||
* Check if the flow could be detected as TOR protocol
|
||||
*
|
||||
@@ -654,7 +653,6 @@ extern "C" {
|
||||
*/
|
||||
int ndpi_is_ssl_tor(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
struct ndpi_flow_struct *flow, char *certificate);
|
||||
#endif
|
||||
|
||||
/* Wrappers functions */
|
||||
/**
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* ndpi_main.h
|
||||
*
|
||||
* Copyright (C) 2011-16 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -105,9 +105,8 @@ extern "C" {
|
||||
extern int ndpi_get_protocol_id_master_proto(struct ndpi_detection_module_struct *ndpi_struct, u_int16_t protocol_id,
|
||||
u_int16_t** tcp_master_proto,
|
||||
u_int16_t** udp_master_proto);
|
||||
#ifdef NDPI_PROTOCOL_NETBIOS
|
||||
#/* NDPI_PROTOCOL_NETBIOS */
|
||||
int ndpi_netbios_name_interpret(char *in, char *out, u_int out_len);
|
||||
#endif
|
||||
|
||||
#ifdef NDPI_ENABLE_DEBUG_MESSAGES
|
||||
void ndpi_debug_get_last_log_function_line(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
|
||||
+259
-261
@@ -33,267 +33,265 @@
|
||||
#define NDPI_DETECTION_SUPPORT_IPV6
|
||||
#define NDPI_PROTOCOL_SIZE 2
|
||||
|
||||
#define NDPI_PROTOCOL_UNKNOWN 0
|
||||
typedef enum {
|
||||
NDPI_PROTOCOL_UNKNOWN = 0,
|
||||
NDPI_PROTOCOL_FTP_CONTROL = 1, /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
NDPI_PROTOCOL_MAIL_POP = 2,
|
||||
NDPI_PROTOCOL_MAIL_SMTP = 3,
|
||||
NDPI_PROTOCOL_MAIL_IMAP = 4,
|
||||
NDPI_PROTOCOL_DNS = 5,
|
||||
NDPI_PROTOCOL_IPP = 6,
|
||||
NDPI_PROTOCOL_HTTP = 7,
|
||||
NDPI_PROTOCOL_MDNS = 8,
|
||||
NDPI_PROTOCOL_NTP = 9,
|
||||
NDPI_PROTOCOL_NETBIOS = 10,
|
||||
NDPI_PROTOCOL_NFS = 11,
|
||||
NDPI_PROTOCOL_SSDP = 12,
|
||||
NDPI_PROTOCOL_BGP = 13,
|
||||
NDPI_PROTOCOL_SNMP = 14,
|
||||
NDPI_PROTOCOL_XDMCP = 15,
|
||||
NDPI_PROTOCOL_SMB = 16,
|
||||
NDPI_PROTOCOL_SYSLOG = 17,
|
||||
NDPI_PROTOCOL_DHCP = 18,
|
||||
NDPI_PROTOCOL_POSTGRES = 19,
|
||||
NDPI_PROTOCOL_MYSQL = 20,
|
||||
NDPI_PROTOCOL_HOTMAIL = 21,
|
||||
NDPI_PROTOCOL_DIRECT_DOWNLOAD_LINK = 22,
|
||||
NDPI_PROTOCOL_MAIL_POPS = 23,
|
||||
NDPI_PROTOCOL_APPLEJUICE = 24,
|
||||
NDPI_PROTOCOL_DIRECTCONNECT = 25,
|
||||
NDPI_PROTOCOL_NTOP = 26,
|
||||
NDPI_PROTOCOL_COAP = 27,
|
||||
NDPI_PROTOCOL_VMWARE = 28,
|
||||
NDPI_PROTOCOL_MAIL_SMTPS = 29,
|
||||
NDPI_PROTOCOL_FBZERO = 30,
|
||||
NDPI_PROTOCOL_UBNTAC2 = 31, /* Ubiquity UBNT AirControl = 2 - Thomas Fjellstrom <thomas+ndpi@fjellstrom.ca> */
|
||||
NDPI_PROTOCOL_KONTIKI = 32,
|
||||
NDPI_PROTOCOL_OPENFT = 33,
|
||||
NDPI_PROTOCOL_FASTTRACK = 34,
|
||||
NDPI_PROTOCOL_GNUTELLA = 35,
|
||||
NDPI_PROTOCOL_EDONKEY = 36, /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
NDPI_PROTOCOL_BITTORRENT = 37,
|
||||
NDPI_PROTOCOL_SKYPE_CALL_OUT = 38,
|
||||
NDPI_PROTOCOL_MUSICALLY = 39,
|
||||
|
||||
#define NDPI_PROTOCOL_NO_MASTER_PROTO NDPI_PROTOCOL_UNKNOWN
|
||||
NDPI_PROTOCOL_FREE_40 = 40, /* Free */
|
||||
NDPI_PROTOCOL_FREE_41 = 41, /* Free */
|
||||
NDPI_PROTOCOL_FREE_42 = 42, /* Free */
|
||||
NDPI_PROTOCOL_FREE_43 = 43, /* Free */
|
||||
NDPI_PROTOCOL_FREE_44 = 44, /* Free */
|
||||
NDPI_PROTOCOL_FREE_45 = 45, /* Free */
|
||||
NDPI_PROTOCOL_FREE_46 = 46, /* Free */
|
||||
|
||||
NDPI_PROTOCOL_XBOX = 47,
|
||||
NDPI_PROTOCOL_QQ = 48,
|
||||
NDPI_PROTOCOL_SKYPE_CALL_IN = 49,
|
||||
NDPI_PROTOCOL_RTSP = 50,
|
||||
NDPI_PROTOCOL_MAIL_IMAPS = 51,
|
||||
NDPI_PROTOCOL_ICECAST = 52,
|
||||
NDPI_PROTOCOL_PPLIVE = 53, /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
NDPI_PROTOCOL_PPSTREAM = 54,
|
||||
NDPI_PROTOCOL_ZATTOO = 55,
|
||||
NDPI_PROTOCOL_SHOUTCAST = 56,
|
||||
NDPI_PROTOCOL_SOPCAST = 57,
|
||||
NDPI_PROTOCOL_TVANTS = 58,
|
||||
NDPI_PROTOCOL_TVUPLAYER = 59,
|
||||
NDPI_PROTOCOL_HTTP_DOWNLOAD = 60,
|
||||
NDPI_PROTOCOL_QQLIVE = 61,
|
||||
NDPI_PROTOCOL_THUNDER = 62,
|
||||
NDPI_PROTOCOL_SOULSEEK = 63,
|
||||
NDPI_PROTOCOL_SSL_NO_CERT = 64,
|
||||
NDPI_PROTOCOL_IRC = 65,
|
||||
NDPI_PROTOCOL_AYIYA = 66,
|
||||
NDPI_PROTOCOL_UNENCRYPTED_JABBER = 67,
|
||||
NDPI_PROTOCOL_MSN = 68,
|
||||
NDPI_PROTOCOL_OSCAR = 69,
|
||||
NDPI_PROTOCOL_YAHOO = 70,
|
||||
NDPI_PROTOCOL_BATTLEFIELD = 71,
|
||||
NDPI_PROTOCOL_GOOGLE_PLUS = 72,
|
||||
NDPI_PROTOCOL_IP_VRRP = 73,
|
||||
NDPI_PROTOCOL_STEAM = 74, /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
NDPI_PROTOCOL_HALFLIFE2 = 75,
|
||||
NDPI_PROTOCOL_WORLDOFWARCRAFT = 76,
|
||||
NDPI_PROTOCOL_TELNET = 77,
|
||||
NDPI_PROTOCOL_STUN = 78,
|
||||
NDPI_PROTOCOL_IP_IPSEC = 79,
|
||||
NDPI_PROTOCOL_IP_GRE = 80,
|
||||
NDPI_PROTOCOL_IP_ICMP = 81,
|
||||
NDPI_PROTOCOL_IP_IGMP = 82,
|
||||
NDPI_PROTOCOL_IP_EGP = 83,
|
||||
NDPI_PROTOCOL_IP_SCTP = 84,
|
||||
NDPI_PROTOCOL_IP_OSPF = 85,
|
||||
NDPI_PROTOCOL_IP_IP_IN_IP = 86,
|
||||
NDPI_PROTOCOL_RTP = 87,
|
||||
NDPI_PROTOCOL_RDP = 88,
|
||||
NDPI_PROTOCOL_VNC = 89,
|
||||
NDPI_PROTOCOL_PCANYWHERE = 90,
|
||||
NDPI_PROTOCOL_SSL = 91,
|
||||
NDPI_PROTOCOL_SSH = 92,
|
||||
NDPI_PROTOCOL_USENET = 93,
|
||||
NDPI_PROTOCOL_MGCP = 94,
|
||||
NDPI_PROTOCOL_IAX = 95,
|
||||
NDPI_PROTOCOL_TFTP = 96,
|
||||
NDPI_PROTOCOL_AFP = 97,
|
||||
NDPI_PROTOCOL_STEALTHNET = 98,
|
||||
NDPI_PROTOCOL_AIMINI = 99,
|
||||
NDPI_PROTOCOL_SIP = 100,
|
||||
NDPI_PROTOCOL_TRUPHONE = 101,
|
||||
NDPI_PROTOCOL_IP_ICMPV6 = 102,
|
||||
NDPI_PROTOCOL_DHCPV6 = 103,
|
||||
NDPI_PROTOCOL_ARMAGETRON = 104,
|
||||
NDPI_PROTOCOL_CROSSFIRE = 105,
|
||||
NDPI_PROTOCOL_DOFUS = 106,
|
||||
NDPI_PROTOCOL_FIESTA = 107,
|
||||
NDPI_PROTOCOL_FLORENSIA = 108,
|
||||
NDPI_PROTOCOL_GUILDWARS = 109,
|
||||
NDPI_PROTOCOL_HTTP_ACTIVESYNC = 110,
|
||||
NDPI_PROTOCOL_KERBEROS = 111,
|
||||
NDPI_PROTOCOL_LDAP = 112,
|
||||
NDPI_PROTOCOL_MAPLESTORY = 113,
|
||||
NDPI_PROTOCOL_MSSQL_TDS = 114,
|
||||
NDPI_PROTOCOL_PPTP = 115,
|
||||
NDPI_PROTOCOL_WARCRAFT3 = 116,
|
||||
NDPI_PROTOCOL_WORLD_OF_KUNG_FU = 117,
|
||||
NDPI_PROTOCOL_SLACK = 118,
|
||||
NDPI_PROTOCOL_FACEBOOK = 119,
|
||||
NDPI_PROTOCOL_TWITTER = 120,
|
||||
NDPI_PROTOCOL_DROPBOX = 121,
|
||||
NDPI_PROTOCOL_GMAIL = 122,
|
||||
NDPI_PROTOCOL_GOOGLE_MAPS = 123,
|
||||
NDPI_PROTOCOL_YOUTUBE = 124,
|
||||
NDPI_PROTOCOL_SKYPE = 125,
|
||||
NDPI_PROTOCOL_GOOGLE = 126,
|
||||
NDPI_PROTOCOL_DCERPC = 127,
|
||||
NDPI_PROTOCOL_NETFLOW = 128,
|
||||
NDPI_PROTOCOL_SFLOW = 129,
|
||||
NDPI_PROTOCOL_HTTP_CONNECT = 130,
|
||||
NDPI_PROTOCOL_HTTP_PROXY = 131,
|
||||
NDPI_PROTOCOL_CITRIX = 132, /* It also includes the old NDPI_PROTOCOL_CITRIX_ONLINE */
|
||||
NDPI_PROTOCOL_NETFLIX = 133,
|
||||
NDPI_PROTOCOL_LASTFM = 134,
|
||||
NDPI_PROTOCOL_WAZE = 135,
|
||||
NDPI_PROTOCOL_YOUTUBE_UPLOAD = 136, /* Upload files to youtube */
|
||||
NDPI_PROTOCOL_GENERIC = 137, /* Generic protocol used for category matching */
|
||||
NDPI_PROTOCOL_CHECKMK = 138,
|
||||
NDPI_PROTOCOL_AJP = 139, /* Leonn Paiva <leonn.paiva@gmail.com> */
|
||||
NDPI_PROTOCOL_APPLE = 140,
|
||||
NDPI_PROTOCOL_WEBEX = 141,
|
||||
NDPI_PROTOCOL_WHATSAPP = 142,
|
||||
NDPI_PROTOCOL_APPLE_ICLOUD = 143,
|
||||
NDPI_PROTOCOL_VIBER = 144,
|
||||
NDPI_PROTOCOL_APPLE_ITUNES = 145,
|
||||
NDPI_PROTOCOL_RADIUS = 146,
|
||||
NDPI_PROTOCOL_WINDOWS_UPDATE = 147,
|
||||
NDPI_PROTOCOL_TEAMVIEWER = 148, /* xplico.org */
|
||||
NDPI_PROTOCOL_TUENTI = 149,
|
||||
NDPI_PROTOCOL_LOTUS_NOTES = 150,
|
||||
NDPI_PROTOCOL_SAP = 151,
|
||||
NDPI_PROTOCOL_GTP = 152,
|
||||
NDPI_PROTOCOL_UPNP = 153,
|
||||
NDPI_PROTOCOL_LLMNR = 154,
|
||||
NDPI_PROTOCOL_REMOTE_SCAN = 155,
|
||||
NDPI_PROTOCOL_SPOTIFY = 156,
|
||||
NDPI_PROTOCOL_MESSENGER = 157,
|
||||
NDPI_PROTOCOL_H323 = 158, /* Remy Mudingay <mudingay@ill.fr> */
|
||||
NDPI_PROTOCOL_OPENVPN = 159, /* Remy Mudingay <mudingay@ill.fr> */
|
||||
NDPI_PROTOCOL_NOE = 160, /* Remy Mudingay <mudingay@ill.fr> */
|
||||
NDPI_PROTOCOL_CISCOVPN = 161, /* Remy Mudingay <mudingay@ill.fr> */
|
||||
NDPI_PROTOCOL_TEAMSPEAK = 162, /* Remy Mudingay <mudingay@ill.fr> */
|
||||
NDPI_PROTOCOL_TOR = 163, /* Remy Mudingay <mudingay@ill.fr> */
|
||||
NDPI_PROTOCOL_SKINNY = 164, /* Remy Mudingay <mudingay@ill.fr> */
|
||||
NDPI_PROTOCOL_RTCP = 165, /* Remy Mudingay <mudingay@ill.fr> */
|
||||
NDPI_PROTOCOL_RSYNC = 166, /* Remy Mudingay <mudingay@ill.fr> */
|
||||
NDPI_PROTOCOL_ORACLE = 167, /* Remy Mudingay <mudingay@ill.fr> */
|
||||
NDPI_PROTOCOL_CORBA = 168, /* Remy Mudingay <mudingay@ill.fr> */
|
||||
NDPI_PROTOCOL_UBUNTUONE = 169, /* Remy Mudingay <mudingay@ill.fr> */
|
||||
NDPI_PROTOCOL_WHOIS_DAS = 170,
|
||||
NDPI_PROTOCOL_COLLECTD = 171,
|
||||
NDPI_PROTOCOL_SOCKS = 172, /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
NDPI_PROTOCOL_NINTENDO = 173,
|
||||
NDPI_PROTOCOL_RTMP = 174, /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
NDPI_PROTOCOL_FTP_DATA = 175, /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
NDPI_PROTOCOL_WIKIPEDIA = 176, /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
NDPI_PROTOCOL_ZMQ = 177,
|
||||
NDPI_PROTOCOL_AMAZON = 178, /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
NDPI_PROTOCOL_EBAY = 179, /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
NDPI_PROTOCOL_CNN = 180, /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
NDPI_PROTOCOL_MEGACO = 181, /* Gianluca Costa <g.costa@xplico.org> */
|
||||
NDPI_PROTOCOL_REDIS = 182,
|
||||
NDPI_PROTOCOL_PANDO = 183, /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
NDPI_PROTOCOL_VHUA = 184,
|
||||
NDPI_PROTOCOL_TELEGRAM = 185, /* Gianluca Costa <g.costa@xplico.org> */
|
||||
NDPI_PROTOCOL_VEVO = 186,
|
||||
NDPI_PROTOCOL_PANDORA = 187,
|
||||
NDPI_PROTOCOL_QUIC = 188, /* Andrea Buscarinu <andrea.buscarinu@gmail.com> - Michele Campus <michelecampus5@gmail.com> */
|
||||
NDPI_PROTOCOL_WHATSAPP_VOICE = 189,
|
||||
NDPI_PROTOCOL_EAQ = 190,
|
||||
NDPI_PROTOCOL_OOKLA = 191,
|
||||
NDPI_PROTOCOL_AMQP = 192,
|
||||
NDPI_PROTOCOL_KAKAOTALK = 193, /* KakaoTalk Chat (no voice call) */
|
||||
NDPI_PROTOCOL_KAKAOTALK_VOICE = 194, /* KakaoTalk Voice */
|
||||
NDPI_PROTOCOL_TWITCH = 195, /* Edoardo Dominici <edoaramis@gmail.com> */
|
||||
NDPI_PROTOCOL_FREE_196 = 196, /* Free */
|
||||
NDPI_PROTOCOL_WECHAT = 197,
|
||||
NDPI_PROTOCOL_MPEGTS = 198,
|
||||
NDPI_PROTOCOL_SNAPCHAT = 199,
|
||||
NDPI_PROTOCOL_SINA = 200,
|
||||
NDPI_PROTOCOL_HANGOUT = 201,
|
||||
NDPI_PROTOCOL_IFLIX = 202, /* www.vizuamatix.com R&D team & M.Mallawaarachchie <manoj_ws@yahoo.com> */
|
||||
NDPI_PROTOCOL_GITHUB = 203,
|
||||
NDPI_PROTOCOL_BJNP = 204,
|
||||
NDPI_PROTOCOL_FREE_205 = 205, /* Free */
|
||||
NDPI_PROTOCOL_VIDTO = 206,
|
||||
NDPI_PROTOCOL_SMPP = 207, /* Damir Franusic <df@release14.org> */
|
||||
NDPI_PROTOCOL_DNSCRYPT = 208,
|
||||
NDPI_PROTOCOL_TINC = 209, /* William Guglielmo <william@deselmo.com> */
|
||||
NDPI_PROTOCOL_DEEZER = 210,
|
||||
NDPI_PROTOCOL_INSTAGRAM = 211, /* Andrea Buscarinu <andrea.buscarinu@gmail.com> */
|
||||
NDPI_PROTOCOL_MICROSOFT = 212,
|
||||
NDPI_PROTOCOL_STARCRAFT = 213, /* Matteo Bracci <matteobracci1@gmail.com> */
|
||||
NDPI_PROTOCOL_TEREDO = 214,
|
||||
NDPI_PROTOCOL_HOTSPOT_SHIELD = 215,
|
||||
NDPI_PROTOCOL_HEP = 216, /* sipcapture.org QXIP BV */
|
||||
NDPI_PROTOCOL_GOOGLE_DRIVE = 217,
|
||||
NDPI_PROTOCOL_OCS = 218,
|
||||
NDPI_PROTOCOL_OFFICE_365 = 219,
|
||||
NDPI_PROTOCOL_CLOUDFLARE = 220,
|
||||
NDPI_PROTOCOL_MS_ONE_DRIVE = 221,
|
||||
NDPI_PROTOCOL_MQTT = 222,
|
||||
NDPI_PROTOCOL_RX = 223,
|
||||
NDPI_PROTOCOL_APPLESTORE = 224,
|
||||
NDPI_PROTOCOL_OPENDNS = 225,
|
||||
NDPI_PROTOCOL_GIT = 226,
|
||||
NDPI_PROTOCOL_DRDA = 227,
|
||||
NDPI_PROTOCOL_PLAYSTORE = 228,
|
||||
NDPI_PROTOCOL_SOMEIP = 229,
|
||||
NDPI_PROTOCOL_FIX = 230,
|
||||
NDPI_PROTOCOL_PLAYSTATION = 231,
|
||||
NDPI_PROTOCOL_PASTEBIN = 232, /* Paulo Angelo <pa@pauloangelo.com> */
|
||||
NDPI_PROTOCOL_LINKEDIN = 233, /* Paulo Angelo <pa@pauloangelo.com> */
|
||||
NDPI_PROTOCOL_SOUNDCLOUD = 234,
|
||||
NDPI_PROTOCOL_CSGO = 235, /* Counter-Strike Global Offensive, Dota = 2 */
|
||||
NDPI_PROTOCOL_LISP = 236,
|
||||
NDPI_PROTOCOL_DIAMETER = 237,
|
||||
NDPI_PROTOCOL_APPLE_PUSH = 238,
|
||||
NDPI_PROTOCOL_GOOGLE_SERVICES = 239,
|
||||
NDPI_PROTOCOL_AMAZON_VIDEO = 240,
|
||||
NDPI_PROTOCOL_GOOGLE_DOCS = 241,
|
||||
NDPI_PROTOCOL_WHATSAPP_FILES = 242, /* Videos, pictures, voice messages... */
|
||||
/*
|
||||
IMPORTANT
|
||||
before allocating a new identifier please fill up
|
||||
one of those named NDPI_PROTOCOL_FREE_XXX and not used
|
||||
(placeholders to avoid protocol renumbering)
|
||||
*/
|
||||
|
||||
|
||||
/* IMPORTANT:NDPI_LAST_IMPLEMENTED_PROTOCOL MUST BE THE LAST ELEMENT */
|
||||
NDPI_LAST_IMPLEMENTED_PROTOCOL
|
||||
} ndpi_protocol_ids;
|
||||
|
||||
#define NDPI_PROTOCOL_UNKNOWN 0
|
||||
#define NDPI_PROTOCOL_FTP_CONTROL 1 /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
#define NDPI_PROTOCOL_MAIL_POP 2
|
||||
#define NDPI_PROTOCOL_MAIL_SMTP 3
|
||||
#define NDPI_PROTOCOL_MAIL_IMAP 4
|
||||
#define NDPI_PROTOCOL_DNS 5
|
||||
#define NDPI_PROTOCOL_IPP 6
|
||||
#define NDPI_PROTOCOL_HTTP 7
|
||||
#define NDPI_PROTOCOL_MDNS 8
|
||||
#define NDPI_PROTOCOL_NTP 9
|
||||
#define NDPI_PROTOCOL_NETBIOS 10
|
||||
#define NDPI_PROTOCOL_NFS 11
|
||||
#define NDPI_PROTOCOL_SSDP 12
|
||||
#define NDPI_PROTOCOL_BGP 13
|
||||
#define NDPI_PROTOCOL_SNMP 14
|
||||
#define NDPI_PROTOCOL_XDMCP 15
|
||||
#define NDPI_PROTOCOL_SMB 16
|
||||
#define NDPI_PROTOCOL_SYSLOG 17
|
||||
#define NDPI_PROTOCOL_DHCP 18
|
||||
#define NDPI_PROTOCOL_POSTGRES 19
|
||||
#define NDPI_PROTOCOL_MYSQL 20
|
||||
#define NDPI_PROTOCOL_HOTMAIL 21
|
||||
#define NDPI_PROTOCOL_DIRECT_DOWNLOAD_LINK 22
|
||||
#define NDPI_PROTOCOL_MAIL_POPS 23
|
||||
#define NDPI_PROTOCOL_APPLEJUICE 24
|
||||
#define NDPI_PROTOCOL_DIRECTCONNECT 25
|
||||
#define NDPI_PROTOCOL_NTOP 26
|
||||
#define NDPI_PROTOCOL_COAP 27
|
||||
#define NDPI_PROTOCOL_VMWARE 28
|
||||
#define NDPI_PROTOCOL_MAIL_SMTPS 29
|
||||
#define NDPI_PROTOCOL_FBZERO 30
|
||||
#define NDPI_PROTOCOL_UBNTAC2 31 /* Ubiquity UBNT AirControl 2 - Thomas Fjellstrom <thomas+ndpi@fjellstrom.ca> */
|
||||
#define NDPI_PROTOCOL_KONTIKI 32
|
||||
#define NDPI_PROTOCOL_OPENFT 33
|
||||
#define NDPI_PROTOCOL_FASTTRACK 34
|
||||
#define NDPI_PROTOCOL_GNUTELLA 35
|
||||
#define NDPI_PROTOCOL_EDONKEY 36 /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
#define NDPI_PROTOCOL_BITTORRENT 37
|
||||
#define NDPI_PROTOCOL_SKYPE_CALL_OUT 38
|
||||
#define NDPI_PROTOCOL_MUSICALLY 39
|
||||
|
||||
/* 40..46 are free */
|
||||
#define NDPI_PROTOCOL_FREE_40 40
|
||||
#define NDPI_PROTOCOL_FREE_41 41
|
||||
#define NDPI_PROTOCOL_FREE_42 42
|
||||
#define NDPI_PROTOCOL_FREE_43 43
|
||||
#define NDPI_PROTOCOL_FREE_44 44
|
||||
#define NDPI_PROTOCOL_FREE_45 45
|
||||
#define NDPI_PROTOCOL_FREE_46 46
|
||||
|
||||
#define NDPI_PROTOCOL_XBOX 47
|
||||
#define NDPI_PROTOCOL_QQ 48
|
||||
#define NDPI_PROTOCOL_SKYPE_CALL_IN 49
|
||||
#define NDPI_PROTOCOL_RTSP 50
|
||||
#define NDPI_PROTOCOL_MAIL_IMAPS 51
|
||||
#define NDPI_PROTOCOL_ICECAST 52
|
||||
#define NDPI_PROTOCOL_PPLIVE 53 /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
#define NDPI_PROTOCOL_PPSTREAM 54
|
||||
#define NDPI_PROTOCOL_ZATTOO 55
|
||||
#define NDPI_PROTOCOL_SHOUTCAST 56
|
||||
#define NDPI_PROTOCOL_SOPCAST 57
|
||||
#define NDPI_PROTOCOL_TVANTS 58
|
||||
#define NDPI_PROTOCOL_TVUPLAYER 59
|
||||
#define NDPI_PROTOCOL_HTTP_DOWNLOAD 60
|
||||
#define NDPI_PROTOCOL_QQLIVE 61
|
||||
#define NDPI_PROTOCOL_THUNDER 62
|
||||
#define NDPI_PROTOCOL_SOULSEEK 63
|
||||
#define NDPI_PROTOCOL_SSL_NO_CERT 64
|
||||
#define NDPI_PROTOCOL_IRC 65
|
||||
#define NDPI_PROTOCOL_AYIYA 66
|
||||
#define NDPI_PROTOCOL_UNENCRYPTED_JABBER 67
|
||||
#define NDPI_PROTOCOL_MSN 68
|
||||
#define NDPI_PROTOCOL_OSCAR 69
|
||||
#define NDPI_PROTOCOL_YAHOO 70
|
||||
#define NDPI_PROTOCOL_BATTLEFIELD 71
|
||||
#define NDPI_PROTOCOL_GOOGLE_PLUS 72
|
||||
#define NDPI_PROTOCOL_IP_VRRP 73
|
||||
#define NDPI_PROTOCOL_STEAM 74 /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
#define NDPI_PROTOCOL_HALFLIFE2 75
|
||||
#define NDPI_PROTOCOL_WORLDOFWARCRAFT 76
|
||||
#define NDPI_PROTOCOL_TELNET 77
|
||||
#define NDPI_PROTOCOL_STUN 78
|
||||
#define NDPI_PROTOCOL_IP_IPSEC 79
|
||||
#define NDPI_PROTOCOL_IP_GRE 80
|
||||
#define NDPI_PROTOCOL_IP_ICMP 81
|
||||
#define NDPI_PROTOCOL_IP_IGMP 82
|
||||
#define NDPI_PROTOCOL_IP_EGP 83
|
||||
#define NDPI_PROTOCOL_IP_SCTP 84
|
||||
#define NDPI_PROTOCOL_IP_OSPF 85
|
||||
#define NDPI_PROTOCOL_IP_IP_IN_IP 86
|
||||
#define NDPI_PROTOCOL_RTP 87
|
||||
#define NDPI_PROTOCOL_RDP 88
|
||||
#define NDPI_PROTOCOL_VNC 89
|
||||
#define NDPI_PROTOCOL_PCANYWHERE 90
|
||||
#define NDPI_PROTOCOL_SSL 91
|
||||
#define NDPI_PROTOCOL_SSH 92
|
||||
#define NDPI_PROTOCOL_USENET 93
|
||||
#define NDPI_PROTOCOL_MGCP 94
|
||||
#define NDPI_PROTOCOL_IAX 95
|
||||
#define NDPI_PROTOCOL_TFTP 96
|
||||
#define NDPI_PROTOCOL_AFP 97
|
||||
#define NDPI_PROTOCOL_STEALTHNET 98
|
||||
#define NDPI_PROTOCOL_AIMINI 99
|
||||
#define NDPI_PROTOCOL_SIP 100
|
||||
#define NDPI_PROTOCOL_TRUPHONE 101
|
||||
#define NDPI_PROTOCOL_IP_ICMPV6 102
|
||||
#define NDPI_PROTOCOL_DHCPV6 103
|
||||
#define NDPI_PROTOCOL_ARMAGETRON 104
|
||||
#define NDPI_PROTOCOL_CROSSFIRE 105
|
||||
#define NDPI_PROTOCOL_DOFUS 106
|
||||
#define NDPI_PROTOCOL_FIESTA 107
|
||||
#define NDPI_PROTOCOL_FLORENSIA 108
|
||||
#define NDPI_PROTOCOL_GUILDWARS 109
|
||||
#define NDPI_PROTOCOL_HTTP_APPLICATION_ACTIVESYNC 110 /*avoid large declarations in the future*/
|
||||
#define NDPI_PROTOCOL_KERBEROS 111
|
||||
#define NDPI_PROTOCOL_LDAP 112
|
||||
#define NDPI_PROTOCOL_MAPLESTORY 113
|
||||
#define NDPI_PROTOCOL_MSSQL_TDS 114
|
||||
#define NDPI_PROTOCOL_PPTP 115
|
||||
#define NDPI_PROTOCOL_WARCRAFT3 116
|
||||
#define NDPI_PROTOCOL_WORLD_OF_KUNG_FU 117
|
||||
#define NDPI_PROTOCOL_SLACK 118
|
||||
#define NDPI_PROTOCOL_FACEBOOK 119
|
||||
#define NDPI_PROTOCOL_TWITTER 120
|
||||
#define NDPI_PROTOCOL_DROPBOX 121
|
||||
#define NDPI_PROTOCOL_GMAIL 122
|
||||
#define NDPI_PROTOCOL_GOOGLE_MAPS 123
|
||||
#define NDPI_PROTOCOL_YOUTUBE 124
|
||||
#define NDPI_PROTOCOL_SKYPE 125
|
||||
#define NDPI_PROTOCOL_GOOGLE 126
|
||||
#define NDPI_PROTOCOL_DCERPC 127
|
||||
#define NDPI_PROTOCOL_NETFLOW 128
|
||||
#define NDPI_PROTOCOL_SFLOW 129
|
||||
#define NDPI_PROTOCOL_HTTP_CONNECT 130
|
||||
#define NDPI_PROTOCOL_HTTP_PROXY 131
|
||||
#define NDPI_PROTOCOL_CITRIX 132 /* It includes also the old NDPI_PROTOCOL_CITRIX_ONLINE */
|
||||
#define NDPI_PROTOCOL_NETFLIX 133
|
||||
#define NDPI_PROTOCOL_LASTFM 134
|
||||
#define NDPI_PROTOCOL_WAZE 135
|
||||
#define NDPI_PROTOCOL_YOUTUBE_UPLOAD 136 /* Upload files to youtube */
|
||||
#define NDPI_PROTOCOL_ICQ 137
|
||||
#define NDPI_PROTOCOL_CHECKMK 138
|
||||
#define NDPI_PROTOCOL_AJP 139 /* Leonn Paiva <leonn.paiva@gmail.com>*/
|
||||
#define NDPI_PROTOCOL_APPLE 140
|
||||
#define NDPI_PROTOCOL_WEBEX 141
|
||||
#define NDPI_PROTOCOL_WHATSAPP 142
|
||||
#define NDPI_PROTOCOL_APPLE_ICLOUD 143
|
||||
#define NDPI_PROTOCOL_VIBER 144
|
||||
#define NDPI_PROTOCOL_APPLE_ITUNES 145
|
||||
#define NDPI_PROTOCOL_RADIUS 146
|
||||
#define NDPI_PROTOCOL_WINDOWS_UPDATE 147
|
||||
#define NDPI_PROTOCOL_TEAMVIEWER 148 /* xplico.org */
|
||||
#define NDPI_PROTOCOL_TUENTI 149
|
||||
#define NDPI_PROTOCOL_LOTUS_NOTES 150
|
||||
#define NDPI_PROTOCOL_SAP 151
|
||||
#define NDPI_PROTOCOL_GTP 152
|
||||
#define NDPI_PROTOCOL_UPNP 153
|
||||
#define NDPI_PROTOCOL_LLMNR 154
|
||||
#define NDPI_PROTOCOL_REMOTE_SCAN 155
|
||||
#define NDPI_PROTOCOL_SPOTIFY 156
|
||||
#define NDPI_PROTOCOL_MESSENGER 157
|
||||
#define NDPI_PROTOCOL_H323 158 /* Remy Mudingay <mudingay@ill.fr> */
|
||||
#define NDPI_PROTOCOL_OPENVPN 159 /* Remy Mudingay <mudingay@ill.fr> */
|
||||
#define NDPI_PROTOCOL_NOE 160 /* Remy Mudingay <mudingay@ill.fr> */
|
||||
#define NDPI_PROTOCOL_CISCOVPN 161 /* Remy Mudingay <mudingay@ill.fr> */
|
||||
#define NDPI_PROTOCOL_TEAMSPEAK 162 /* Remy Mudingay <mudingay@ill.fr> */
|
||||
#define NDPI_PROTOCOL_TOR 163 /* Remy Mudingay <mudingay@ill.fr> */
|
||||
#define NDPI_PROTOCOL_SKINNY 164 /* Remy Mudingay <mudingay@ill.fr> */
|
||||
#define NDPI_PROTOCOL_RTCP 165 /* Remy Mudingay <mudingay@ill.fr> */
|
||||
#define NDPI_PROTOCOL_RSYNC 166 /* Remy Mudingay <mudingay@ill.fr> */
|
||||
#define NDPI_PROTOCOL_ORACLE 167 /* Remy Mudingay <mudingay@ill.fr> */
|
||||
#define NDPI_PROTOCOL_CORBA 168 /* Remy Mudingay <mudingay@ill.fr> */
|
||||
#define NDPI_PROTOCOL_UBUNTUONE 169 /* Remy Mudingay <mudingay@ill.fr> */
|
||||
#define NDPI_PROTOCOL_WHOIS_DAS 170
|
||||
#define NDPI_PROTOCOL_COLLECTD 171
|
||||
#define NDPI_PROTOCOL_SOCKS 172 /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
#define NDPI_PROTOCOL_NINTENDO 173
|
||||
#define NDPI_PROTOCOL_RTMP 174 /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
#define NDPI_PROTOCOL_FTP_DATA 175 /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
#define NDPI_PROTOCOL_WIKIPEDIA 176 /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
#define NDPI_PROTOCOL_ZMQ 177
|
||||
#define NDPI_PROTOCOL_AMAZON 178 /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
#define NDPI_PROTOCOL_EBAY 179 /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
#define NDPI_PROTOCOL_CNN 180 /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
#define NDPI_PROTOCOL_MEGACO 181 /* Gianluca Costa <g.costa@xplico.org> */
|
||||
#define NDPI_PROTOCOL_REDIS 182
|
||||
#define NDPI_PROTOCOL_PANDO 183 /* Tomasz Bujlow <tomasz@skatnet.dk> */
|
||||
#define NDPI_PROTOCOL_VHUA 184
|
||||
#define NDPI_PROTOCOL_TELEGRAM 185 /* Gianluca Costa <g.costa@xplico.org> */
|
||||
#define NDPI_PROTOCOL_VEVO 186
|
||||
#define NDPI_PROTOCOL_PANDORA 187
|
||||
#define NDPI_PROTOCOL_QUIC 188 /* Andrea Buscarinu <andrea.buscarinu@gmail.com> - Michele Campus <michelecampus5@gmail.com> */
|
||||
#define NDPI_PROTOCOL_WHATSAPP_VOICE 189
|
||||
#define NDPI_PROTOCOL_EAQ 190
|
||||
#define NDPI_PROTOCOL_OOKLA 191
|
||||
#define NDPI_PROTOCOL_AMQP 192
|
||||
#define NDPI_PROTOCOL_KAKAOTALK 193 /* KakaoTalk Chat (no voice call) */
|
||||
#define NDPI_PROTOCOL_KAKAOTALK_VOICE 194 /* KakaoTalk Voice */
|
||||
#define NDPI_PROTOCOL_TWITCH 195 /* Edoardo Dominici <edoaramis@gmail.com> */
|
||||
#define NDPI_PROTOCOL_QUICKPLAY 196 /* Streaming service used by various services such as hooq.tv */
|
||||
#define NDPI_PROTOCOL_WECHAT 197
|
||||
#define NDPI_PROTOCOL_MPEGTS 198
|
||||
#define NDPI_PROTOCOL_SNAPCHAT 199
|
||||
#define NDPI_PROTOCOL_SINA 200
|
||||
#define NDPI_PROTOCOL_HANGOUT 201
|
||||
#define NDPI_PROTOCOL_IFLIX 202 /* www.vizuamatix.com R&D team & M.Mallawaarachchie <manoj_ws@yahoo.com> */
|
||||
#define NDPI_PROTOCOL_GITHUB 203
|
||||
#define NDPI_PROTOCOL_BJNP 204
|
||||
#define NDPI_PROTOCOL_1KXUN 205
|
||||
#define NDPI_PROTOCOL_IQIYI 206
|
||||
#define NDPI_PROTOCOL_SMPP 207 /* Damir Franusic <df@release14.org> */
|
||||
#define NDPI_PROTOCOL_DNSCRYPT 208
|
||||
#define NDPI_PROTOCOL_TINC 209 /* William Guglielmo <william@deselmo.com> */
|
||||
#define NDPI_PROTOCOL_DEEZER 210
|
||||
#define NDPI_PROTOCOL_INSTAGRAM 211 /* Andrea Buscarinu <andrea.buscarinu@gmail.com> */
|
||||
#define NDPI_PROTOCOL_MICROSOFT 212
|
||||
#define NDPI_PROTOCOL_STARCRAFT 213 /* Matteo Bracci <matteobracci1@gmail.com> */
|
||||
#define NDPI_PROTOCOL_TEREDO 214
|
||||
#define NDPI_PROTOCOL_HOTSPOT_SHIELD 215
|
||||
#define NDPI_PROTOCOL_HEP 216 /* sipcapture.org QXIP BV */
|
||||
#define NDPI_PROTOCOL_GOOGLE_DRIVE 217
|
||||
#define NDPI_PROTOCOL_OCS 218
|
||||
#define NDPI_PROTOCOL_OFFICE_365 219
|
||||
#define NDPI_PROTOCOL_CLOUDFLARE 220
|
||||
#define NDPI_PROTOCOL_MS_ONE_DRIVE 221
|
||||
#define NDPI_PROTOCOL_MQTT 222
|
||||
#define NDPI_PROTOCOL_RX 223
|
||||
#define NDPI_PROTOCOL_APPLESTORE 224
|
||||
#define NDPI_PROTOCOL_OPENDNS 225
|
||||
#define NDPI_PROTOCOL_GIT 226
|
||||
#define NDPI_PROTOCOL_DRDA 227
|
||||
#define NDPI_PROTOCOL_PLAYSTORE 228
|
||||
#define NDPI_PROTOCOL_SOMEIP 229
|
||||
#define NDPI_PROTOCOL_FIX 230
|
||||
#define NDPI_PROTOCOL_PLAYSTATION 231
|
||||
#define NDPI_PROTOCOL_PASTEBIN 232 /* Paulo Angelo <pa@pauloangelo.com> */
|
||||
#define NDPI_PROTOCOL_LINKEDIN 233 /* Paulo Angelo <pa@pauloangelo.com> */
|
||||
#define NDPI_PROTOCOL_SOUNDCLOUD 234
|
||||
#define NDPI_PROTOCOL_CSGO 235 /* Counter-Strike Global Offensive, Dota 2 */
|
||||
#define NDPI_PROTOCOL_LISP 236
|
||||
#define NDPI_PROTOCOL_DIAMETER 237
|
||||
#define NDPI_PROTOCOL_APPLE_PUSH 238
|
||||
#define NDPI_PROTOCOL_GOOGLE_SERVICES 239
|
||||
#define NDPI_PROTOCOL_AMAZON_VIDEO 240
|
||||
#define NDPI_PROTOCOL_GOOGLE_DOCS 241
|
||||
#define NDPI_PROTOCOL_WHATSAPP_FILES 242 /* Videos, pictures, voice messages... */
|
||||
#define NDPI_PROTOCOL_VIDTO 243 /* VidTO streaming service */
|
||||
#define NDPI_PROTOCOL_RAPIDVIDEO 244 /* RapidVideo streaming */
|
||||
#define NDPI_PROTOCOL_SHOWMAX 245 /* showmax.com video streaming */
|
||||
/* IMPORTANT IMPORTANT IMPORTANT IMPORTANT IMPORTANT IMPORTANT IMPORTANT IMPORTANT IMPORTANT */
|
||||
/* */
|
||||
/* If you add new NDPI protocol defines after the last, DON'T forget */
|
||||
/* to update constant NDPI_LAST_IMPLEMENTED_PROTOCOL below !!! */
|
||||
/* */
|
||||
/* IMPORTANT IMPORTANT IMPORTANT IMPORTANT IMPORTANT IMPORTANT IMPORTANT IMPORTANT IMPORTANT */
|
||||
#define NDPI_LAST_IMPLEMENTED_PROTOCOL NDPI_PROTOCOL_SHOWMAX
|
||||
|
||||
#define NDPI_MAX_SUPPORTED_PROTOCOLS (NDPI_LAST_IMPLEMENTED_PROTOCOL + 1)
|
||||
#define NDPI_MAX_NUM_CUSTOM_PROTOCOLS (NDPI_NUM_BITS-NDPI_LAST_IMPLEMENTED_PROTOCOL)
|
||||
#define NDPI_PROTOCOL_NO_MASTER_PROTO NDPI_PROTOCOL_UNKNOWN
|
||||
#define NDPI_MAX_SUPPORTED_PROTOCOLS NDPI_LAST_IMPLEMENTED_PROTOCOL
|
||||
#define NDPI_MAX_NUM_CUSTOM_PROTOCOLS (NDPI_NUM_BITS-NDPI_LAST_IMPLEMENTED_PROTOCOL)
|
||||
#endif
|
||||
|
||||
+207
-226
@@ -26,9 +26,6 @@
|
||||
|
||||
#include "ndpi_define.h"
|
||||
|
||||
#define BT_ANNOUNCE
|
||||
#define SNAP_EXT
|
||||
|
||||
/* NDPI_LOG_LEVEL */
|
||||
typedef enum {
|
||||
NDPI_LOG_ERROR,
|
||||
@@ -308,8 +305,7 @@ struct ndpi_icmphdr {
|
||||
/* ******************* ********************* ****************** */
|
||||
/* ************************************************************ */
|
||||
|
||||
#ifdef NDPI_PROTOCOL_BITTORRENT
|
||||
|
||||
/* NDPI_PROTOCOL_BITTORRENT */
|
||||
typedef struct spinlock {
|
||||
volatile int val;
|
||||
} spinlock_t;
|
||||
@@ -348,9 +344,8 @@ struct bt_announce { // 192 bytes
|
||||
u_int8_t name_len,
|
||||
name[192 - 4*10 - 2 - 1]; // 149 bytes
|
||||
};
|
||||
#endif
|
||||
|
||||
#ifdef NDPI_PROTOCOL_TINC
|
||||
/* NDPI_PROTOCOL_TINC */
|
||||
#define TINC_CACHE_MAX_SIZE 10
|
||||
|
||||
PACK_ON struct tinc_cache_entry {
|
||||
@@ -359,8 +354,6 @@ PACK_ON struct tinc_cache_entry {
|
||||
u_int16_t dst_port;
|
||||
} PACK_OFF;
|
||||
|
||||
#endif
|
||||
|
||||
typedef enum {
|
||||
HTTP_METHOD_UNKNOWN = 0,
|
||||
HTTP_METHOD_OPTIONS,
|
||||
@@ -381,227 +374,221 @@ struct ndpi_id_struct {
|
||||
to compare this, use:
|
||||
**/
|
||||
NDPI_PROTOCOL_BITMASK detected_protocol_bitmask;
|
||||
#ifdef NDPI_PROTOCOL_RTSP
|
||||
/* NDPI_PROTOCOL_RTSP */
|
||||
ndpi_ip_addr_t rtsp_ip_address;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_SIP
|
||||
#ifdef NDPI_PROTOCOL_YAHOO
|
||||
|
||||
/* NDPI_PROTOCOL_YAHOO */
|
||||
u_int32_t yahoo_video_lan_timer;
|
||||
#endif
|
||||
#endif
|
||||
|
||||
/* NDPI_PROTOCOL_IRC_MAXPORT % 2 must be 0 */
|
||||
#ifdef NDPI_PROTOCOL_IRC
|
||||
/* NDPI_PROTOCOL_IRC */
|
||||
#define NDPI_PROTOCOL_IRC_MAXPORT 8
|
||||
u_int16_t irc_port[NDPI_PROTOCOL_IRC_MAXPORT];
|
||||
u_int32_t last_time_port_used[NDPI_PROTOCOL_IRC_MAXPORT];
|
||||
u_int32_t irc_ts;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_GNUTELLA
|
||||
|
||||
/* NDPI_PROTOCOL_GNUTELLA */
|
||||
u_int32_t gnutella_ts;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_BATTLEFIELD
|
||||
|
||||
/* NDPI_PROTOCOL_BATTLEFIELD */
|
||||
u_int32_t battlefield_ts;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_THUNDER
|
||||
|
||||
/* NDPI_PROTOCOL_THUNDER */
|
||||
u_int32_t thunder_ts;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_RTSP
|
||||
|
||||
/* NDPI_PROTOCOL_RTSP */
|
||||
u_int32_t rtsp_timer;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_OSCAR
|
||||
|
||||
/* NDPI_PROTOCOL_OSCAR */
|
||||
u_int32_t oscar_last_safe_access_time;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_ZATTOO
|
||||
|
||||
/* NDPI_PROTOCOL_ZATTOO */
|
||||
u_int32_t zattoo_ts;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_UNENCRYPTED_JABBER
|
||||
|
||||
/* NDPI_PROTOCOL_UNENCRYPTED_JABBER */
|
||||
u_int32_t jabber_stun_or_ft_ts;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_DIRECTCONNECT
|
||||
|
||||
/* NDPI_PROTOCOL_DIRECTCONNECT */
|
||||
u_int32_t directconnect_last_safe_access_time;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_SOULSEEK
|
||||
|
||||
/* NDPI_PROTOCOL_SOULSEEK */
|
||||
u_int32_t soulseek_last_safe_access_time;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_DIRECTCONNECT
|
||||
|
||||
/* NDPI_PROTOCOL_DIRECTCONNECT */
|
||||
u_int16_t detected_directconnect_port;
|
||||
u_int16_t detected_directconnect_udp_port;
|
||||
u_int16_t detected_directconnect_ssl_port;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_BITTORRENT
|
||||
|
||||
/* NDPI_PROTOCOL_BITTORRENT */
|
||||
#define NDPI_BT_PORTS 8
|
||||
u_int16_t bt_port_t[NDPI_BT_PORTS];
|
||||
u_int16_t bt_port_u[NDPI_BT_PORTS];
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_UNENCRYPTED_JABBER
|
||||
|
||||
/* NDPI_PROTOCOL_UNENCRYPTED_JABBER */
|
||||
#define JABBER_MAX_STUN_PORTS 6
|
||||
u_int16_t jabber_voice_stun_port[JABBER_MAX_STUN_PORTS];
|
||||
u_int16_t jabber_file_transfer_port[2];
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_GNUTELLA
|
||||
|
||||
/* NDPI_PROTOCOL_GNUTELLA */
|
||||
u_int16_t detected_gnutella_port;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_GNUTELLA
|
||||
|
||||
/* NDPI_PROTOCOL_GNUTELLA */
|
||||
u_int16_t detected_gnutella_udp_port1;
|
||||
u_int16_t detected_gnutella_udp_port2;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_SOULSEEK
|
||||
|
||||
/* NDPI_PROTOCOL_SOULSEEK */
|
||||
u_int16_t soulseek_listen_port;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_IRC
|
||||
|
||||
/* NDPI_PROTOCOL_IRC */
|
||||
u_int8_t irc_number_of_port;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_OSCAR
|
||||
|
||||
/* NDPI_PROTOCOL_OSCAR */
|
||||
u_int8_t oscar_ssl_session_id[33];
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_UNENCRYPTED_JABBER
|
||||
|
||||
/* NDPI_PROTOCOL_UNENCRYPTED_JABBER */
|
||||
u_int8_t jabber_voice_stun_used_ports;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_SIP
|
||||
#ifdef NDPI_PROTOCOL_YAHOO
|
||||
|
||||
/* NDPI_PROTOCOL_SIP */
|
||||
/* NDPI_PROTOCOL_YAHOO */
|
||||
u_int32_t yahoo_video_lan_dir:1;
|
||||
#endif
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_YAHOO
|
||||
|
||||
/* NDPI_PROTOCOL_YAHOO */
|
||||
u_int32_t yahoo_conf_logged_in:1;
|
||||
u_int32_t yahoo_voice_conf_logged_in:1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_RTSP
|
||||
|
||||
/* NDPI_PROTOCOL_RTSP */
|
||||
u_int32_t rtsp_ts_set:1;
|
||||
#endif
|
||||
};
|
||||
|
||||
/* ************************************************** */
|
||||
|
||||
struct ndpi_flow_tcp_struct {
|
||||
#ifdef NDPI_PROTOCOL_MAIL_SMTP
|
||||
/* NDPI_PROTOCOL_MAIL_SMTP */
|
||||
u_int16_t smtp_command_bitmask;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_MAIL_POP
|
||||
|
||||
/* NDPI_PROTOCOL_MAIL_POP */
|
||||
u_int16_t pop_command_bitmask;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_QQ
|
||||
|
||||
/* NDPI_PROTOCOL_QQ */
|
||||
u_int16_t qq_nxt_len;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_TDS
|
||||
|
||||
/* NDPI_PROTOCOL_TDS */
|
||||
u_int8_t tds_login_version;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_IRC
|
||||
|
||||
/* NDPI_PROTOCOL_IRC */
|
||||
u_int8_t irc_stage;
|
||||
u_int8_t irc_port;
|
||||
#endif
|
||||
|
||||
#ifdef NDPI_PROTOCOL_H323
|
||||
/* NDPI_PROTOCOL_H323 */
|
||||
u_int8_t h323_valid_packets;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_GNUTELLA
|
||||
|
||||
/* NDPI_PROTOCOL_GNUTELLA */
|
||||
u_int8_t gnutella_msg_id[3];
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_IRC
|
||||
|
||||
/* NDPI_PROTOCOL_IRC */
|
||||
u_int32_t irc_3a_counter:3;
|
||||
u_int32_t irc_stage2:5;
|
||||
u_int32_t irc_direction:2;
|
||||
u_int32_t irc_0x1000_full:1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_SOULSEEK
|
||||
|
||||
/* NDPI_PROTOCOL_SOULSEEK */
|
||||
u_int32_t soulseek_stage:2;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_TDS
|
||||
|
||||
/* NDPI_PROTOCOL_TDS */
|
||||
u_int32_t tds_stage:3;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_USENET
|
||||
|
||||
/* NDPI_PROTOCOL_USENET */
|
||||
u_int32_t usenet_stage:2;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_IMESH
|
||||
|
||||
/* NDPI_PROTOCOL_IMESH */
|
||||
u_int32_t imesh_stage:4;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_HTTP
|
||||
|
||||
/* NDPI_PROTOCOL_HTTP */
|
||||
u_int32_t http_setup_dir:2;
|
||||
u_int32_t http_stage:2;
|
||||
u_int32_t http_empty_line_seen:1;
|
||||
u_int32_t http_wait_for_retransmission:1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_GNUTELLA
|
||||
|
||||
/* NDPI_PROTOCOL_GNUTELLA */
|
||||
u_int32_t gnutella_stage:2; // 0 - 2
|
||||
#endif
|
||||
#ifdef NDPI_CONTENT_MMS
|
||||
|
||||
/* NDPI_CONTENT_MMS */
|
||||
u_int32_t mms_stage:2;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_YAHOO
|
||||
|
||||
/* NDPI_PROTOCOL_YAHOO */
|
||||
u_int32_t yahoo_sip_comm:1;
|
||||
u_int32_t yahoo_http_proxy_stage:2;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_MSN
|
||||
|
||||
/* NDPI_PROTOCOL_MSN */
|
||||
u_int32_t msn_stage:3;
|
||||
u_int32_t msn_ssl_ft:2;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_SSH
|
||||
|
||||
/* NDPI_PROTOCOL_SSH */
|
||||
u_int32_t ssh_stage:3;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_VNC
|
||||
|
||||
/* NDPI_PROTOCOL_VNC */
|
||||
u_int32_t vnc_stage:2; // 0 - 3
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_TELNET
|
||||
|
||||
/* NDPI_PROTOCOL_TELNET */
|
||||
u_int32_t telnet_stage:2; // 0 - 2
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_SSL
|
||||
|
||||
/* NDPI_PROTOCOL_SSL */
|
||||
u_int8_t ssl_stage:2, ssl_seen_client_cert:1, ssl_seen_server_cert:1; // 0 - 5
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_POSTGRES
|
||||
|
||||
/* NDPI_PROTOCOL_POSTGRES */
|
||||
u_int32_t postgres_stage:3;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_DIRECT_DOWNLOAD_LINK
|
||||
|
||||
/* NDPI_PROTOCOL_DIRECT_DOWNLOAD_LINK */
|
||||
u_int32_t ddlink_server_direction:1;
|
||||
#endif
|
||||
u_int32_t seen_syn:1;
|
||||
u_int32_t seen_syn_ack:1;
|
||||
u_int32_t seen_ack:1;
|
||||
#ifdef NDPI_PROTOCOL_ICECAST
|
||||
|
||||
/* NDPI_PROTOCOL_ICECAST */
|
||||
u_int32_t icecast_stage:1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_DOFUS
|
||||
|
||||
/* NDPI_PROTOCOL_DOFUS */
|
||||
u_int32_t dofus_stage:1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_FIESTA
|
||||
|
||||
/* NDPI_PROTOCOL_FIESTA */
|
||||
u_int32_t fiesta_stage:2;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_WORLDOFWARCRAFT
|
||||
|
||||
/* NDPI_PROTOCOL_WORLDOFWARCRAFT */
|
||||
u_int32_t wow_stage:2;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_HTTP_APPLICATION_VEOHTV
|
||||
|
||||
/* NDPI_PROTOCOL_HTTP_APPLICATION_VEOHTV */
|
||||
u_int32_t veoh_tv_stage:2;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_SHOUTCAST
|
||||
|
||||
/* NDPI_PROTOCOL_SHOUTCAST */
|
||||
u_int32_t shoutcast_stage:2;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_RTP
|
||||
|
||||
/* NDPI_PROTOCOL_RTP */
|
||||
u_int32_t rtp_special_packets_seen:1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_MAIL_POP
|
||||
|
||||
/* NDPI_PROTOCOL_MAIL_POP */
|
||||
u_int32_t mail_pop_stage:2;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_MAIL_IMAP
|
||||
|
||||
/* NDPI_PROTOCOL_MAIL_IMAP */
|
||||
u_int32_t mail_imap_stage:3, mail_imap_starttls:2;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_SKYPE
|
||||
|
||||
/* NDPI_PROTOCOL_SKYPE */
|
||||
u_int8_t skype_packet_id;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_CITRIX
|
||||
|
||||
/* NDPI_PROTOCOL_CITRIX */
|
||||
u_int8_t citrix_packet_id;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_LOTUS_NOTES
|
||||
|
||||
/* NDPI_PROTOCOL_LOTUS_NOTES */
|
||||
u_int8_t lotus_notes_packet_id;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_TEAMVIEWER
|
||||
|
||||
/* NDPI_PROTOCOL_TEAMVIEWER */
|
||||
u_int8_t teamviewer_stage;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_ZMQ
|
||||
|
||||
/* NDPI_PROTOCOL_ZMQ */
|
||||
u_int8_t prev_zmq_pkt_len;
|
||||
u_char prev_zmq_pkt[10];
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_PPSTREAM
|
||||
|
||||
/* NDPI_PROTOCOL_PPSTREAM */
|
||||
u_int32_t ppstream_stage:3;
|
||||
#endif
|
||||
}
|
||||
#ifndef WIN32
|
||||
__attribute__ ((__packed__))
|
||||
@@ -611,55 +598,54 @@ struct ndpi_flow_tcp_struct {
|
||||
/* ************************************************** */
|
||||
|
||||
struct ndpi_flow_udp_struct {
|
||||
#ifdef NDPI_PROTOCOL_BATTLEFIELD
|
||||
/* NDPI_PROTOCOL_BATTLEFIELD */
|
||||
u_int32_t battlefield_msg_id;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_SNMP
|
||||
|
||||
/* NDPI_PROTOCOL_SNMP */
|
||||
u_int32_t snmp_msg_id;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_BATTLEFIELD
|
||||
|
||||
/* NDPI_PROTOCOL_BATTLEFIELD */
|
||||
u_int32_t battlefield_stage:3;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_SNMP
|
||||
|
||||
/* NDPI_PROTOCOL_SNMP */
|
||||
u_int32_t snmp_stage:2;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_PPSTREAM
|
||||
|
||||
/* NDPI_PROTOCOL_PPSTREAM */
|
||||
u_int32_t ppstream_stage:3; // 0 - 7
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_HALFLIFE2
|
||||
|
||||
/* NDPI_PROTOCOL_HALFLIFE2 */
|
||||
u_int32_t halflife2_stage:2; // 0 - 2
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_TFTP
|
||||
|
||||
/* NDPI_PROTOCOL_TFTP */
|
||||
u_int32_t tftp_stage:1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_AIMINI
|
||||
|
||||
/* NDPI_PROTOCOL_AIMINI */
|
||||
u_int32_t aimini_stage:5;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_XBOX
|
||||
|
||||
/* NDPI_PROTOCOL_XBOX */
|
||||
u_int32_t xbox_stage:1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_WINDOWS_UPDATE
|
||||
|
||||
/* NDPI_PROTOCOL_WINDOWS_UPDATE */
|
||||
u_int32_t wsus_stage:1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_SKYPE
|
||||
|
||||
/* NDPI_PROTOCOL_SKYPE */
|
||||
u_int8_t skype_packet_id;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_TEAMVIEWER
|
||||
|
||||
/* NDPI_PROTOCOL_TEAMVIEWER */
|
||||
u_int8_t teamviewer_stage;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_EAQ
|
||||
|
||||
/* NDPI_PROTOCOL_EAQ */
|
||||
u_int8_t eaq_pkt_id;
|
||||
u_int32_t eaq_sequence;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_RX
|
||||
|
||||
/* NDPI_PROTOCOL_RX */
|
||||
u_int32_t rx_conn_epoch;
|
||||
u_int32_t rx_conn_id;
|
||||
#endif
|
||||
}
|
||||
#ifndef WIN32
|
||||
__attribute__ ((__packed__))
|
||||
#endif
|
||||
;
|
||||
#endif
|
||||
|
||||
/* ************************************************** */
|
||||
|
||||
@@ -684,7 +670,6 @@ struct ndpi_packet_struct {
|
||||
u_int16_t detected_protocol_stack[NDPI_PROTOCOL_SIZE];
|
||||
u_int8_t detected_subprotocol_stack[NDPI_PROTOCOL_SIZE];
|
||||
|
||||
|
||||
#ifndef WIN32
|
||||
__attribute__ ((__packed__))
|
||||
#endif
|
||||
@@ -799,7 +784,7 @@ typedef enum {
|
||||
NDPI_CONTENT_CATEGORY_WINDOWSMEDIA,
|
||||
NDPI_CONTENT_CATEGORY_WEBM,
|
||||
|
||||
/* Out custom categories */
|
||||
/* Some custom categories */
|
||||
CUSTOM_CATEGORY_MINING = 99,
|
||||
CUSTOM_CATEGORY_MALWARE = 100,
|
||||
CUSTOM_CATEGORY_ADVERTISEMENT = 101,
|
||||
@@ -962,19 +947,18 @@ struct ndpi_detection_module_struct {
|
||||
char ip_string[NDPI_IP_STRING_SIZE];
|
||||
#endif
|
||||
u_int8_t ip_version_limit;
|
||||
#ifdef NDPI_PROTOCOL_BITTORRENT
|
||||
/* NDPI_PROTOCOL_BITTORRENT */
|
||||
struct hash_ip4p_table *bt_ht;
|
||||
#ifdef NDPI_DETECTION_SUPPORT_IPV6
|
||||
struct hash_ip4p_table *bt6_ht;
|
||||
#endif
|
||||
#ifdef BT_ANNOUNCE
|
||||
|
||||
/* BT_ANNOUNCE */
|
||||
struct bt_announce *bt_ann;
|
||||
int bt_ann_len;
|
||||
#endif
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_TINC
|
||||
|
||||
/* NDPI_PROTOCOL_TINC */
|
||||
struct cache *tinc_cache;
|
||||
#endif
|
||||
|
||||
ndpi_proto_defaults_t proto_defaults[NDPI_MAX_SUPPORTED_PROTOCOLS+NDPI_MAX_NUM_CUSTOM_PROTOCOLS];
|
||||
|
||||
@@ -986,7 +970,8 @@ struct ndpi_detection_module_struct {
|
||||
|
||||
void *hyperscan; /* Intel Hyperscan */
|
||||
};
|
||||
#endif
|
||||
|
||||
#endif /* NDPI_LIB_COMPILATION */
|
||||
|
||||
struct ndpi_flow_struct {
|
||||
u_int16_t detected_protocol_stack[NDPI_PROTOCOL_SIZE];
|
||||
@@ -1102,95 +1087,91 @@ struct ndpi_flow_struct {
|
||||
NDPI_PROTOCOL_BITMASK excluded_protocol_bitmask;
|
||||
|
||||
|
||||
#ifdef NDPI_PROTOCOL_REDIS
|
||||
/* NDPI_PROTOCOL_REDIS */
|
||||
u_int8_t redis_s2d_first_char, redis_d2s_first_char;
|
||||
#endif
|
||||
|
||||
u_int16_t packet_counter; // can be 0 - 65000
|
||||
u_int16_t packet_direction_counter[2];
|
||||
u_int16_t byte_counter[2];
|
||||
#ifdef NDPI_PROTOCOL_BITTORRENT
|
||||
/* NDPI_PROTOCOL_BITTORRENT */
|
||||
u_int8_t bittorrent_stage; // can be 0 - 255
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_DIRECTCONNECT
|
||||
|
||||
/* NDPI_PROTOCOL_DIRECTCONNECT */
|
||||
u_int32_t directconnect_stage:2; // 0 - 1
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_SIP
|
||||
#ifdef NDPI_PROTOCOL_YAHOO
|
||||
|
||||
/* NDPI_PROTOCOL_YAHOO */
|
||||
u_int32_t sip_yahoo_voice:1;
|
||||
#endif
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_HTTP
|
||||
|
||||
/* NDPI_PROTOCOL_HTTP */
|
||||
u_int32_t http_detected:1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_RTSP
|
||||
|
||||
/* NDPI_PROTOCOL_RTSP */
|
||||
u_int32_t rtsprdt_stage:2;
|
||||
u_int32_t rtsp_control_flow:1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_YAHOO
|
||||
|
||||
/* NDPI_PROTOCOL_YAHOO */
|
||||
u_int32_t yahoo_detection_finished:2;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_ZATTOO
|
||||
|
||||
/* NDPI_PROTOCOL_ZATTOO */
|
||||
u_int32_t zattoo_stage:3;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_QQ
|
||||
|
||||
/* NDPI_PROTOCOL_QQ */
|
||||
u_int32_t qq_stage:3;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_THUNDER
|
||||
|
||||
/* NDPI_PROTOCOL_THUNDER */
|
||||
u_int32_t thunder_stage:2; // 0 - 3
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_OSCAR
|
||||
|
||||
/* NDPI_PROTOCOL_OSCAR */
|
||||
u_int32_t oscar_ssl_voice_stage:3;
|
||||
u_int32_t oscar_video_voice:1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_FLORENSIA
|
||||
|
||||
/* NDPI_PROTOCOL_FLORENSIA */
|
||||
u_int32_t florensia_stage:1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_SOCKS
|
||||
|
||||
/* NDPI_PROTOCOL_SOCKS */
|
||||
u_int32_t socks5_stage:2; // 0 - 3
|
||||
u_int32_t socks4_stage:2; // 0 - 3
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_EDONKEY
|
||||
|
||||
/* NDPI_PROTOCOL_EDONKEY */
|
||||
u_int32_t edonkey_stage:2; // 0 - 3
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_FTP_CONTROL
|
||||
|
||||
/* NDPI_PROTOCOL_FTP_CONTROL */
|
||||
u_int32_t ftp_control_stage:2;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_RTMP
|
||||
|
||||
/* NDPI_PROTOCOL_RTMP */
|
||||
u_int32_t rtmp_stage:2;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_PANDO
|
||||
|
||||
/* NDPI_PROTOCOL_PANDO */
|
||||
u_int32_t pando_stage:3;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_STEAM
|
||||
|
||||
/* NDPI_PROTOCOL_STEAM */
|
||||
u_int32_t steam_stage:3;
|
||||
u_int32_t steam_stage1:3; // 0 - 4
|
||||
u_int32_t steam_stage2:2; // 0 - 2
|
||||
u_int32_t steam_stage3:2; // 0 - 2
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_PPLIVE
|
||||
|
||||
/* NDPI_PROTOCOL_PPLIVE */
|
||||
u_int32_t pplive_stage1:3; // 0 - 6
|
||||
u_int32_t pplive_stage2:2; // 0 - 2
|
||||
u_int32_t pplive_stage3:2; // 0 - 2
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_STARCRAFT
|
||||
|
||||
/* NDPI_PROTOCOL_STARCRAFT */
|
||||
u_int32_t starcraft_udp_stage : 3; // 0-7
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_OPENVPN
|
||||
|
||||
/* NDPI_PROTOCOL_OPENVPN */
|
||||
u_int8_t ovpn_session_id[8];
|
||||
u_int8_t ovpn_counter;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_TINC
|
||||
|
||||
/* NDPI_PROTOCOL_TINC */
|
||||
u_int8_t tinc_state;
|
||||
struct tinc_cache_entry tinc_cache_entry;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_CSGO
|
||||
|
||||
/* NDPI_PROTOCOL_CSGO */
|
||||
u_int8_t csgo_strid[18],csgo_state,csgo_s2;
|
||||
u_int32_t csgo_id2;
|
||||
#endif
|
||||
|
||||
#if defined(NDPI_PROTOCOL_1KXUN) || defined(NDPI_PROTOCOL_IQIYI)
|
||||
/* NDPI_PROTOCOL_1KXUN || NDPI_PROTOCOL_IQIYI */
|
||||
u_int16_t kxun_counter, iqiyi_counter;
|
||||
#endif
|
||||
|
||||
/* internal structures to save functions calls */
|
||||
struct ndpi_packet_struct packet;
|
||||
@@ -1212,4 +1193,4 @@ typedef struct {
|
||||
u_int8_t value;
|
||||
} ndpi_network;
|
||||
|
||||
#endif/* __NDPI_TYPEDEFS_H__ */
|
||||
#endif /* __NDPI_TYPEDEFS_H__ */
|
||||
|
||||
@@ -11,12 +11,14 @@ RANLIB=ranlib
|
||||
OBJECTS = $(patsubst protocols/%.c, protocols/%.o, $(wildcard protocols/*.c)) $(patsubst third_party/src/%.c, third_party/src/%.o, $(wildcard third_party/src/*.c)) ndpi_main.o
|
||||
HEADERS = $(wildcard ../include/*.h)
|
||||
|
||||
all: libndpi.a
|
||||
|
||||
libndpi.a: $(OBJECTS)
|
||||
ar rc $@ $(OBJECTS)
|
||||
$(RANLIB) $@
|
||||
|
||||
|
||||
%.o: %.c $(HEADERS) Makefile
|
||||
$(CC) $(CFLAGS) -c $< -o $@
|
||||
|
||||
clean:
|
||||
/bin/rm -f libndpi.a $(OBJECTS)
|
||||
/bin/rm -f libndpi.a $(OBJECTS)
|
||||
@@ -1,181 +0,0 @@
|
||||
lib_LTLIBRARIES = libndpi.la
|
||||
|
||||
CFLAGS += -fPIC -DPIC -DNDPI_LIB_COMPILATION # --coverage
|
||||
libndpi_la_CPPFLAGS = -I$(top_srcdir)/src/include/ -I$(top_srcdir)/src/lib/third_party/include/ @HS_INC@
|
||||
libndpi_la_LDFLAGS = -version-info 1:0:0 -export-symbols $(top_srcdir)/libndpi.sym
|
||||
|
||||
libndpi_la_includedir = $(includedir)/libndpi-@VERSION@/libndpi
|
||||
|
||||
libndpi_la_include_HEADERS = ../include/ndpi_api.h \
|
||||
../include/ndpi_define.h \
|
||||
../include/ndpi_main.h \
|
||||
../include/ndpi_includes.h \
|
||||
../include/ndpi_config.h \
|
||||
../include/ndpi_protocol_ids.h \
|
||||
../include/ndpi_protocols.h \
|
||||
../include/ndpi_typedefs.h \
|
||||
third_party/include/libcache.h
|
||||
|
||||
libndpi_la_SOURCES = ndpi_content_match.c.inc \
|
||||
ndpi_main.c \
|
||||
protocols/afp.c \
|
||||
protocols/ajp.c \
|
||||
protocols/aimini.c \
|
||||
protocols/applejuice.c \
|
||||
protocols/apple_push.c \
|
||||
protocols/armagetron.c \
|
||||
protocols/ayiya.c \
|
||||
protocols/amqp.c \
|
||||
protocols/battlefield.c \
|
||||
protocols/bgp.c \
|
||||
protocols/bittorrent.c \
|
||||
protocols/bjnp.c \
|
||||
protocols/checkmk.c \
|
||||
protocols/ciscovpn.c \
|
||||
protocols/citrix.c \
|
||||
protocols/coap.c \
|
||||
protocols/collectd.c \
|
||||
protocols/corba.c \
|
||||
protocols/crossfire.c \
|
||||
protocols/csgo.c \
|
||||
protocols/dcerpc.c \
|
||||
protocols/dhcp.c \
|
||||
protocols/dhcpv6.c \
|
||||
protocols/diameter.c \
|
||||
protocols/directconnect.c \
|
||||
protocols/directdownloadlink.c \
|
||||
protocols/dns.c \
|
||||
protocols/dofus.c \
|
||||
protocols/drda.c \
|
||||
protocols/dropbox.c \
|
||||
protocols/eaq.c \
|
||||
protocols/edonkey.c \
|
||||
protocols/fasttrack.c \
|
||||
protocols/fbzero.c \
|
||||
protocols/fiesta.c \
|
||||
protocols/fix.c \
|
||||
protocols/florensia.c \
|
||||
protocols/ftp_control.c \
|
||||
protocols/ftp_data.c \
|
||||
protocols/git.c \
|
||||
protocols/gnutella.c \
|
||||
protocols/gtp.c \
|
||||
protocols/guildwars.c \
|
||||
protocols/hangout.c \
|
||||
protocols/h323.c \
|
||||
protocols/halflife2_and_mods.c \
|
||||
protocols/hep.c \
|
||||
protocols/http_activesync.c \
|
||||
protocols/http.c \
|
||||
protocols/iax.c \
|
||||
protocols/icecast.c \
|
||||
protocols/ipp.c \
|
||||
protocols/irc.c \
|
||||
protocols/jabber.c \
|
||||
protocols/kakaotalk_voice.c \
|
||||
protocols/kerberos.c \
|
||||
protocols/kontiki.c \
|
||||
protocols/ldap.c \
|
||||
protocols/lotus_notes.c \
|
||||
protocols/lisp.c \
|
||||
protocols/mail_imap.c \
|
||||
protocols/mail_pop.c \
|
||||
protocols/mail_smtp.c \
|
||||
protocols/maplestory.c \
|
||||
protocols/mdns.c \
|
||||
protocols/megaco.c \
|
||||
protocols/mgcp.c \
|
||||
protocols/mpegts.c \
|
||||
protocols/mqtt.c \
|
||||
protocols/msn.c \
|
||||
protocols/mssql_tds.c \
|
||||
protocols/mysql.c \
|
||||
protocols/netbios.c \
|
||||
protocols/netflow.c \
|
||||
protocols/nintendo.c \
|
||||
protocols/nfs.c \
|
||||
protocols/noe.c \
|
||||
protocols/non_tcp_udp.c \
|
||||
protocols/ntp.c \
|
||||
protocols/openft.c \
|
||||
protocols/openvpn.c \
|
||||
protocols/oracle.c \
|
||||
protocols/oscar.c \
|
||||
protocols/pando.c \
|
||||
protocols/pcanywhere.c \
|
||||
protocols/postgres.c \
|
||||
protocols/pplive.c \
|
||||
protocols/ppstream.c \
|
||||
protocols/pptp.c \
|
||||
protocols/qq.c \
|
||||
protocols/quic.c \
|
||||
protocols/radius.c \
|
||||
protocols/rdp.c \
|
||||
protocols/redis_net.c \
|
||||
protocols/rsync.c \
|
||||
protocols/rtcp.c \
|
||||
protocols/rtmp.c \
|
||||
protocols/rtp.c \
|
||||
protocols/rtsp.c \
|
||||
protocols/rx.c \
|
||||
protocols/sflow.c \
|
||||
protocols/shoutcast.c \
|
||||
protocols/sip.c \
|
||||
protocols/skinny.c \
|
||||
protocols/skype.c \
|
||||
protocols/smb.c \
|
||||
protocols/snmp.c \
|
||||
protocols/socks45.c \
|
||||
protocols/sopcast.c \
|
||||
protocols/soulseek.c \
|
||||
protocols/spotify.c \
|
||||
protocols/ssdp.c \
|
||||
protocols/ssh.c \
|
||||
protocols/ssl.c \
|
||||
protocols/starcraft.c \
|
||||
protocols/stealthnet.c \
|
||||
protocols/steam.c \
|
||||
protocols/stun.c \
|
||||
protocols/syslog.c \
|
||||
protocols/tcp_udp.c \
|
||||
protocols/teamspeak.c \
|
||||
protocols/teamviewer.c \
|
||||
protocols/telegram.c \
|
||||
protocols/telnet.c \
|
||||
protocols/tftp.c \
|
||||
protocols/thunder.c \
|
||||
protocols/tor.c \
|
||||
protocols/teredo.c \
|
||||
protocols/tvants.c \
|
||||
protocols/tvuplayer.c \
|
||||
protocols/ubntac2.c \
|
||||
protocols/usenet.c \
|
||||
protocols/viber.c \
|
||||
protocols/vhua.c \
|
||||
protocols/vmware.c \
|
||||
protocols/vnc.c \
|
||||
protocols/warcraft3.c \
|
||||
protocols/whoisdas.c \
|
||||
protocols/world_of_kung_fu.c \
|
||||
protocols/world_of_warcraft.c \
|
||||
protocols/xbox.c \
|
||||
protocols/xdmcp.c \
|
||||
protocols/yahoo.c \
|
||||
protocols/zattoo.c \
|
||||
protocols/zeromq.c \
|
||||
protocols/smpp.c \
|
||||
protocols/tinc.c \
|
||||
protocols/someip.c \
|
||||
protocols/whatsapp.c \
|
||||
third_party/include/actypes.h \
|
||||
third_party/include/ahocorasick.h \
|
||||
third_party/include/ndpi_patricia.h \
|
||||
third_party/include/node.h \
|
||||
third_party/include/sort.h \
|
||||
third_party/include/libcache.h \
|
||||
third_party/src/ahocorasick.c \
|
||||
third_party/src/node.c \
|
||||
third_party/src/sort.c \
|
||||
third_party/src/libcache.c
|
||||
|
||||
EXTRA_DIST = third_party/src/ndpi_patricia.c
|
||||
@@ -7946,9 +7946,8 @@ static ndpi_network host_protocol_list[] = {
|
||||
|
||||
/*
|
||||
VidTO
|
||||
*/
|
||||
|
||||
{ 0x51111030 /* 81.17.16.48/32 */, 32, NDPI_PROTOCOL_VIDTO },
|
||||
*/
|
||||
{ 0x51111030 /* 81.17.16.48/32 */, 32, NDPI_PROTOCOL_VIDTO },
|
||||
{ 0x5fb7329d /* 95.183.50.157/32 */, 32, NDPI_PROTOCOL_VIDTO },
|
||||
{ 0x577824f2 /* 87.120.36.242/32 */, 32, NDPI_PROTOCOL_VIDTO },
|
||||
|
||||
@@ -8212,8 +8211,6 @@ ndpi_protocol_match host_match[] = {
|
||||
{ "static-cdn.jtvnw.net", NULL, NULL, "Twitch", NDPI_PROTOCOL_TWITCH, NDPI_PROTOCOL_CATEGORY_MEDIA, NDPI_PROTOCOL_FUN },
|
||||
{ "www-cdn.jtvnw.net", NULL, NULL, "Twitch", NDPI_PROTOCOL_TWITCH, NDPI_PROTOCOL_CATEGORY_MEDIA, NDPI_PROTOCOL_FUN },
|
||||
|
||||
{ "quickplay.com", NULL, NULL, "QuickPlay", NDPI_PROTOCOL_QUICKPLAY, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
|
||||
{ ".qq.com", NULL, NULL, "QQ", NDPI_PROTOCOL_QQ, NDPI_PROTOCOL_CATEGORY_CHAT, NDPI_PROTOCOL_FUN },
|
||||
{ ".gtimg.com", NULL, NULL, "QQ", NDPI_PROTOCOL_QQ, NDPI_PROTOCOL_CATEGORY_CHAT, NDPI_PROTOCOL_FUN },
|
||||
|
||||
@@ -8316,17 +8313,6 @@ ndpi_protocol_match host_match[] = {
|
||||
{ "githubusercontent.com", NULL, NULL, "Github", NDPI_PROTOCOL_GITHUB, NDPI_PROTOCOL_CATEGORY_COLLABORATIVE, NDPI_PROTOCOL_ACCEPTABLE },
|
||||
{ ".githubusercontent.com", NULL, NULL, "Github", NDPI_PROTOCOL_GITHUB, NDPI_PROTOCOL_CATEGORY_COLLABORATIVE, NDPI_PROTOCOL_ACCEPTABLE },
|
||||
|
||||
{ ".iqiyi.com", NULL, NULL, "iQIYI", NDPI_PROTOCOL_IQIYI, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
{ ".qiyi.com", NULL, NULL, "iQIYI", NDPI_PROTOCOL_IQIYI, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
{ ".71.am", NULL, NULL, "iQIYI", NDPI_PROTOCOL_IQIYI, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
{ ".qiyipic.com", NULL, NULL, "iQIYI", NDPI_PROTOCOL_IQIYI, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
|
||||
{ ".ppstream.com", NULL, NULL, "PPStream", NDPI_PROTOCOL_PPSTREAM, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
{ ".pps.tv", NULL, NULL, "PPStream", NDPI_PROTOCOL_PPSTREAM, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
|
||||
{ ".1kxun.", NULL, NULL, "1kxun", NDPI_PROTOCOL_1KXUN, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
{ "tcad.wedolook.com", NULL, NULL, "1kxun", NDPI_PROTOCOL_1KXUN, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
|
||||
{ ".steampowered.com", NULL, NULL, "Steam", NDPI_PROTOCOL_STEAM, NDPI_PROTOCOL_CATEGORY_GAME, NDPI_PROTOCOL_FUN },
|
||||
{ "steamcommunity.com", NULL, NULL, "Steam", NDPI_PROTOCOL_STEAM, NDPI_PROTOCOL_CATEGORY_GAME, NDPI_PROTOCOL_FUN },
|
||||
{ ".steamcontent.com", NULL, NULL, "Steam", NDPI_PROTOCOL_STEAM, NDPI_PROTOCOL_CATEGORY_GAME, NDPI_PROTOCOL_FUN },
|
||||
@@ -8353,8 +8339,6 @@ ndpi_protocol_match host_match[] = {
|
||||
{ ".playstation.com", NULL, NULL, "Playstation", NDPI_PROTOCOL_PLAYSTATION, NDPI_PROTOCOL_CATEGORY_GAME, NDPI_PROTOCOL_FUN },
|
||||
{ ".sonyentertainmentnetwork.com", NULL, NULL,"Playstation", NDPI_PROTOCOL_PLAYSTATION, NDPI_PROTOCOL_CATEGORY_GAME, NDPI_PROTOCOL_FUN },
|
||||
|
||||
{ ".pastebin.com", NULL, NULL, "Pastebin", NDPI_PROTOCOL_PASTEBIN, NDPI_PROTOCOL_CATEGORY_DOWNLOAD_FT, NDPI_PROTOCOL_POTENTIALLY_DANGEROUS },
|
||||
|
||||
{ ".linkedin.com", NULL, NULL, "LinkedIn", NDPI_PROTOCOL_LINKEDIN, NDPI_PROTOCOL_CATEGORY_SOCIAL_NETWORK, NDPI_PROTOCOL_FUN },
|
||||
{ ".licdn.com", NULL, NULL, "LinkedIn", NDPI_PROTOCOL_LINKEDIN, NDPI_PROTOCOL_CATEGORY_SOCIAL_NETWORK, NDPI_PROTOCOL_FUN },
|
||||
|
||||
@@ -8366,17 +8350,42 @@ ndpi_protocol_match host_match[] = {
|
||||
{ "tdesktop.com", NULL, NULL, "Telegram", NDPI_PROTOCOL_TELEGRAM, NDPI_PROTOCOL_CATEGORY_CHAT, NDPI_PROTOCOL_ACCEPTABLE },
|
||||
{ "tupdate.com", NULL, NULL, "Telegram", NDPI_PROTOCOL_TELEGRAM, NDPI_PROTOCOL_CATEGORY_CHAT, NDPI_PROTOCOL_ACCEPTABLE },
|
||||
|
||||
{ ".icq.", NULL, NULL, "ICQ", NDPI_PROTOCOL_ICQ, NDPI_PROTOCOL_CATEGORY_CHAT, NDPI_PROTOCOL_ACCEPTABLE },
|
||||
{ "icq.", NULL, NULL, "ICQ", NDPI_PROTOCOL_ICQ, NDPI_PROTOCOL_CATEGORY_CHAT, NDPI_PROTOCOL_ACCEPTABLE },
|
||||
{ ".pastebin.com", NULL, NULL, "Pastebin", NDPI_PROTOCOL_PASTEBIN, NDPI_PROTOCOL_CATEGORY_DOWNLOAD_FT, NDPI_PROTOCOL_POTENTIALLY_DANGEROUS },
|
||||
|
||||
{ ".vidto.me", NULL, NULL, "VidTO", NDPI_PROTOCOL_VIDTO, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
{ ".vidto.se", NULL, NULL, "VidTO", NDPI_PROTOCOL_VIDTO, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
{ ".ppstream.com", NULL, NULL, "PPStream", NDPI_PROTOCOL_PPSTREAM, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
{ ".pps.tv", NULL, NULL, "PPStream", NDPI_PROTOCOL_PPSTREAM, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
|
||||
/*
|
||||
VidTO streaming service
|
||||
NOTE: this is a possible candidate for NDPI_PROTOCOL_GENERIC
|
||||
*/
|
||||
{ ".vidto.me", NULL, NULL, "VidTO", NDPI_PROTOCOL_PPSTREAM, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
{ ".vidto.se", NULL, NULL, "VidTO", NDPI_PROTOCOL_PPSTREAM, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
|
||||
/*
|
||||
Not so popular services without a protocl dissector (and thus not worth a protocolId) that are handled/detected by categpory rather
|
||||
than by protocol id. They are bound to a generic protocol (NDPI_PROTOCOL_GENERIC) and placed onto the right category
|
||||
*/
|
||||
{ "quickplay.com", NULL, NULL, "QuickPlay", NDPI_PROTOCOL_GENERIC, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
|
||||
{ ".rapidvideo.com", NULL, NULL, "RapidVideo", NDPI_PROTOCOL_RAPIDVIDEO, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
{ ".playercdn.net", NULL, NULL, "RapidVideo", NDPI_PROTOCOL_RAPIDVIDEO, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
{ ".iqiyi.com", NULL, NULL, "iQIYI", NDPI_PROTOCOL_GENERIC, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
{ ".qiyi.com", NULL, NULL, "iQIYI", NDPI_PROTOCOL_GENERIC, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
{ ".71.am", NULL, NULL, "iQIYI", NDPI_PROTOCOL_GENERIC, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
{ ".qiyipic.com", NULL, NULL, "iQIYI", NDPI_PROTOCOL_GENERIC, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
|
||||
{ "showmax.com", NULL, NULL, "Showmax", NDPI_PROTOCOL_SHOWMAX, NDPI_PROTOCOL_CATEGORY_MEDIA, NDPI_PROTOCOL_FUN },
|
||||
{ "showmax.akamaized.net", NULL, NULL, "Showmax", NDPI_PROTOCOL_SHOWMAX, NDPI_PROTOCOL_CATEGORY_MEDIA, NDPI_PROTOCOL_FUN },
|
||||
{ ".1kxun.", NULL, NULL, "1kxun", NDPI_PROTOCOL_GENERIC, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
{ "tcad.wedolook.com", NULL, NULL, "1kxun", NDPI_PROTOCOL_GENERIC, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
|
||||
{ ".icq.", NULL, NULL, "ICQ", NDPI_PROTOCOL_GENERIC, NDPI_PROTOCOL_CATEGORY_CHAT, NDPI_PROTOCOL_ACCEPTABLE },
|
||||
{ "icq.", NULL, NULL, "ICQ", NDPI_PROTOCOL_GENERIC, NDPI_PROTOCOL_CATEGORY_CHAT, NDPI_PROTOCOL_ACCEPTABLE },
|
||||
|
||||
/* RapidVideo streaming */
|
||||
{ ".rapidvideo.com", NULL, NULL, "RapidVideo", NDPI_PROTOCOL_GENERIC, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
{ ".playercdn.net", NULL, NULL, "RapidVideo", NDPI_PROTOCOL_GENERIC, NDPI_PROTOCOL_CATEGORY_STREAMING, NDPI_PROTOCOL_FUN },
|
||||
|
||||
/* showmax.com video streaming */
|
||||
{ "showmax.com", NULL, NULL, "Showmax", NDPI_PROTOCOL_GENERIC, NDPI_PROTOCOL_CATEGORY_MEDIA, NDPI_PROTOCOL_FUN },
|
||||
{ "showmax.akamaized.net", NULL, NULL, "Showmax", NDPI_PROTOCOL_GENERIC, NDPI_PROTOCOL_CATEGORY_MEDIA, NDPI_PROTOCOL_FUN },
|
||||
|
||||
{ NULL, NULL, NULL, 0 }
|
||||
};
|
||||
|
||||
+13
-14
@@ -1495,9 +1495,9 @@ static void ndpi_init_protocol_defaults(struct ndpi_detection_module_struct *ndp
|
||||
no_master, "Guildwars", NDPI_PROTOCOL_CATEGORY_GAME,
|
||||
ndpi_build_default_ports(ports_a, 0, 0, 0, 0, 0) /* TCP */,
|
||||
ndpi_build_default_ports(ports_b, 0, 0, 0, 0, 0) /* UDP */);
|
||||
ndpi_set_proto_defaults(ndpi_mod, NDPI_PROTOCOL_ACCEPTABLE, NDPI_PROTOCOL_HTTP_APPLICATION_ACTIVESYNC,
|
||||
ndpi_set_proto_defaults(ndpi_mod, NDPI_PROTOCOL_ACCEPTABLE, NDPI_PROTOCOL_HTTP_ACTIVESYNC,
|
||||
no_master,
|
||||
no_master, "HTTP_Application_ActiveSync", NDPI_PROTOCOL_CATEGORY_CLOUD,
|
||||
no_master, "HTTP_ActiveSync", NDPI_PROTOCOL_CATEGORY_CLOUD,
|
||||
ndpi_build_default_ports(ports_a, 0, 0, 0, 0, 0) /* TCP */,
|
||||
ndpi_build_default_ports(ports_b, 0, 0, 0, 0, 0) /* UDP */);
|
||||
ndpi_set_proto_defaults(ndpi_mod, NDPI_PROTOCOL_ACCEPTABLE, NDPI_PROTOCOL_KERBEROS,
|
||||
@@ -1917,8 +1917,6 @@ static int ac_match_handler(AC_MATCH_t *m, AC_TEXT_t *txt, void *param) {
|
||||
|
||||
/* ******************************************************************** */
|
||||
|
||||
#ifdef NDPI_PROTOCOL_TOR
|
||||
|
||||
static int fill_prefix_v4(prefix_t *p, struct in_addr *a, int b, int mb) {
|
||||
do {
|
||||
if(b < 0 || b > mb)
|
||||
@@ -1995,6 +1993,7 @@ static patricia_node_t* add_to_ptree(patricia_tree_t *tree, int family,
|
||||
|
||||
return(node);
|
||||
}
|
||||
|
||||
/* ******************************************* */
|
||||
|
||||
static void ndpi_init_ptree_ipv4(struct ndpi_detection_module_struct *ndpi_str,
|
||||
@@ -2006,7 +2005,8 @@ static void ndpi_init_ptree_ipv4(struct ndpi_detection_module_struct *ndpi_str,
|
||||
patricia_node_t *node;
|
||||
|
||||
pin.s_addr = htonl(host_list[i].network);
|
||||
if((node = add_to_ptree(ptree, AF_INET, &pin, host_list[i].cidr /* bits */)) != NULL)
|
||||
if((node = add_to_ptree(ptree, AF_INET,
|
||||
&pin, host_list[i].cidr /* bits */)) != NULL)
|
||||
node->value.user_value = host_list[i].value;
|
||||
}
|
||||
}
|
||||
@@ -2036,8 +2036,6 @@ static int ndpi_add_host_ip_subprotocol(struct ndpi_detection_module_struct *ndp
|
||||
return 0;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
void set_ndpi_malloc(void* (*__ndpi_malloc)(size_t size)) { _ndpi_malloc = __ndpi_malloc; }
|
||||
void set_ndpi_flow_malloc(void* (*__ndpi_flow_malloc)(size_t size)) { _ndpi_flow_malloc = __ndpi_flow_malloc; }
|
||||
|
||||
@@ -2293,13 +2291,13 @@ void ndpi_exit_detection_module(struct ndpi_detection_module_struct *ndpi_struct
|
||||
ndpi_free(ndpi_struct->proto_defaults[i].protoName);
|
||||
}
|
||||
|
||||
#ifdef NDPI_PROTOCOL_TINC
|
||||
/* NDPI_PROTOCOL_TINC */
|
||||
if(ndpi_struct->tinc_cache)
|
||||
cache_free((cache_t)(ndpi_struct->tinc_cache));
|
||||
#endif
|
||||
|
||||
if(ndpi_struct->protocols_ptree)
|
||||
ndpi_Destroy_Patricia((patricia_tree_t*)ndpi_struct->protocols_ptree, free_ptree_data);
|
||||
ndpi_Destroy_Patricia((patricia_tree_t*)ndpi_struct->protocols_ptree,
|
||||
free_ptree_data);
|
||||
|
||||
if (ndpi_struct->udpRoot != NULL)
|
||||
ndpi_tdestroy(ndpi_struct->udpRoot, ndpi_free);
|
||||
@@ -2358,7 +2356,8 @@ int ndpi_get_protocol_id_master_proto(struct ndpi_detection_module_struct *ndpi_
|
||||
u_int16_t** tcp_master_proto,
|
||||
u_int16_t** udp_master_proto) {
|
||||
if(protocol_id >= (NDPI_MAX_SUPPORTED_PROTOCOLS+NDPI_MAX_NUM_CUSTOM_PROTOCOLS)) {
|
||||
*tcp_master_proto = *udp_master_proto = NDPI_PROTOCOL_UNKNOWN;
|
||||
*tcp_master_proto = ndpi_struct->proto_defaults[NDPI_PROTOCOL_UNKNOWN].master_tcp_protoId,
|
||||
*udp_master_proto = ndpi_struct->proto_defaults[NDPI_PROTOCOL_UNKNOWN].master_udp_protoId;
|
||||
return(-1);
|
||||
}
|
||||
|
||||
@@ -2566,12 +2565,12 @@ int ndpi_handle_rule(struct ndpi_detection_module_struct *ndpi_mod,
|
||||
else
|
||||
removeDefaultPort(&range, def, is_tcp ? &ndpi_mod->tcpRoot : &ndpi_mod->udpRoot);
|
||||
} else if(is_ip) {
|
||||
#ifdef NDPI_PROTOCOL_TOR
|
||||
/* NDPI_PROTOCOL_TOR */
|
||||
ndpi_add_host_ip_subprotocol(ndpi_mod, value, subprotocol_id);
|
||||
#endif
|
||||
} else {
|
||||
if(do_add)
|
||||
ndpi_add_host_url_subprotocol(ndpi_mod, value, subprotocol_id, NDPI_PROTOCOL_ACCEPTABLE);
|
||||
ndpi_add_host_url_subprotocol(ndpi_mod, value, subprotocol_id,
|
||||
NDPI_PROTOCOL_ACCEPTABLE);
|
||||
else
|
||||
ndpi_remove_host_url_subprotocol(ndpi_mod, value, subprotocol_id);
|
||||
}
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
/*
|
||||
* afp.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-16 - ntop.org
|
||||
* Copyright (C) 2009-11 by ipoque GmbH
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -25,8 +25,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_AFP
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_AFP
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -100,5 +98,3 @@ void init_afp_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int3
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* aimini.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -25,8 +25,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_AIMINI
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_AIMINI
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -293,5 +291,3 @@ void init_aimini_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_i
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -22,8 +22,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_AJP
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_AJP
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -149,5 +147,3 @@ void init_ajp_dissector(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* amqp.c
|
||||
*
|
||||
* Copyright (C) 2011-17 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* nDPI is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU Lesser General Public License as published by
|
||||
@@ -20,8 +20,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_AMQP
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_AMQP
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -87,4 +85,3 @@ void init_amqp_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -23,8 +23,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_APPLE_PUSH
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_APPLE_PUSH
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -76,6 +74,3 @@ void init_apple_push_dissector(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* applejuice.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -24,8 +24,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_APPLEJUICE
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_APPLEJUICE
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -67,5 +65,3 @@ void init_applejuice_dissector(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* armagetron.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -24,8 +24,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_ARMAGETRON
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_ARMAGETRON
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -109,6 +107,3 @@ void init_armagetron_dissector(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* flash.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* ftp.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* manolito.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* popo.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* secondlife.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* ayiya.c
|
||||
*
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -28,8 +28,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_AYIYA
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_AYIYA
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -85,5 +83,3 @@ void init_ayiya_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_in
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* battlefield.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -24,8 +24,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_BATTLEFIELD
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_BATTLEFIELD
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -126,5 +124,3 @@ void init_battlefield_dissector(struct ndpi_detection_module_struct *ndpi_struct
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* bgp.c
|
||||
*
|
||||
* Copyright (C) 2016 - ntop.org
|
||||
* Copyright (C) 2016-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -23,8 +23,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_BGP
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_BGP
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -67,5 +65,3 @@ void init_bgp_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int3
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
@@ -25,8 +25,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_BITTORRENT
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_BITTORRENT
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -503,5 +501,3 @@ void init_bittorrent_dissector(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,16 +1,14 @@
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_BJNP
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_BJNP
|
||||
|
||||
#include "ndpi_api.h"
|
||||
|
||||
static void ndpi_int_bjnp_add_connection(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
struct ndpi_flow_struct *flow,
|
||||
u_int8_t due_to_correlation)
|
||||
{
|
||||
ndpi_set_detected_protocol(ndpi_struct, flow, NDPI_PROTOCOL_BJNP, NDPI_PROTOCOL_UNKNOWN);
|
||||
u_int8_t due_to_correlation) {
|
||||
ndpi_set_detected_protocol(ndpi_struct, flow,
|
||||
NDPI_PROTOCOL_BJNP, NDPI_PROTOCOL_UNKNOWN);
|
||||
}
|
||||
|
||||
|
||||
@@ -61,7 +59,3 @@ void init_bjnp_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* btlib.c
|
||||
*
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
* Contributed by Vitaly Lavrov <vel21ripn@gmail.com>
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* checkmk.c
|
||||
*
|
||||
* Copyright (C) 2011-17 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -23,8 +23,6 @@
|
||||
*/
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_CHECKMK
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_CHECKMK
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -82,6 +80,3 @@ void init_checkmk_dissector(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
@@ -6,8 +6,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_CISCOVPN
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_CISCOVPN
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -84,5 +82,3 @@ void init_ciscovpn_dissector(struct ndpi_detection_module_struct *ndpi_struct, u
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* citrix.c
|
||||
*
|
||||
* Copyright (C) 2012-15 - ntop.org
|
||||
* Copyright (C) 2012-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -23,8 +23,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_CITRIX
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_CITRIX
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -95,5 +93,3 @@ void init_citrix_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_i
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -23,8 +23,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_COAP
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_COAP
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -163,5 +161,3 @@ void init_coap_dissector (struct ndpi_detection_module_struct *ndpi_struct,
|
||||
*id +=1;
|
||||
}
|
||||
|
||||
|
||||
#endif // NDPI_PROTOCOL_COAP
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* collectd.c
|
||||
*
|
||||
* Copyright (C) 2014 - ntop.org
|
||||
* Copyright (C) 2014-18 - ntop.org
|
||||
*
|
||||
* nDPI is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU Lesser General Public License as published by
|
||||
@@ -21,8 +21,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_COLLECTD
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_COLLECTD
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -54,5 +52,3 @@ void ndpi_search_collectd(struct ndpi_detection_module_struct *ndpi_struct, stru
|
||||
NDPI_EXCLUDE_PROTO(ndpi_struct, flow);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -20,8 +20,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_CORBA
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_CORBA
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -60,4 +58,3 @@ void init_corba_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_in
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* crossfire.c
|
||||
*
|
||||
* Copyright (C) 2012-15 - ntop.org
|
||||
* Copyright (C) 2012-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -23,8 +23,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_CROSSFIRE
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_CROSSFIRE
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -88,5 +86,3 @@ void init_crossfire_dissector(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -22,8 +22,6 @@
|
||||
*/
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_CSGO
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_CSGO
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -122,5 +120,3 @@ void init_csgo_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* dcerpc.c
|
||||
*
|
||||
* Copyright (C) 2011-13 by ntop.org
|
||||
* Copyright (C) 2011-18 by ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -23,8 +23,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_DCERPC
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_DCERPC
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -69,4 +67,3 @@ void init_dcerpc_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_i
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* dhcp.c
|
||||
*
|
||||
* Copyright (C) 2016 - ntop.org
|
||||
* Copyright (C) 2016-18 - ntop.org
|
||||
*
|
||||
* nDPI is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU Lesser General Public License as published by
|
||||
@@ -20,8 +20,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_DHCP
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_DHCP
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -166,5 +164,3 @@ void init_dhcp_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* dhcpv6.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -24,8 +24,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_DHCPV6
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_DHCPV6
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -68,5 +66,3 @@ void init_dhcpv6_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_i
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
* diameter.c
|
||||
*
|
||||
* Copyright (C) 2018 - ntop.org
|
||||
* Written by Michele Campus - <campus@ntop.org>
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -19,12 +18,12 @@
|
||||
*
|
||||
* You should have received a copy of the GNU Lesser General Public License
|
||||
* along with nDPI. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*
|
||||
* Based on code of:
|
||||
* Michele Campus - <campus@ntop.org>
|
||||
*/
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_DIAMETER
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_DIAMETER
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -128,5 +127,3 @@ void init_diameter_dissector(struct ndpi_detection_module_struct *ndpi_struct, u
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif /* NDPI_PROTOCOL_DIAMETER */
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* directconnect.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -25,8 +25,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_DIRECTCONNECT
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_DIRECTCONNECT
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -446,5 +444,3 @@ void init_directconnect_dissector(struct ndpi_detection_module_struct *ndpi_stru
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* directdownloadlink.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-14svn - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -25,8 +25,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_DIRECT_DOWNLOAD_LINK
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_DIRECT_DOWNLOAD_LINK
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -731,4 +729,4 @@ void init_directdownloadlink_dissector(struct ndpi_detection_module_struct *ndpi
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* dns.c
|
||||
*
|
||||
* Copyright (C) 2012-16 - ntop.org
|
||||
* Copyright (C) 2012-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -23,8 +23,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_DNS
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_DNS
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -247,5 +245,3 @@ void init_dns_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int3
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* dofus.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -24,8 +24,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_DOFUS
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_DOFUS
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -151,4 +149,4 @@ void init_dofus_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_in
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* drda.c
|
||||
*
|
||||
* Copyright (C) 2012-16 - ntop.org
|
||||
* Copyright (C) 2012-18 - ntop.org
|
||||
*
|
||||
* This module is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU Lesser General Public License as published by
|
||||
@@ -19,8 +19,6 @@
|
||||
*/
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_DRDA
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_DRDA
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -103,5 +101,3 @@ void init_drda_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif /* NDPI_PROTOCOL_DRDA */
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* dropbox.c
|
||||
*
|
||||
* Copyright (C) 2012-16 by ntop.org
|
||||
* Copyright (C) 2012-18 by ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -23,8 +23,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_DROPBOX
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_DROPBOX
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -91,7 +89,3 @@ void init_dropbox_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* eaq.c
|
||||
*
|
||||
* Copyright (C) 2015 - ntop.org
|
||||
* Copyright (C) 2015-18 - ntop.org
|
||||
*
|
||||
* This module is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU Lesser General Public License as published by
|
||||
@@ -27,8 +27,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_EAQ
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_EAQ
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -88,5 +86,3 @@ void init_eaq_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int3
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -25,8 +25,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_EDONKEY
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_EDONKEY
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -225,4 +223,3 @@ void init_edonkey_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* fasttrack.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -24,8 +24,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_FASTTRACK
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_FASTTRACK
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -94,5 +92,3 @@ void init_fasttrack_dissector(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -22,8 +22,6 @@
|
||||
|
||||
/* https://code.facebook.com/posts/608854979307125/building-zero-protocol-for-fast-secure-mobile-connections/ */
|
||||
|
||||
#ifdef NDPI_PROTOCOL_FBZERO
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_FBZERO
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -129,4 +127,3 @@ void init_fbzero_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_i
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* fiesta.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -24,8 +24,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_FIESTA
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_FIESTA
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -105,4 +103,3 @@ void init_fiesta_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_i
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* fix.c
|
||||
*
|
||||
* Copyright (C) 2017 - ntop.org
|
||||
* Copyright (C) 2017-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -23,8 +23,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_FIX
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_FIX
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -75,6 +73,3 @@ void init_fix_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int3
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* florensia.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -24,8 +24,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_FLORENSIA
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_FLORENSIA
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -129,5 +127,3 @@ void init_florensia_dissector(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* ftp_control.c
|
||||
*
|
||||
* Copyright (C) 2016 - ntop.org
|
||||
* Copyright (C) 2016-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -23,8 +23,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_FTP_CONTROL
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_FTP_CONTROL
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -1014,5 +1012,3 @@ void init_ftp_control_dissector(struct ndpi_detection_module_struct *ndpi_struct
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* ftp_data.c
|
||||
*
|
||||
* Copyright (C) 2016 - ntop.org
|
||||
* Copyright (C) 2016-18 - ntop.org
|
||||
*
|
||||
* The signature is based on the Libprotoident library.
|
||||
*
|
||||
@@ -25,8 +25,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_FTP_DATA
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_FTP_DATA
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -258,5 +256,3 @@ void init_ftp_data_dissector(struct ndpi_detection_module_struct *ndpi_struct, u
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* git.c
|
||||
*
|
||||
* Copyright (C) 2012-16 - ntop.org
|
||||
* Copyright (C) 2012-18 - ntop.org
|
||||
*
|
||||
* This module is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU Lesser General Public License as published by
|
||||
@@ -20,8 +20,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_GIT
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_GIT
|
||||
|
||||
#include <stdlib.h>
|
||||
@@ -73,7 +71,6 @@ void ndpi_search_git(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
|
||||
/* ***************************************************************** */
|
||||
|
||||
|
||||
void init_git_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int32_t *id,
|
||||
NDPI_PROTOCOL_BITMASK *detection_bitmask)
|
||||
{
|
||||
@@ -86,5 +83,3 @@ void init_git_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int3
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif /* NDPI_PROTOCOL_GIT */
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* gnutella.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -24,8 +24,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_GNUTELLA
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_GNUTELLA
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -371,5 +369,3 @@ void init_gnutella_dissector(struct ndpi_detection_module_struct *ndpi_struct, u
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* gtp.c
|
||||
*
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* nDPI is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU Lesser General Public License as published by
|
||||
@@ -20,8 +20,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_GTP
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_GTP
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -89,5 +87,3 @@ void init_gtp_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int3
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* guildwars.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -24,8 +24,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_GUILDWARS
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_GUILDWARS
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -78,5 +76,3 @@ void init_guildwars_dissector(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,16 +1,13 @@
|
||||
/*
|
||||
* h323.c
|
||||
*
|
||||
* Copyright (C) 2015 ntop.org
|
||||
* Copyright (C) 2015-18 ntop.org
|
||||
* Copyright (C) 2013 Remy Mudingay <mudingay@ill.fr>
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_H323
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_H323
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -115,5 +112,3 @@ void init_h323_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* halflife2_and_mods.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -25,8 +25,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_HALFLIFE2
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_HALFLIFE2
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -77,5 +75,3 @@ void init_halflife2_dissector(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* hangout.c
|
||||
*
|
||||
* Copyright (C) 2012-16 - ntop.org
|
||||
* Copyright (C) 2012-18 - ntop.org
|
||||
*
|
||||
* This module is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU Lesser General Public License as published by
|
||||
@@ -20,8 +20,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_HANGOUT
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_HANGOUT
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -109,4 +107,3 @@ void init_hangout_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif /* NDPI_PROTOCOL_HANGOUT */
|
||||
|
||||
+11
-14
@@ -2,7 +2,7 @@
|
||||
* hep.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
* Copyright (C) 2011-15 - QXIP BV
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
@@ -26,8 +26,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_HEP
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_HEP
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -45,16 +43,17 @@ void ndpi_search_hep(struct ndpi_detection_module_struct *ndpi_struct, struct nd
|
||||
const u_int8_t *packet_payload = packet->payload;
|
||||
u_int32_t payload_len = packet->payload_packet_len;
|
||||
|
||||
NDPI_LOG_DBG(ndpi_struct, "searching HEP\n");
|
||||
if (payload_len > 10) {
|
||||
if (memcmp(packet_payload, "HEP3", 4) == 0) {
|
||||
NDPI_LOG_INFO(ndpi_struct, "found HEP3\n");
|
||||
ndpi_int_hep_add_connection(ndpi_struct, flow);
|
||||
return;
|
||||
}
|
||||
}
|
||||
NDPI_LOG_DBG(ndpi_struct, "searching HEP\n");
|
||||
|
||||
NDPI_EXCLUDE_PROTO(ndpi_struct, flow);
|
||||
if(payload_len > 10) {
|
||||
if(memcmp(packet_payload, "HEP3", 4) == 0) {
|
||||
NDPI_LOG_INFO(ndpi_struct, "found HEP3\n");
|
||||
ndpi_int_hep_add_connection(ndpi_struct, flow);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
NDPI_EXCLUDE_PROTO(ndpi_struct, flow);
|
||||
}
|
||||
|
||||
|
||||
@@ -69,5 +68,3 @@ void init_hep_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int3
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
+13
-32
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* http.c
|
||||
*
|
||||
* Copyright (C) 2011-17 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -23,8 +23,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_HTTP
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_HTTP
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -121,7 +119,6 @@ static void avi_check_http_payload(struct ndpi_detection_module_struct *ndpi_str
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef NDPI_PROTOCOL_TEAMVIEWER
|
||||
static void teamviewer_check_http_payload(struct ndpi_detection_module_struct *ndpi_struct, struct ndpi_flow_struct *flow)
|
||||
{
|
||||
struct ndpi_packet_struct *packet = &flow->packet;
|
||||
@@ -140,10 +137,7 @@ static void teamviewer_check_http_payload(struct ndpi_detection_module_struct *n
|
||||
ndpi_int_http_add_connection(ndpi_struct, flow, NDPI_PROTOCOL_TEAMVIEWER);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
#ifdef NDPI_PROTOCOL_RTSP
|
||||
static void rtsp_parse_packet_acceptline(struct ndpi_detection_module_struct
|
||||
*ndpi_struct, struct ndpi_flow_struct *flow)
|
||||
{
|
||||
@@ -154,7 +148,6 @@ static void rtsp_parse_packet_acceptline(struct ndpi_detection_module_struct
|
||||
ndpi_int_http_add_connection(ndpi_struct, flow, NDPI_PROTOCOL_RTSP);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
static void setHttpUserAgent(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
struct ndpi_flow_struct *flow, char *ua) {
|
||||
@@ -428,25 +421,20 @@ static void check_content_type_and_change_protocol(struct ndpi_detection_module_
|
||||
if(packet->accept_line.ptr != NULL) {
|
||||
NDPI_LOG_DBG2(ndpi_struct, "Accept line found %.*s\n",
|
||||
packet->accept_line.len, packet->accept_line.ptr);
|
||||
#ifdef NDPI_PROTOCOL_RTSP
|
||||
if(NDPI_COMPARE_PROTOCOL_TO_BITMASK(ndpi_struct->detection_bitmask, NDPI_PROTOCOL_RTSP) != 0) {
|
||||
if(NDPI_COMPARE_PROTOCOL_TO_BITMASK(ndpi_struct->detection_bitmask,
|
||||
NDPI_PROTOCOL_RTSP) != 0) {
|
||||
rtsp_parse_packet_acceptline(ndpi_struct, flow);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
/* search for line startin with "Icy-MetaData" */
|
||||
#ifdef NDPI_CONTENT_CATEGORY_MPEG
|
||||
for (a = 0; a < packet->parsed_lines; a++) {
|
||||
for (a = 0; a < packet->parsed_lines; a++) {
|
||||
if(packet->line[a].len > 11 && memcmp(packet->line[a].ptr, "Icy-MetaData", 12) == 0) {
|
||||
NDPI_LOG_INFO(ndpi_struct, "found MPEG: Icy-MetaData\n");
|
||||
ndpi_int_http_add_connection(ndpi_struct, flow, NDPI_CONTENT_CATEGORY_MPEG);
|
||||
return;
|
||||
}
|
||||
NDPI_LOG_INFO(ndpi_struct, "found MPEG: Icy-MetaData\n");
|
||||
ndpi_int_http_add_connection(ndpi_struct, flow, NDPI_CONTENT_CATEGORY_MPEG);
|
||||
return;
|
||||
}
|
||||
}
|
||||
#ifdef NDPI_CONTENT_CATEGORY_AVI
|
||||
#endif
|
||||
#endif
|
||||
|
||||
if(packet->content_line.ptr != NULL && packet->content_line.len != 0) {
|
||||
NDPI_LOG_DBG2(ndpi_struct, "Content Type line found %.*s\n",
|
||||
@@ -471,10 +459,8 @@ static void check_http_payload(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
if(NDPI_COMPARE_PROTOCOL_TO_BITMASK(ndpi_struct->detection_bitmask, NDPI_CONTENT_CATEGORY_AVI) != 0)
|
||||
avi_check_http_payload(ndpi_struct, flow);
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_TEAMVIEWER
|
||||
teamviewer_check_http_payload(ndpi_struct, flow);
|
||||
#endif
|
||||
|
||||
teamviewer_check_http_payload(ndpi_struct, flow);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -550,9 +536,8 @@ static void http_bitmask_exclude_other(struct ndpi_flow_struct *flow)
|
||||
#ifdef NDPI_CONTENT_CATEGORY_OGG
|
||||
NDPI_ADD_PROTOCOL_TO_BITMASK(flow->excluded_protocol_bitmask, NDPI_CONTENT_CATEGORY_OGG);
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_XBOX
|
||||
|
||||
NDPI_ADD_PROTOCOL_TO_BITMASK(flow->excluded_protocol_bitmask, NDPI_PROTOCOL_XBOX);
|
||||
#endif
|
||||
}
|
||||
|
||||
/*************************************************************************************************/
|
||||
@@ -1007,7 +992,7 @@ void init_http_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_XBOX
|
||||
|
||||
ndpi_set_bitmask_protocol_detection("Xbox", ndpi_struct, detection_bitmask, *id,
|
||||
NDPI_PROTOCOL_XBOX,
|
||||
ndpi_search_http_tcp,
|
||||
@@ -1015,8 +1000,7 @@ void init_http_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int
|
||||
NO_SAVE_DETECTION_BITMASK_AS_UNKNOWN,
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_QQ
|
||||
|
||||
ndpi_set_bitmask_protocol_detection("QQ", ndpi_struct, detection_bitmask, *id,
|
||||
NDPI_PROTOCOL_QQ,
|
||||
ndpi_search_http_tcp,
|
||||
@@ -1024,7 +1008,7 @@ void init_http_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int
|
||||
NO_SAVE_DETECTION_BITMASK_AS_UNKNOWN,
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
#endif
|
||||
|
||||
#ifdef NDPI_CONTENT_CATEGORY_AVI
|
||||
ndpi_set_bitmask_protocol_detection("AVI", ndpi_struct, detection_bitmask, *id,
|
||||
NDPI_CONTENT_CATEGORY_AVI,
|
||||
@@ -1069,7 +1053,4 @@ void init_http_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int
|
||||
a++;
|
||||
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* http_activesync.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -26,42 +26,39 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_HTTP_APPLICATION_ACTIVESYNC
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_HTTP_APPLICATION_ACTIVESYNC
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_HTTP_ACTIVESYNC
|
||||
|
||||
#include "ndpi_api.h"
|
||||
|
||||
static void ndpi_int_activesync_add_connection(struct ndpi_detection_module_struct *ndpi_struct, struct ndpi_flow_struct *flow)
|
||||
{
|
||||
ndpi_set_detected_protocol(ndpi_struct, flow, NDPI_PROTOCOL_HTTP_APPLICATION_ACTIVESYNC, NDPI_PROTOCOL_HTTP);
|
||||
ndpi_set_detected_protocol(ndpi_struct, flow, NDPI_PROTOCOL_HTTP_ACTIVESYNC, NDPI_PROTOCOL_HTTP);
|
||||
}
|
||||
|
||||
void ndpi_search_activesync(struct ndpi_detection_module_struct *ndpi_struct, struct ndpi_flow_struct *flow)
|
||||
{
|
||||
struct ndpi_packet_struct *packet = &flow->packet;
|
||||
struct ndpi_packet_struct *packet = &flow->packet;
|
||||
|
||||
NDPI_LOG_DBG(ndpi_struct, "search activesync\n");
|
||||
if (packet->tcp != NULL) {
|
||||
NDPI_LOG_DBG(ndpi_struct, "search activesync\n");
|
||||
if (packet->tcp != NULL) {
|
||||
|
||||
if (packet->payload_packet_len > 150
|
||||
&& ((memcmp(packet->payload, "OPTIONS /Microsoft-Server-ActiveSync?", 37) == 0)
|
||||
|| (memcmp(packet->payload, "POST /Microsoft-Server-ActiveSync?", 34) == 0))) {
|
||||
ndpi_int_activesync_add_connection(ndpi_struct, flow);
|
||||
NDPI_LOG_INFO(ndpi_struct, "found ActiveSync \n");
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
NDPI_EXCLUDE_PROTO(ndpi_struct, flow);
|
||||
if (packet->payload_packet_len > 150
|
||||
&& ((memcmp(packet->payload, "OPTIONS /Microsoft-Server-ActiveSync?", 37) == 0)
|
||||
|| (memcmp(packet->payload, "POST /Microsoft-Server-ActiveSync?", 34) == 0))) {
|
||||
ndpi_int_activesync_add_connection(ndpi_struct, flow);
|
||||
NDPI_LOG_INFO(ndpi_struct, "found ActiveSync \n");
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
NDPI_EXCLUDE_PROTO(ndpi_struct, flow);
|
||||
}
|
||||
|
||||
|
||||
void init_http_activesync_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int32_t *id, NDPI_PROTOCOL_BITMASK *detection_bitmask)
|
||||
void init_http_activesync_dissector(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
u_int32_t *id, NDPI_PROTOCOL_BITMASK *detection_bitmask)
|
||||
{
|
||||
ndpi_set_bitmask_protocol_detection("HTTP_Application_ActiveSync", ndpi_struct, detection_bitmask, *id,
|
||||
NDPI_PROTOCOL_HTTP_APPLICATION_ACTIVESYNC,
|
||||
NDPI_PROTOCOL_HTTP_ACTIVESYNC,
|
||||
ndpi_search_activesync,
|
||||
NDPI_SELECTION_BITMASK_PROTOCOL_V4_V6_TCP_WITH_PAYLOAD_WITHOUT_RETRANSMISSION,
|
||||
SAVE_DETECTION_BITMASK_AS_UNKNOWN,
|
||||
@@ -70,4 +67,3 @@ void init_http_activesync_dissector(struct ndpi_detection_module_struct *ndpi_st
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* iax.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -25,8 +25,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_IAX
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_IAX
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -107,5 +105,3 @@ void init_iax_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int3
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
+13
-15
@@ -2,7 +2,7 @@
|
||||
* icecast.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -24,8 +24,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_ICECAST
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_ICECAST
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -42,13 +40,13 @@ void ndpi_search_icecast_tcp(struct ndpi_detection_module_struct *ndpi_struct, s
|
||||
|
||||
NDPI_LOG_DBG(ndpi_struct, "search icecast\n");
|
||||
|
||||
if ((packet->payload_packet_len < 500 &&
|
||||
if((packet->payload_packet_len < 500 &&
|
||||
packet->payload_packet_len >= 7 && memcmp(packet->payload, "SOURCE ", 7) == 0)
|
||||
|| flow->l4.tcp.icecast_stage) {
|
||||
ndpi_parse_packet_line_info_any(ndpi_struct, flow);
|
||||
NDPI_LOG_DBG2(ndpi_struct, "Icecast lines=%d\n", packet->parsed_lines);
|
||||
for (i = 0; i < packet->parsed_lines; i++) {
|
||||
if (packet->line[i].ptr != NULL && packet->line[i].len > 4
|
||||
if(packet->line[i].ptr != NULL && packet->line[i].len > 4
|
||||
&& memcmp(packet->line[i].ptr, "ice-", 4) == 0) {
|
||||
NDPI_LOG_INFO(ndpi_struct, "found Icecast\n");
|
||||
ndpi_int_icecast_add_connection(ndpi_struct, flow);
|
||||
@@ -56,28 +54,30 @@ void ndpi_search_icecast_tcp(struct ndpi_detection_module_struct *ndpi_struct, s
|
||||
}
|
||||
}
|
||||
|
||||
if (packet->parsed_lines < 1 && !flow->l4.tcp.icecast_stage) {
|
||||
if(packet->parsed_lines < 1 && !flow->l4.tcp.icecast_stage) {
|
||||
flow->l4.tcp.icecast_stage = 1;
|
||||
return;
|
||||
}
|
||||
}
|
||||
#ifdef NDPI_PROTOCOL_HTTP
|
||||
if (NDPI_FLOW_PROTOCOL_EXCLUDED(ndpi_struct, flow, NDPI_PROTOCOL_HTTP)) {
|
||||
|
||||
if(NDPI_FLOW_PROTOCOL_EXCLUDED(ndpi_struct, flow, NDPI_PROTOCOL_HTTP)) {
|
||||
goto icecast_exclude;
|
||||
}
|
||||
#endif
|
||||
|
||||
if (packet->packet_direction == flow->setup_packet_direction && flow->packet_counter < 10) {
|
||||
if((packet->packet_direction == flow->setup_packet_direction)
|
||||
&& (flow->packet_counter < 10)) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (packet->packet_direction != flow->setup_packet_direction) {
|
||||
if(packet->packet_direction != flow->setup_packet_direction) {
|
||||
/* server answer, now test Server for Icecast */
|
||||
|
||||
ndpi_parse_packet_line_info(ndpi_struct, flow);
|
||||
|
||||
if (packet->server_line.ptr != NULL && packet->server_line.len > NDPI_STATICSTRING_LEN("Icecast") &&
|
||||
memcmp(packet->server_line.ptr, "Icecast", NDPI_STATICSTRING_LEN("Icecast")) == 0) {
|
||||
if((packet->server_line.ptr != NULL)
|
||||
&& (packet->server_line.len > NDPI_STATICSTRING_LEN("Icecast"))
|
||||
&& memcmp(packet->server_line.ptr, "Icecast",
|
||||
NDPI_STATICSTRING_LEN("Icecast")) == 0) {
|
||||
/* TODO maybe store the previous protocol type as subtype?
|
||||
* e.g. ogg or mpeg
|
||||
*/
|
||||
@@ -103,5 +103,3 @@ void init_icecast_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* ipp.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -24,8 +24,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_IPP
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_IPP
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -123,5 +121,3 @@ void init_ipp_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int3
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* irc.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -25,8 +25,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_IRC
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_IRC
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -778,8 +776,8 @@ void ndpi_search_irc_tcp(struct ndpi_detection_module_struct *ndpi_struct, struc
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void init_irc_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int32_t *id, NDPI_PROTOCOL_BITMASK *detection_bitmask)
|
||||
void init_irc_dissector(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
u_int32_t *id, NDPI_PROTOCOL_BITMASK *detection_bitmask)
|
||||
{
|
||||
ndpi_set_bitmask_protocol_detection("IRC", ndpi_struct, detection_bitmask, *id,
|
||||
NDPI_PROTOCOL_IRC,
|
||||
@@ -791,4 +789,3 @@ void init_irc_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int3
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* jabber.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -24,8 +24,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_UNENCRYPTED_JABBER
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_UNENCRYPTED_JABBER
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -36,10 +34,8 @@ struct jabber_string {
|
||||
};
|
||||
|
||||
static struct jabber_string jabber_strings[] = {
|
||||
#ifdef NDPI_PROTOCOL_TRUPHONE
|
||||
{ "='im.truphone.com'", NDPI_PROTOCOL_TRUPHONE },
|
||||
{ "=\"im.truphone.com\"", NDPI_PROTOCOL_TRUPHONE },
|
||||
#endif
|
||||
{ NULL, 0 }
|
||||
};
|
||||
|
||||
@@ -289,9 +285,8 @@ void ndpi_search_jabber_tcp(struct ndpi_detection_module_struct *ndpi_struct, st
|
||||
|
||||
NDPI_EXCLUDE_PROTO(ndpi_struct, flow);
|
||||
|
||||
#ifdef NDPI_PROTOCOL_TRUPHONE
|
||||
ndpi_exclude_protocol(ndpi_struct, flow, NDPI_PROTOCOL_TRUPHONE,__FILE__,__FUNCTION__,__LINE__);
|
||||
#endif
|
||||
ndpi_exclude_protocol(ndpi_struct, flow, NDPI_PROTOCOL_TRUPHONE,
|
||||
__FILE__,__FUNCTION__,__LINE__);
|
||||
}
|
||||
|
||||
|
||||
@@ -306,4 +301,4 @@ void init_jabber_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_i
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* kakaotalk_voice.c
|
||||
*
|
||||
* Copyright (C) 2015 - ntop.org
|
||||
* Copyright (C) 2015-18 - ntop.org
|
||||
*
|
||||
* This module is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU Lesser General Public License as published by
|
||||
@@ -26,8 +26,6 @@
|
||||
*/
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_KAKAOTALK_VOICE
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_KAKAOTALK_VOICE
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -66,7 +64,8 @@ void ndpi_search_kakaotalk_voice(struct ndpi_detection_module_struct *ndpi_struc
|
||||
}
|
||||
|
||||
|
||||
void init_kakaotalk_voice_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int32_t *id, NDPI_PROTOCOL_BITMASK *detection_bitmask)
|
||||
void init_kakaotalk_voice_dissector(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
u_int32_t *id, NDPI_PROTOCOL_BITMASK *detection_bitmask)
|
||||
{
|
||||
ndpi_set_bitmask_protocol_detection("KakaoTalk_Voice", ndpi_struct, detection_bitmask, *id,
|
||||
NDPI_PROTOCOL_KAKAOTALK_VOICE,
|
||||
@@ -77,4 +76,3 @@ void init_kakaotalk_voice_dissector(struct ndpi_detection_module_struct *ndpi_st
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* kerberos.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -24,8 +24,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_KERBEROS
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_KERBEROS
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -80,4 +78,3 @@ void init_kerberos_dissector(struct ndpi_detection_module_struct *ndpi_struct, u
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* kontiki.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -25,8 +25,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_KONTIKI
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_KONTIKI
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -66,7 +64,8 @@ void ndpi_search_kontiki(struct ndpi_detection_module_struct *ndpi_struct, struc
|
||||
}
|
||||
|
||||
|
||||
void init_kontiki_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int32_t *id, NDPI_PROTOCOL_BITMASK *detection_bitmask)
|
||||
void init_kontiki_dissector(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
u_int32_t *id, NDPI_PROTOCOL_BITMASK *detection_bitmask)
|
||||
{
|
||||
ndpi_set_bitmask_protocol_detection("Kontiki", ndpi_struct, detection_bitmask, *id,
|
||||
NDPI_PROTOCOL_KONTIKI,
|
||||
@@ -78,4 +77,3 @@ void init_kontiki_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* ldap.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -24,8 +24,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_LDAP
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_LDAP
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -104,4 +102,3 @@ void init_ldap_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_LISP
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_LISP
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -68,4 +66,3 @@ void init_lisp_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* lotus_notes.c
|
||||
*
|
||||
* Copyright (C) 2012-15 - ntop.org
|
||||
* Copyright (C) 2012-18 - ntop.org
|
||||
*
|
||||
* nDPI is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU Lesser General Public License as published by
|
||||
@@ -20,13 +20,10 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_LOTUS_NOTES
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_LOTUS_NOTES
|
||||
|
||||
#include "ndpi_api.h"
|
||||
|
||||
|
||||
/* ************************************ */
|
||||
|
||||
static void ndpi_check_lotus_notes(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
@@ -84,4 +81,3 @@ void init_lotus_notes_dissector(struct ndpi_detection_module_struct *ndpi_struct
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* mail_imap.c
|
||||
*
|
||||
* Copyright (C) 2016 - ntop.org
|
||||
* Copyright (C) 2016-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -24,8 +24,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_MAIL_IMAP
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_MAIL_IMAP
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -48,12 +46,10 @@ void ndpi_search_mail_imap_tcp(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
NDPI_LOG_DBG(ndpi_struct, "search IMAP_IMAP\n");
|
||||
|
||||
if (flow->l4.tcp.mail_imap_starttls == 2) {
|
||||
#ifdef NDPI_PROTOCOL_SSL
|
||||
NDPI_LOG_DBG2(ndpi_struct, "starttls detected\n");
|
||||
NDPI_ADD_PROTOCOL_TO_BITMASK(flow->excluded_protocol_bitmask, NDPI_PROTOCOL_MAIL_IMAP);
|
||||
NDPI_DEL_PROTOCOL_FROM_BITMASK(flow->excluded_protocol_bitmask, NDPI_PROTOCOL_SSL);
|
||||
return;
|
||||
#endif
|
||||
}
|
||||
|
||||
if (packet->payload_packet_len >= 4 && ntohs(get_u_int16_t(packet->payload, packet->payload_packet_len - 2)) == 0x0d0a) {
|
||||
@@ -320,5 +316,3 @@ void init_mail_imap_dissector(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* mail_pop.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -25,8 +25,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_MAIL_POP
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_MAIL_POP
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -212,5 +210,3 @@ void init_mail_pop_dissector(struct ndpi_detection_module_struct *ndpi_struct, u
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* mail_smtp.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -25,8 +25,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_MAIL_SMTP
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_MAIL_SMTP
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -189,4 +187,3 @@ void init_mail_smtp_dissector(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* maplestory.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -24,8 +24,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_MAPLESTORY
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_MAPLESTORY
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -94,5 +92,3 @@ void init_maplestory_dissector(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* mdns.c
|
||||
*
|
||||
* Copyright (C) 2016-17 - ntop.org
|
||||
* Copyright (C) 2016-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -22,8 +22,6 @@
|
||||
*/
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_MDNS
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_MDNS
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -159,4 +157,3 @@ void init_mdns_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* megaco.c
|
||||
*
|
||||
* Copyright (C) 2014 by Gianluca Costa http://www.capanalysis.net
|
||||
* Copyright (C) 2012-15 - ntop.org
|
||||
* Copyright (C) 2012-18 - ntop.org
|
||||
*
|
||||
* This module is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU Lesser General Public License as published by
|
||||
@@ -20,14 +20,13 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_MEGACO
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_MEGACO
|
||||
|
||||
#include "ndpi_api.h"
|
||||
|
||||
|
||||
void ndpi_search_megaco(struct ndpi_detection_module_struct *ndpi_struct, struct ndpi_flow_struct *flow)
|
||||
void ndpi_search_megaco(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
struct ndpi_flow_struct *flow)
|
||||
{
|
||||
struct ndpi_packet_struct *packet = &flow->packet;
|
||||
|
||||
@@ -61,4 +60,3 @@ void init_megaco_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_i
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* mgcp.c
|
||||
*
|
||||
* Copyright (C) 2017 - ntop.org
|
||||
* Copyright (C) 2017-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -23,14 +23,10 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_MGCP
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_MGCP
|
||||
|
||||
#include "ndpi_api.h"
|
||||
|
||||
|
||||
|
||||
static void ndpi_int_mgcp_add_connection(struct ndpi_detection_module_struct
|
||||
*ndpi_struct, struct ndpi_flow_struct *flow)
|
||||
{
|
||||
@@ -93,4 +89,3 @@ void init_mgpc_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* mpegts.c (MPEG Transport Stream)
|
||||
* https://en.wikipedia.org/wiki/MPEG_transport_stream
|
||||
*
|
||||
* Copyright (C) 2015 - ntop.org
|
||||
* Copyright (C) 2015-18 - ntop.org
|
||||
*
|
||||
* nDPI is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU Lesser General Public License as published by
|
||||
@@ -21,8 +21,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_MPEGTS
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_MPEGTS
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -65,4 +63,3 @@ void init_mpegts_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_i
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -23,8 +23,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_MQTT
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_MQTT
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -255,5 +253,4 @@ void init_mqtt_dissector (struct ndpi_detection_module_struct *ndpi_struct,
|
||||
*id +=1;
|
||||
}
|
||||
|
||||
#endif // NDPI_PROTOCOL_MQTT
|
||||
|
||||
|
||||
+22
-39
@@ -2,7 +2,7 @@
|
||||
* msn.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -24,9 +24,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
|
||||
#ifdef NDPI_PROTOCOL_MSN
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_MSN
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -65,7 +62,6 @@ static void ndpi_search_msn_tcp(struct ndpi_detection_module_struct *ndpi_struct
|
||||
u_int16_t plen;
|
||||
u_int16_t status = 0;
|
||||
|
||||
#ifdef NDPI_PROTOCOL_SSL
|
||||
if(packet->detected_protocol_stack[0] == NDPI_PROTOCOL_SSL) {
|
||||
|
||||
NDPI_LOG_DBG2(ndpi_struct, "msn ssl ft test\n");
|
||||
@@ -73,28 +69,32 @@ static void ndpi_search_msn_tcp(struct ndpi_detection_module_struct *ndpi_struct
|
||||
if(flow->packet_counter < 10) {
|
||||
if(flow->packet_counter == 7 && packet->payload_packet_len > 300) {
|
||||
if(memcmp(packet->payload + 24, "MSNSLP", 6) == 0
|
||||
|| (get_u_int32_t(packet->payload, 0) == htonl(0x30000000) && get_u_int32_t(packet->payload, 4) == 0x00000000)) {
|
||||
|| (get_u_int32_t(packet->payload, 0) == htonl(0x30000000)
|
||||
&& get_u_int32_t(packet->payload, 4) == 0x00000000)) {
|
||||
NDPI_LOG_INFO(ndpi_struct, "found MSN File Transfer, ifdef ssl\n");
|
||||
ndpi_int_msn_add_connection(ndpi_struct, flow);
|
||||
return;
|
||||
}
|
||||
}
|
||||
if(flow->packet_counter >= 5 && flow->packet_counter <= 10 && (get_u_int32_t(packet->payload, 0) == htonl(0x18000000)
|
||||
&& get_u_int32_t(packet->payload, 4) == 0x00000000)) {
|
||||
|
||||
if(flow->packet_counter >= 5 && flow->packet_counter <= 10
|
||||
&& (get_u_int32_t(packet->payload, 0) == htonl(0x18000000)
|
||||
&& get_u_int32_t(packet->payload, 4) == 0x00000000)) {
|
||||
flow->l4.tcp.msn_ssl_ft++;
|
||||
NDPI_LOG_DBG2(ndpi_struct,
|
||||
"increased msn ft ssl stage to: %u at packet nr: %u\n", flow->l4.tcp.msn_ssl_ft,
|
||||
"increased msn ft ssl stage to: %u at packet nr: %u\n",
|
||||
flow->l4.tcp.msn_ssl_ft,
|
||||
flow->packet_counter);
|
||||
if (flow->l4.tcp.msn_ssl_ft == 2) {
|
||||
NDPI_LOG_INFO(ndpi_struct,
|
||||
"found MSN File Transfer, ifdef ssl 2.\n");
|
||||
ndpi_int_msn_add_connection(ndpi_struct, flow);
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
/* we detect the initial connection only ! */
|
||||
/* match: "VER " ..... "CVR" x 0x0d 0x0a
|
||||
@@ -103,15 +103,17 @@ static void ndpi_search_msn_tcp(struct ndpi_detection_module_struct *ndpi_struct
|
||||
*/
|
||||
/* now we have a look at the first packet only. */
|
||||
if(flow->packet_counter == 1
|
||||
#ifdef NDPI_PROTOCOL_SSL
|
||||
|| ((packet->detected_protocol_stack[0] == NDPI_PROTOCOL_SSL) && flow->packet_counter <= 3)
|
||||
#endif
|
||||
|| ((packet->detected_protocol_stack[0] == NDPI_PROTOCOL_SSL)
|
||||
&& flow->packet_counter <= 3)
|
||||
) {
|
||||
|
||||
/* this part is working asymmetrically */
|
||||
if(packet->payload_packet_len > 32 && (packet->payload[0] == 0x02 || packet->payload[0] == 0x00)
|
||||
&& (ntohl(get_u_int32_t(packet->payload, 8)) == 0x2112a442 || ntohl(get_u_int32_t(packet->payload, 4)) == 0x2112a442)
|
||||
&& ((ntohl(get_u_int32_t(packet->payload, 24)) == 0x000f0004 && ntohl(get_u_int32_t(packet->payload, 28)) == 0x72c64bc6)
|
||||
if(packet->payload_packet_len > 32
|
||||
&& (packet->payload[0] == 0x02 || packet->payload[0] == 0x00)
|
||||
&& (ntohl(get_u_int32_t(packet->payload, 8)) == 0x2112a442
|
||||
|| ntohl(get_u_int32_t(packet->payload, 4)) == 0x2112a442)
|
||||
&& ((ntohl(get_u_int32_t(packet->payload, 24)) == 0x000f0004
|
||||
&& ntohl(get_u_int32_t(packet->payload, 28)) == 0x72c64bc6)
|
||||
|| (ntohl(get_u_int32_t(packet->payload, 20)) == 0x000f0004
|
||||
&& ntohl(get_u_int32_t(packet->payload, 24)) == 0x72c64bc6))) {
|
||||
NDPI_LOG_INFO(ndpi_struct,
|
||||
@@ -145,10 +147,9 @@ static void ndpi_search_msn_tcp(struct ndpi_detection_module_struct *ndpi_struct
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if(
|
||||
#ifdef NDPI_PROTOCOL_HTTP
|
||||
packet->detected_protocol_stack[0] == NDPI_PROTOCOL_HTTP ||
|
||||
#endif
|
||||
ndpi_match_strprefix(packet->payload, packet->payload_packet_len, "GET ") ||
|
||||
ndpi_match_strprefix(packet->payload, packet->payload_packet_len, "POST ")) {
|
||||
ndpi_parse_packet_line_info(ndpi_struct, flow);
|
||||
@@ -160,18 +161,12 @@ static void ndpi_search_msn_tcp(struct ndpi_detection_module_struct *ndpi_struct
|
||||
return;
|
||||
}
|
||||
}
|
||||
/* #ifdef NDPI_PROTOCOL_HTTP */
|
||||
/* /\* we have to examine two http packets *\/ */
|
||||
/* if(packet->detected_protocol_stack[0] == NDPI_PROTOCOL_HTTP) { */
|
||||
/* } */
|
||||
/* #endif */
|
||||
|
||||
/* not seen this pattern in any trace */
|
||||
/* now test for http login, at least 100 a bytes packet */
|
||||
if(packet->payload_packet_len > 100) {
|
||||
if(
|
||||
#ifdef NDPI_PROTOCOL_HTTP
|
||||
packet->detected_protocol_stack[0] == NDPI_PROTOCOL_HTTP ||
|
||||
#endif
|
||||
memcmp(packet->payload, "POST http://", 12) == 0) {
|
||||
/* scan packet if not already done... */
|
||||
ndpi_parse_packet_line_info(ndpi_struct, flow);
|
||||
@@ -193,9 +188,7 @@ static void ndpi_search_msn_tcp(struct ndpi_detection_module_struct *ndpi_struct
|
||||
/* for this case the asymmetric detection is asym (1) */
|
||||
if(packet->payload_packet_len > 400) {
|
||||
if((
|
||||
#ifdef NDPI_PROTOCOL_HTTP
|
||||
packet->detected_protocol_stack[0] == NDPI_PROTOCOL_HTTP ||
|
||||
#endif
|
||||
(memcmp(packet->payload, "POST ", 5) == 0))) {
|
||||
u_int16_t c;
|
||||
if(memcmp(&packet->payload[5], "http://", 7) == 0) {
|
||||
@@ -259,9 +252,7 @@ static void ndpi_search_msn_tcp(struct ndpi_detection_module_struct *ndpi_struct
|
||||
&& packet->payload_packet_len > 100) {
|
||||
/* not necessary to check the length, because this has been done : >400. */
|
||||
if(
|
||||
#ifdef NDPI_PROTOCOL_HTTP
|
||||
packet->detected_protocol_stack[0] == NDPI_PROTOCOL_HTTP ||
|
||||
#endif
|
||||
ndpi_match_strprefix(packet->payload, packet->payload_packet_len, "HTTP/1.0 200 OK") ||
|
||||
ndpi_match_strprefix(packet->payload, packet->payload_packet_len, "HTTP/1.1 200 OK")
|
||||
) {
|
||||
@@ -342,9 +333,7 @@ static void ndpi_search_msn_tcp(struct ndpi_detection_module_struct *ndpi_struct
|
||||
packet->payload_packet_len > 100) {
|
||||
/* not necessary to check the length, because this has been done : >400. */
|
||||
if(
|
||||
#ifdef NDPI_PROTOCOL_HTTP
|
||||
packet->detected_protocol_stack[0] == NDPI_PROTOCOL_HTTP ||
|
||||
#endif
|
||||
(memcmp(packet->payload, "HTTP/1.0 200 OK", 15) == 0) ||
|
||||
(memcmp(packet->payload, "HTTP/1.1 200 OK", 15) == 0)) {
|
||||
|
||||
@@ -507,15 +496,9 @@ void ndpi_search_msn(struct ndpi_detection_module_struct *ndpi_struct, struct nd
|
||||
/* the detection can switch out the http or the ssl detection. In this case we need not check those protocols */
|
||||
// need to do the ceck when protocol == http too (POST /gateway ...)
|
||||
if(packet->detected_protocol_stack[0] == NDPI_PROTOCOL_UNKNOWN
|
||||
#ifdef NDPI_PROTOCOL_HTTP
|
||||
|| packet->detected_protocol_stack[0] == NDPI_PROTOCOL_HTTP
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_SSL
|
||||
|| packet->detected_protocol_stack[0] == NDPI_PROTOCOL_SSL
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_STUN
|
||||
|| packet->detected_protocol_stack[0] == NDPI_PROTOCOL_STUN
|
||||
#endif
|
||||
)
|
||||
ndpi_search_msn_tcp(ndpi_struct, flow);
|
||||
} else if (packet->udp != NULL) {
|
||||
@@ -525,7 +508,8 @@ void ndpi_search_msn(struct ndpi_detection_module_struct *ndpi_struct, struct nd
|
||||
}
|
||||
|
||||
|
||||
void init_msn_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int32_t *id, NDPI_PROTOCOL_BITMASK *detection_bitmask)
|
||||
void init_msn_dissector(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
u_int32_t *id, NDPI_PROTOCOL_BITMASK *detection_bitmask)
|
||||
{
|
||||
|
||||
NDPI_BITMASK_RESET(ndpi_struct->callback_buffer[*id].excluded_protocol_bitmask);
|
||||
@@ -540,4 +524,3 @@ void init_msn_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int3
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* mssql.c
|
||||
*
|
||||
* Copyright (C) 2016 - ntop.org
|
||||
* Copyright (C) 2016-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -24,8 +24,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_MSSQL_TDS
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_MSSQL_TDS
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -83,5 +81,3 @@ void init_mssql_tds_dissector(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* mysql.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -25,8 +25,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_MYSQL
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_MYSQL
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -85,5 +83,3 @@ void init_mysql_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_in
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* netbios.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-17 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -25,8 +25,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_NETBIOS
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_NETBIOS
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -390,5 +388,3 @@ void init_netbios_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* netflow.c
|
||||
*
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* nDPI is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU Lesser General Public License as published by
|
||||
@@ -20,8 +20,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_NETFLOW
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_NETFLOW
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -184,4 +182,3 @@ void init_netflow_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* nfs.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -25,8 +25,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_NFS
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_NFS
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -101,4 +99,3 @@ void init_nfs_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int3
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* nintendo.c
|
||||
*
|
||||
* Copyright (C) 2017 by ntop.org
|
||||
* Copyright (C) 2017-18 by ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -23,8 +23,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_NINTENDO
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_NINTENDO
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -67,4 +65,3 @@ void init_nintendo_dissector(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -7,8 +7,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_NOE
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_NOE
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -21,7 +19,8 @@ static void ndpi_int_noe_add_connection(struct ndpi_detection_module_struct
|
||||
NDPI_LOG_INFO(ndpi_struct, "found noe\n");
|
||||
}
|
||||
|
||||
void ndpi_search_noe(struct ndpi_detection_module_struct *ndpi_struct, struct ndpi_flow_struct *flow)
|
||||
void ndpi_search_noe(struct ndpi_detection_module_struct *ndpi_struct,
|
||||
struct ndpi_flow_struct *flow)
|
||||
{
|
||||
struct ndpi_packet_struct *packet = &flow->packet;
|
||||
|
||||
@@ -66,4 +65,3 @@ void init_noe_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int3
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* non_tcp_udp.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -25,8 +25,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#if defined(NDPI_PROTOCOL_IP_IPSEC) || defined(NDPI_PROTOCOL_IP_GRE) || defined(NDPI_PROTOCOL_IP_ICMP) || defined(NDPI_PROTOCOL_IP_IGMP) || defined(NDPI_PROTOCOL_IP_EGP) || defined(NDPI_PROTOCOL_IP_SCTP) || defined(NDPI_PROTOCOL_IP_OSPF) || defined(NDPI_PROTOCOL_IP_IP_IN_IP)
|
||||
|
||||
#include "ndpi_api.h"
|
||||
|
||||
#define set_protocol_and_bmask(nprot) \
|
||||
@@ -52,57 +50,46 @@ void ndpi_search_in_non_tcp_udp(struct ndpi_detection_module_struct
|
||||
}
|
||||
|
||||
switch (packet->l4_protocol) {
|
||||
#ifdef NDPI_PROTOCOL_IP_IPSEC
|
||||
case NDPI_IPSEC_PROTOCOL_ESP:
|
||||
case NDPI_IPSEC_PROTOCOL_AH:
|
||||
set_protocol_and_bmask(NDPI_PROTOCOL_IP_IPSEC);
|
||||
break;
|
||||
#endif /* NDPI_PROTOCOL_IP_IPSEC */
|
||||
#ifdef NDPI_PROTOCOL_IP_GRE
|
||||
|
||||
case NDPI_GRE_PROTOCOL_TYPE:
|
||||
set_protocol_and_bmask(NDPI_PROTOCOL_IP_GRE);
|
||||
break;
|
||||
#endif /* NDPI_PROTOCOL_IP_GRE */
|
||||
#ifdef NDPI_PROTOCOL_IP_ICMP
|
||||
|
||||
case NDPI_ICMP_PROTOCOL_TYPE:
|
||||
set_protocol_and_bmask(NDPI_PROTOCOL_IP_ICMP);
|
||||
break;
|
||||
#endif /* NDPI_PROTOCOL_IP_ICMP */
|
||||
#ifdef NDPI_PROTOCOL_IP_IGMP
|
||||
|
||||
case NDPI_IGMP_PROTOCOL_TYPE:
|
||||
set_protocol_and_bmask(NDPI_PROTOCOL_IP_IGMP);
|
||||
break;
|
||||
#endif /* NDPI_PROTOCOL_IP_IGMP */
|
||||
#ifdef NDPI_PROTOCOL_IP_EGP
|
||||
|
||||
case NDPI_EGP_PROTOCOL_TYPE:
|
||||
set_protocol_and_bmask(NDPI_PROTOCOL_IP_EGP);
|
||||
break;
|
||||
#endif /* NDPI_PROTOCOL_IP_EGP */
|
||||
#ifdef NDPI_PROTOCOL_IP_SCTP
|
||||
|
||||
case NDPI_SCTP_PROTOCOL_TYPE:
|
||||
set_protocol_and_bmask(NDPI_PROTOCOL_IP_SCTP);
|
||||
break;
|
||||
#endif /* NDPI_PROTOCOL_IP_SCTP */
|
||||
#ifdef NDPI_PROTOCOL_IP_OSPF
|
||||
|
||||
case NDPI_OSPF_PROTOCOL_TYPE:
|
||||
set_protocol_and_bmask(NDPI_PROTOCOL_IP_OSPF);
|
||||
break;
|
||||
#endif /* NDPI_PROTOCOL_IP_OSPF */
|
||||
#ifdef NDPI_PROTOCOL_IP_IP_IN_IP
|
||||
|
||||
case NDPI_IPIP_PROTOCOL_TYPE:
|
||||
set_protocol_and_bmask(NDPI_PROTOCOL_IP_IP_IN_IP);
|
||||
break;
|
||||
#endif /* NDPI_PROTOCOL_IP_IP_IN_IP */
|
||||
#ifdef NDPI_PROTOCOL_IP_ICMPV6
|
||||
|
||||
case NDPI_ICMPV6_PROTOCOL_TYPE:
|
||||
set_protocol_and_bmask(NDPI_PROTOCOL_IP_ICMPV6);
|
||||
break;
|
||||
#endif /* NDPI_PROTOCOL_IP_ICMPV6 */
|
||||
#ifdef NDPI_PROTOCOL_IP_VRRP
|
||||
|
||||
case 112:
|
||||
set_protocol_and_bmask(NDPI_PROTOCOL_IP_VRRP);
|
||||
break;
|
||||
#endif /* NDPI_PROTOCOL_IP_VRRP */
|
||||
}
|
||||
}
|
||||
|
||||
@@ -113,7 +100,6 @@ void init_non_tcp_udp_dissector(struct ndpi_detection_module_struct *ndpi_struct
|
||||
/* always add non tcp/udp if one protocol is compiled in */
|
||||
NDPI_SAVE_AS_BITMASK(ndpi_struct->callback_buffer[*id].detection_bitmask, NDPI_PROTOCOL_UNKNOWN);
|
||||
|
||||
#ifdef NDPI_PROTOCOL_IP_IPSEC
|
||||
ndpi_set_bitmask_protocol_detection("IP_IPSEC", ndpi_struct, detection_bitmask, *id,
|
||||
NDPI_PROTOCOL_IP_IPSEC,
|
||||
ndpi_search_in_non_tcp_udp,
|
||||
@@ -121,8 +107,7 @@ void init_non_tcp_udp_dissector(struct ndpi_detection_module_struct *ndpi_struct
|
||||
NO_SAVE_DETECTION_BITMASK_AS_UNKNOWN,
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_IP_GRE
|
||||
|
||||
ndpi_set_bitmask_protocol_detection("IP_GRE", ndpi_struct, detection_bitmask, *id,
|
||||
NDPI_PROTOCOL_IP_GRE,
|
||||
ndpi_search_in_non_tcp_udp,
|
||||
@@ -130,8 +115,7 @@ void init_non_tcp_udp_dissector(struct ndpi_detection_module_struct *ndpi_struct
|
||||
NO_SAVE_DETECTION_BITMASK_AS_UNKNOWN,
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_IP_ICMP
|
||||
|
||||
ndpi_set_bitmask_protocol_detection("IP_ICMP", ndpi_struct, detection_bitmask, *id,
|
||||
NDPI_PROTOCOL_IP_ICMP,
|
||||
ndpi_search_in_non_tcp_udp,
|
||||
@@ -139,8 +123,7 @@ void init_non_tcp_udp_dissector(struct ndpi_detection_module_struct *ndpi_struct
|
||||
NO_SAVE_DETECTION_BITMASK_AS_UNKNOWN,
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_IP_IGMP
|
||||
|
||||
ndpi_set_bitmask_protocol_detection("IP_IGMP", ndpi_struct, detection_bitmask, *id,
|
||||
NDPI_PROTOCOL_IP_IGMP,
|
||||
ndpi_search_in_non_tcp_udp,
|
||||
@@ -148,8 +131,7 @@ void init_non_tcp_udp_dissector(struct ndpi_detection_module_struct *ndpi_struct
|
||||
NO_SAVE_DETECTION_BITMASK_AS_UNKNOWN,
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_IP_EGP
|
||||
|
||||
ndpi_set_bitmask_protocol_detection("IP_EGP", ndpi_struct, detection_bitmask, *id,
|
||||
NDPI_PROTOCOL_IP_EGP,
|
||||
ndpi_search_in_non_tcp_udp,
|
||||
@@ -157,8 +139,7 @@ void init_non_tcp_udp_dissector(struct ndpi_detection_module_struct *ndpi_struct
|
||||
NO_SAVE_DETECTION_BITMASK_AS_UNKNOWN,
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_IP_SCTP
|
||||
|
||||
ndpi_set_bitmask_protocol_detection("IP_SCTP", ndpi_struct, detection_bitmask, *id,
|
||||
NDPI_PROTOCOL_IP_SCTP,
|
||||
ndpi_search_in_non_tcp_udp,
|
||||
@@ -166,8 +147,7 @@ void init_non_tcp_udp_dissector(struct ndpi_detection_module_struct *ndpi_struct
|
||||
NO_SAVE_DETECTION_BITMASK_AS_UNKNOWN,
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_IP_OSPF
|
||||
|
||||
ndpi_set_bitmask_protocol_detection("IP_OSPF", ndpi_struct, detection_bitmask, *id,
|
||||
NDPI_PROTOCOL_IP_OSPF,
|
||||
ndpi_search_in_non_tcp_udp,
|
||||
@@ -175,8 +155,7 @@ void init_non_tcp_udp_dissector(struct ndpi_detection_module_struct *ndpi_struct
|
||||
NO_SAVE_DETECTION_BITMASK_AS_UNKNOWN,
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_IP_IP_IN_IP
|
||||
|
||||
ndpi_set_bitmask_protocol_detection("IP_IP_IN_IP", ndpi_struct, detection_bitmask, *id,
|
||||
NDPI_PROTOCOL_IP_IP_IN_IP,
|
||||
ndpi_search_in_non_tcp_udp,
|
||||
@@ -184,8 +163,7 @@ void init_non_tcp_udp_dissector(struct ndpi_detection_module_struct *ndpi_struct
|
||||
NO_SAVE_DETECTION_BITMASK_AS_UNKNOWN,
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
#endif
|
||||
#ifdef NDPI_PROTOCOL_IP_ICMPV6
|
||||
|
||||
ndpi_set_bitmask_protocol_detection("IP_ICMPV6", ndpi_struct, detection_bitmask, *id,
|
||||
NDPI_PROTOCOL_IP_ICMPV6,
|
||||
ndpi_search_in_non_tcp_udp,
|
||||
@@ -193,8 +171,4 @@ void init_non_tcp_udp_dissector(struct ndpi_detection_module_struct *ndpi_struct
|
||||
NO_SAVE_DETECTION_BITMASK_AS_UNKNOWN,
|
||||
ADD_TO_DETECTION_BITMASK);
|
||||
*id += 1;
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* ntp.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -24,8 +24,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_NTP
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_NTP
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -77,4 +75,3 @@ void init_ntp_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_int3
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* openft.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -24,8 +24,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_OPENFT
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_OPENFT
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -67,5 +65,3 @@ void init_openft_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_i
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* openvpn.c
|
||||
*
|
||||
* Copyright (C) 2011-16 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* OpenVPN TCP / UDP Detection - 128/160 hmac
|
||||
*
|
||||
@@ -23,8 +23,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_OPENVPN
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_OPENVPN
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -135,5 +133,3 @@ void init_openvpn_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -20,8 +20,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_ORACLE
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_ORACLE
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -75,5 +73,3 @@ void init_oracle_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_i
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* oscar.c
|
||||
*
|
||||
* Copyright (C) 2009-2011 by ipoque GmbH
|
||||
* Copyright (C) 2011-15 - ntop.org
|
||||
* Copyright (C) 2011-18 - ntop.org
|
||||
*
|
||||
* This file is part of nDPI, an open source deep packet inspection
|
||||
* library based on the OpenDPI and PACE technology by ipoque GmbH
|
||||
@@ -24,8 +24,6 @@
|
||||
|
||||
#include "ndpi_protocol_ids.h"
|
||||
|
||||
#ifdef NDPI_PROTOCOL_OSCAR
|
||||
|
||||
#define NDPI_CURRENT_PROTO NDPI_PROTOCOL_OSCAR
|
||||
|
||||
#include "ndpi_api.h"
|
||||
@@ -816,5 +814,3 @@ void init_oscar_dissector(struct ndpi_detection_module_struct *ndpi_struct, u_in
|
||||
|
||||
*id += 1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user