aboutsummaryrefslogtreecommitdiff
path: root/src/lib/protocols/rdp.c
diff options
context:
space:
mode:
authorLuca Deri <deri@ntop.org>2021-07-23 17:26:56 +0200
committerLuca Deri <deri@ntop.org>2021-07-23 17:27:15 +0200
commit61fc5be202f05113de07c063fa3fc9ccc47625d8 (patch)
treee7cb3b63e579a5f7c072de7c8836bd3aace04b33 /src/lib/protocols/rdp.c
parent4ffe1eb3c00d59fe746f4668ec9c6b3726848fce (diff)
Reworked flow risk implementation
Diffstat (limited to 'src/lib/protocols/rdp.c')
-rw-r--r--src/lib/protocols/rdp.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/lib/protocols/rdp.c b/src/lib/protocols/rdp.c
index 4776ab9c1..e783d7d4e 100644
--- a/src/lib/protocols/rdp.c
+++ b/src/lib/protocols/rdp.c
@@ -29,14 +29,13 @@
#include "ndpi_api.h"
-static void ndpi_int_rdp_add_connection(struct ndpi_detection_module_struct
- *ndpi_struct, struct ndpi_flow_struct *flow)
-{
+static void ndpi_int_rdp_add_connection(struct ndpi_detection_module_struct *ndpi_struct,
+ struct ndpi_flow_struct *flow) {
ndpi_set_detected_protocol(ndpi_struct, flow, NDPI_PROTOCOL_RDP, NDPI_PROTOCOL_UNKNOWN);
}
-void ndpi_search_rdp(struct ndpi_detection_module_struct *ndpi_struct, struct ndpi_flow_struct *flow)
-{
+void ndpi_search_rdp(struct ndpi_detection_module_struct *ndpi_struct,
+ struct ndpi_flow_struct *flow) {
struct ndpi_packet_struct *packet = &flow->packet;
NDPI_LOG_DBG(ndpi_struct, "search RDP\n");
@@ -49,7 +48,7 @@ void ndpi_search_rdp(struct ndpi_detection_module_struct *ndpi_struct, struct nd
&& get_u_int16_t(packet->payload, 6) == 0 && get_u_int16_t(packet->payload, 8) == 0 && get_u_int8_t(packet->payload, 10) == 0) {
NDPI_LOG_INFO(ndpi_struct, "found RDP\n");
ndpi_int_rdp_add_connection(ndpi_struct, flow);
- ndpi_set_risk(flow, NDPI_DESKTOP_OR_FILE_SHARING_SESSION); /* Remote assistance */
+ ndpi_set_risk(ndpi_struct, flow, NDPI_DESKTOP_OR_FILE_SHARING_SESSION); /* Remote assistance */
return;
}