Domain Classification Improvements (#2396)

* Added
size_t ndpi_compress_str(const char * in, size_t len, char * out, size_t bufsize);
size_t ndpi_decompress_str(const char * in, size_t len, char * out, size_t bufsize);

used to compress short strings such as domain names. This code is based on
https://github.com/Ed-von-Schleck/shoco

* Major code rewrite for ndpi_hash and ndpi_domain_classify

* Improvements to make sure custom categories are loaded and enabled

* Fixed string encoding

* Extended SalesForce/Cloudflare domains list
This commit is contained in:
Luca Deri
2024-04-18 23:21:40 +02:00
committed by GitHub
parent 108b8331d5
commit ad117bfaab
65 changed files with 1194 additions and 612 deletions
+1 -1
View File
@@ -30,4 +30,4 @@ JA3 Host Stats:
1 62.43.36.99 1
1 TCP 62.43.36.99:37682 <-> 21.65.95.132:465 [proto: 29/SMTPS][IP: 0/Unknown][Encrypted][Confidence: DPI][DPI packets: 4][cat: Email/3][2 pkts/637 bytes <-> 2 pkts/299 bytes][Goodput ratio: 81/60][0.47 sec][Risk: ** TLS (probably) Not Carrying HTTPS **** Missing SNI TLS Extn **][Risk Score: 60][Risk Info: No ALPN][TLSv1.2][JA3C: f17ca639ecdcaa65b4521c49e3515ef9][JA4: t12d860600_e18388e7f3a3_4446390ac224][Firefox][PLAIN TEXT (4223.hostgator.com ESMTP Exim 4)][Plen Bins: 0,0,0,0,0,50,0,0,0,0,0,0,0,0,0,0,50,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]
1 TCP 62.43.36.99:37682 <-> 21.65.95.132:465 [proto: 29/SMTPS][IP: 0/Unknown][Encrypted][Confidence: DPI][DPI packets: 4][cat: Email/3][2 pkts/637 bytes <-> 2 pkts/299 bytes][Goodput ratio: 81/60][0.47 sec][Risk: ** TLS (probably) Not Carrying HTTPS **** Missing SNI TLS Extn **][Risk Score: 60][Risk Info: No ALPN / SNI should always be present][TLSv1.2][JA3C: f17ca639ecdcaa65b4521c49e3515ef9][JA4: t12d860600_e18388e7f3a3_4446390ac224][Firefox][PLAIN TEXT (4223.hostgator.com ESMTP Exim 4)][Plen Bins: 0,0,0,0,0,50,0,0,0,0,0,0,0,0,0,0,50,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]