ntop / ntopng

Web-based Traffic and Security Network Traffic Monitoring
http://www.ntop.org
GNU General Public License v3.0
6.17k stars 648 forks source link

Custom applications and adding rule from flow problem #8559

Closed xkrizp09 closed 1 month ago

xkrizp09 commented 1 month ago

Environment: OS name: Debian OS version: 12 Architecture: amd64 ntopng version/revision: ntopng Enterprise L v.6.1.240724

Hello, I noticed issues with Custom applications, Custom Categories and adding rule from Flow.

I started ntopng with –ndpi-protocols=/var/lib/ntopng/protos.txt, in protos.txt file there is

image

Then I restarted ntopng, but there are no new application in Application. When I tried edit existing application by adding new domain in GUI nothing happed even after restart.

image

So i Tried to add http from live flow and got this: (I tried to add him to different application than 1kxun):

image

After that there is this log:

15:43:51 [flow_details.lua:252] [protos_utils.lua:345] ERROR [protos.txt] Could not open '' for write

in my system ntopng has all premisson for protos.txt

MatteoBiscosi commented 1 month ago

Hi @xkrizp09 could you please share your protocols file here? do not edit manually the protocol files, add the protocols from the gui, because some info (like the identifier) are added to the protocol file. Add new protocols by clicking the + icon image and follow the rules written in the screenshot you sent

xkrizp09 commented 1 month ago

My proto.txt: ip:www.ntop.org@ntop host:"disneyplus.com",host:"cdn.registerdisney.go.com",host:"disney-portal.my.onetrust.com",host:"disneyplus.bn5x.net",host:"disney-plus.net"@DisneyPlus tcp:9002@Elasticsearch

I can not see + icon in my GUI.

MatteoBiscosi commented 1 month ago

the file should be similar to:

biscosi@develv5:~$ cat protos.txt ip:0.0.0.0:55666@matteo=1024

Like i said the issue is that it needs some ids and other things used by ntopng. Could you please send me the output of journalctl -e -u ntopng and the ntopng config file?

xkrizp09 commented 1 month ago

My original file was saved in /var/lib/ntopng/proto.txt and it didn't work, so I created new file in /etc/ntopng/custom_protocols.txt and now its working as you describe. Thank you