필터 지우기
필터 지우기

How Can I plot this Matrix with data network traffic using TCPdump?

조회 수: 1 (최근 30일)
Hello from México
I´m capturing a data network traffic with TCPdump, I want to capture only the time and the MAC addresses of the packets. I can do that and, I can plot the Total MAC addresses (packets) per second with a "for cicle" , But I need to plot each MAC address in only graph.
I have this Matrix after read de data, I have two MAC addresses and I can plot the total MAC addresses per second, and I have this graph, but I want to plot the total mac addresses per second of this addresses 001495702619 and 1C659D0C29B9, bone have two graphics with each MAC address.
I include the Matrix and the graph.
How Could I do that?
'01.52' '1C659D0C29B9'
'01.52' '001495702619'
'01.52' '001495702619'
'01.52' '1C659D0C29B9'
'01.52' '001495702619'
'01.52' '001495702619'
'01.52' '001495702619'
'01.52' '1C659D0C29B9'
'01.52' '001495702619'
'01.52' '1C659D0C29B9'
'01.52' '001495702619'
'01.52' '1C659D0C29B9'
'01.52' '001495702619'
'01.53' '1C659D0C29B9'
'01.53' '1C659D0C29B9'
'01.53' '001495702619'
'01.54' '001495702619'
'01.54' '001495702619'
'01.54' '001495702619'
'01.54' '1C659D0C29B9'
'01.54' '001495702619'
'01.54' '001495702619'
'01.54' '1C659D0C29B9'
'01.55' '001495702619'
'01.55' '1C659D0C29B9'
Thanks.
Victor

채택된 답변

Walter Roberson
Walter Roberson 2011년 9월 14일
[u,a,b] = unique(YourData(:,2));
packets1 = YourData(b==1,1);
packets2 = Yourdata(b==2,1);
then you can apply your per-second counting code to packets1 and packets2; you could plot the results both on a single graph or each on their own graph according to your preferences.
  댓글 수: 1
Victor Haro
Victor Haro 2011년 9월 14일
Thanks So much Roberson, Your answer is usefull to me
Grettins from Mexico
Gracias!!

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Introduction to Installation and Licensing에 대해 자세히 알아보기

제품

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by