nDPI icon indicating copy to clipboard operation
nDPI copied to clipboard

on comparison with wireshark

Open rathnaTech opened this issue 10 years ago • 21 comments

screenshot from 2016-01-28 14 56 06

Hi Luca and all, In the above snap ,the wireshark shows the exact details like length,payload ,source,destination etc,.,Like that, is their any way to find payload,length in nDPI. please suggest me the possible solutions. Thank you,

rathnaTech avatar Jan 28 '16 09:01 rathnaTech

nDPi is a DPI toolkit, not a packet sniffer. Please have a look at the code of https://github.com/ntop/nDPI/blob/dev/example/ndpiReader.c for an example

lucaderi avatar Jan 28 '16 11:01 lucaderi

First of all, nDPI and Wireshark don't show the same informations to the user. Second, are u interested where you can find it inside the the code or you want just to see that information? For example: if you launch ndpiReader with the option -v 2, you can see more detailed informations about the flows (for example you can see, for every flow, the IP source and IP dest, the main protocol and subprotocol, the number of pkts for every flows and the length of these packets, and also the host name server if is present).

kYroL01 avatar Jan 28 '16 11:01 kYroL01

Thankyou Luca and kyroL01, hi kyroL01 As you said ,i used -v 2 it doesn't show the details as you mentioned. Its just show the protocols like TCP and UDP. please, put the snap as you got from your code.

Thank you

rathnaTech avatar Jan 28 '16 11:01 rathnaTech

Hi Luca, Then which library or product gives the details as i mentioned before . can you help me. Thank you,

rathnaTech avatar Jan 28 '16 11:01 rathnaTech

@rathnaTech ./ndpiReader -i wlan0 -v 2

1d

It works as I explained

kYroL01 avatar Jan 28 '16 11:01 kYroL01

Thank you so much for spending your valuable time with me kYroL01.

rathnaTech avatar Jan 28 '16 11:01 rathnaTech

No problem. But if you're interest in a packet sniffer library or a tool without a GUI , look at tcpdump & libpcap.

Greetings

kYroL01 avatar Jan 28 '16 11:01 kYroL01

Thank you once again kYroL01

rathnaTech avatar Jan 28 '16 11:01 rathnaTech

Hi kYroL01, shall i know ,how to write a json file in ndpi. Please put snap if possible. Thank you

rathnaTech avatar Jan 29 '16 05:01 rathnaTech

hi kYroL01, Are u there ?? .Please reply to me. Thank you

rathnaTech avatar Jan 29 '16 12:01 rathnaTech

You have to use the -j option. -j file.json (Specify a file to write the content of packets in .json format)

kYroL01 avatar Jan 29 '16 12:01 kYroL01

Thank you Luca, I did . Please answer my other issues as i posted with various headings. Thank you.

rathnaTech avatar Jan 29 '16 12:01 rathnaTech

hi kYroL01, you have mentioned in a previous comment that in order to see the content pf the packets i could put it in a json file using the command that you have mentioned. when i tried that command i couldn't use it. could you please specify how to use it?

mariam1411450 avatar Oct 17 '17 18:10 mariam1411450

This is the option to use: -j <file.json> | Specify a file to write the content of packets in .json format\n"

You have to compile ndpiReader with json library if you want to export statistic in a json file. After this you have to specify a .json file to pass with -j option and it be filled with stats u can see from here

kYroL01 avatar Oct 17 '17 21:10 kYroL01

kYroL01, thank you for replying, sorry another question, i <file.pcap|device> i have tried reading the packets from .pcap file, but when i tried substituting the file with the name of the device it wouldn't work. could you please demonstrate that part? i'm really sorry if i'm asking a lot it's just i have been trying to find anyone who has any sort of info about nDPI. thank you again

mariam1411450 avatar Oct 17 '17 22:10 mariam1411450

@mariam1411450 for sure you are digiting the wrong device name. ndpiReader -i wlan0 or ndpiReader -i eth0. You can see your devices name if you digit sudo ifconfig in your terminal.

kYroL01 avatar Oct 18 '17 07:10 kYroL01

@kYroL01 sorry for asking too much but I'm working on a graduation project with nDPI :D when I write these command it says ERROR: could not open pcap file or playlist wlan0: No such file or directory. The command I wrote was ndpiReader -i wlan0 enp0s3 and I tried ndpiReader -i wlan0 can you write to me the full command please ? thank you so much

mariam1411450 avatar Oct 20 '17 12:10 mariam1411450

I think you have to put sudo command sudo ndpiReader -i [device name]. You can also pass a pcap file.

kYroL01 avatar Oct 20 '17 13:10 kYroL01

@kYroL01 genuinely, thank you so much for replying, i just wanted to ask another question about the payload, how does we show the payload of packets? does this command -j <file.json> | Specify a file to write the content of packets in .json format\n" achieve this purpose?

mariam1411450 avatar Oct 21 '17 11:10 mariam1411450

@mariam1411450 If you have this doubt, please, write me a private mail to avoid to spam too muche this thread, thanks.

kYroL01 avatar Oct 21 '17 11:10 kYroL01