Luca Deri
3ecda45bc4
IP address matching update
2021-02-07 17:42:31 +01:00
Luca Deri
8297dacfe5
Added Makefile for building the development version of libndpi for OpenWRT
2021-02-07 09:29:01 +00:00
Luca Deri
be58d78417
(Temporarely) Disabled fragment manager ( #1129 )
2021-02-05 23:03:08 +01:00
Luca Deri
45e9c3c438
Partial fix for #1129
2021-02-05 22:22:33 +01:00
Alfredo Cardigliano
95a6a2072b
Code cleanup and safety checks in the fragment manager ( #1129 )
2021-02-05 17:16:11 +01:00
Luca Deri
8dd7716ae5
Implemented more efficient and memory savvy RSI
2021-02-05 12:38:41 +01:00
Luca Deri
60b58dbd67
RSI enhancements
2021-02-05 10:59:09 +01:00
Luca Deri
1eedf734be
Implemented API for computing RSI (Relative Strenght Index)
...
void ndpi_init_rsi(struct ndpi_rsi_struct *s, u_int16_t num_learning_values);
void ndpi_free_rsi(struct ndpi_rsi_struct *s);
float ndpi_rsi_add_value(struct ndpi_rsi_struct *s, const u_int32_t value);
2021-02-04 23:52:33 +01:00
Luca Deri
54636a3213
Improved (partial) TLS dissection
2021-02-04 22:06:18 +01:00
Ivan Nardi
679c317c57
Fix utests when "--disable-gcrypt" flag is used ( #1128 )
...
Fix: d6684f4b
2021-02-04 19:29:48 +01:00
Ivan Nardi
2a65321884
Fix some memory leakes in reassembler code ( #1127 )
2021-02-04 19:29:27 +01:00
Toni and Luca Deri
7255dbe4b7
Added fuzzy targets conditional in tests/do.sh.in which prevents the fuzzer from running if nDPI was configured previously --enable-fuzztargets but not for the current config (may produce invalid results). ( #1126 )
...
* fixed possible NULL pointer dereference for memcpy(), src pointer should never be NULL
Signed-off-by: Toni Uhlig <matzeton@googlemail.com >
Co-authored-by: Luca Deri <lucaderi@users.noreply.github.com >
2021-02-04 19:28:52 +01:00
Luca Deri
c68c8c79c9
Added missing check
2021-02-04 18:17:45 +01:00
Luca Deri
6c366d73e2
Fixed leak with DTLS
2021-02-03 23:36:11 +01:00
Luca Deri
6289413fea
Updated results
2021-02-03 11:58:17 +01:00
Ivan Nardi
a772e18977
Fix a warning ( #1125 )
...
Introduced in 5f7b9d802
reader_util.c: In function ‘process_ndpi_collected_info’:
reader_util.c:1148:60: warning: ‘%s’ directive output may be truncated writing up to 255 bytes into a region of size 64 [-Wformat-truncation=]
1148 | sizeof(flow->ssh_tls.client_requested_server_name), "%s",
| ^~
reader_util.c:1147:5: note: ‘snprintf’ output between 1 and 256 bytes into a destination of size 64
1147 | snprintf(flow->ssh_tls.client_requested_server_name,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1148 | sizeof(flow->ssh_tls.client_requested_server_name), "%s",
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1149 | flow->ndpi_flow->protos.tls_quic_stun.tls_quic.client_requested_server_name);
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2021-02-03 11:56:37 +01:00
Luca Deri
d6684f4b4c
Added test pcap
2021-02-03 11:56:14 +01:00
Ivan Nardi
8c0ea694f8
HTTP: fix user-agent parsing ( #1124 )
...
User-agent information is used to try to detect the user OS; since the
UA is extracted for QUIC traffic too, the "detected_os" field must be
generic and not associated to HTTP flows only.
Otherwise, you might overwrite some "tls_quic_stun" fields (SNI...) with
random data.
Strangely enough, the "detected_os" field is never used: it is never
logged, or printed, or exported...
2021-02-03 11:54:11 +01:00
Ivan Nardi
8cee718e8b
HTTP: fix logs when NDPI_ENABLE_DEBUG_MESSAGES is defined ( #1123 )
2021-02-03 11:53:41 +01:00
Luca Deri
155b1aaa68
Updated results due to the new fragment manager handler
2021-02-03 11:52:46 +01:00
Luca Deri
6e87daab69
Cosmetic fixes
2021-02-03 11:52:32 +01:00
Luca Deri
1f3ade5923
Increased number of extra packets that is necessary since the frgament mananger introduction
2021-02-03 11:51:55 +01:00
Luca Deri
4b181be58e
Improved debug message
2021-02-03 11:49:14 +01:00
Luca Deri
d19bad1581
Added pcap for testing fragments reassembly
2021-02-03 11:48:53 +01:00
Luca Deri
01f4a57118
Fixes an issue with https://github.com/ntop/nDPI/pull/1122 that misprocsssed packets belonging to flows whose initial part (e.g. the 3WH) was not observed by nDPI (e.g. capture started in the middle of the flow)
2021-02-03 11:47:21 +01:00
b70ad0e2f1
fragments management added ( #1122 )
...
Management of tcp segments managements.
Co-authored-by: ragostino <ragostino73@gmail.com >
Co-authored-by: Luca Deri <lucaderi@users.noreply.github.com >
2021-02-03 10:28:51 +01:00
ragostino
ee94534906
debug message bugfix ( #1108 )
...
you can not look for memory enlargement if you print debug message after updating the variables
2021-02-03 09:31:17 +01:00
Luca Deri
50f4049b58
Improved wireguard dissection
2021-01-29 16:38:43 +01:00
Luca Deri
bb74b903d0
DCE/RPC improvement to avoid false positives
2021-01-29 16:23:18 +01:00
Luca Deri
aeeccee106
DGA name improvement
2021-01-27 11:43:35 +01:00
Luca Deri
aa5486f5f8
Added missing library
2021-01-22 09:31:37 +01:00
Luca Deri
288ccd6215
Fixes due to datatype rename
2021-01-22 09:17:34 +01:00
Luca Deri
a31bd5ac3c
Cleaned up tls/quic datatypes
2021-01-21 19:17:33 +01:00
Luca Deri
15295ef4c5
Reworked TLS fingerprint calcolation
...
Modified TLS memory free
2021-01-21 19:06:05 +01:00
Toni
399755607d
Disable tests that require libgcrypt if --disable-gcrypt set. ( #1121 )
...
Signed-off-by: Toni Uhlig <matzeton@googlemail.com >
2021-01-21 08:59:06 +01:00
morefigs
53415c8855
Added missing comma ( #1116 )
...
I presume there is a comma missing in this comma separated list.
2021-01-21 08:58:42 +01:00
Luca Deri
3e5e9569ff
Added simple hash implementation to the nDPI API
2021-01-20 21:30:19 +01:00
Luca Deri
d964c3e081
Code cleanup: third party uthash is at the right place
2021-01-20 19:11:36 +01:00
Luca
0809956e5f
Rewored UPnP protocol that in essence was WSD hence it has been renamed
...
Cleaned up TLS code for DTLS detection by defining a new DTLS protocol
2021-01-20 09:53:30 +01:00
Luca Deri
e9f43516ec
Improves STUN dissection removing an invalid termination condition that prevented Skype calls to be properly identified
2021-01-13 16:46:51 +01:00
Luca Deri
68b6ac7da8
(C) Update
2021-01-07 11:13:36 +01:00
Luca Deri
367184628e
Warning fix
2021-01-07 11:07:17 +01:00
Darryl Sokoloski
5f7b9d8024
Increase SNI hostname buffer length to 256. ( #1111 )
...
According to RFC 4366, SNI host names can be up to 255 bytes.
Previous size of 64 resulted in failed application matches due to truncation.
For example:
0976e041e65b1aece3e720df36ac6bd7.safeframe.googlesyndication.co|m
Signed-off-by: Darryl Sokoloski <darryl@sokoloski.ca >
2021-01-07 10:58:48 +01:00
Ivan Nardi
ec2735694b
STUN: avoid false positives ( #1110 )
...
STUN traffic doesn't use multicast addresses
2021-01-07 10:58:22 +01:00
Ivan Nardi
1e2b57bed4
HTTP: fix compilation and a memory error when NDPI_ENABLE_DEBUG_MESSAGES is defined ( #1109 )
2021-01-07 10:58:02 +01:00
Ivan Nardi
2080cc7365
QUIC: add suppport for DNS-over-QUIC ( #1107 )
...
Even if it is only an early internet draft, DoQ has already (at least)
one deployed implementation.
See: https://www.zdnet.com/article/ad-blocker-adguard-deploys-worlds-first-dns-over-quic-resolver/
Draft: https://tools.ietf.org/html/draft-huitema-dprive-dnsoquic-00
In the future, if this protocol will be really used, it might be worth to
rename NDPI_PROTOCOL_DOH_DOT in NDPI_PROTOCOL_DOH_DOT_DOQ
2021-01-07 10:56:39 +01:00
Ivan Nardi
00dabce65e
Quic fixes ( #1106 )
...
* QUIC: fix heap-buffer-overflow
* TLS: fix parsing of QUIC Transport Parameters
2021-01-07 10:55:55 +01:00
Ivan Nardi
b8a5358e80
QUIC: improve handling of SNI ( #1105 )
...
* QUIC: SNI should be always saved in flow->protos.stun_ssl.ssl.client_requested_server_name
Close #1077
* QUIC: fix matching of custom categories
* QUIC: add NDPI_TLS_MISSING_SNI support for older GQUIC versions
* QUIC: fix serialization
* QUIC: add DGA check for older GQUIC versions
2021-01-07 10:55:23 +01:00
Luca Deri
eb37f8f1fb
Split HTTP request from response Content-Type. Request Content-Type should be present with POSTs and not with other methods such as GET
2021-01-06 18:28:24 +01:00
Luca Deri
cd21f0d316
Added check for invalid HTTP content
2021-01-06 12:25:32 +01:00