Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??

Without and example of the " format to be inserted into a database for analysis", I don't know what you're trying to output.

The NetPacket::* modules seem old by copyright date. You may want to have a look at the Net::Frame modules. They provide packet encode/decode at various OSI layers and specifically, you'll want to look at Net::Frame::Dump and it's sub-modules. The example provided with the distribution (dump-offline.pl) may be what you're looking for:

VinsWorldcom@C:\Users\VinsWorldcom\tmp> dump-offline.pl test.pcap o Frame number: 0 (length: 42) ETH: dst:ff:ff:ff:ff:ff:ff src:cc:18:ff:77:88:99 type:0x0806 ARP: hType:0x0001 pType:0x0800 hSize:0x06 pSize:0x04 opCode:0x0001 ARP: src:c4:17:fe:12:7d:75 srcIp:192.168.10.100 ARP: dst:00:00:00:00:00:00 dstIp:192.168.10.20 o Frame number: 1 (length: 59) ETH: dst:68:69:70:71:77:90 src:cc:18:ff:77:88:99 type:0x0800 IPv4: version:4 hlen:5 tos:0x00 length:45 id:8608 IPv4: flags:0x02 offset:0 ttl:128 protocol:0x06 checksum:0x9072 IPv4: src:192.168.10.100 dst:64.5.62.248 TCP: src:54237 dst:1863 seq:0x322c9b85 ack:0x119cfd35 TCP: off:0x05 x2:0x0 flags:0x18 win:16677 checksum:0xcce5 urp:0x0 +0 TCP: payload:504d570d0a ...

In reply to Re: decoding libpcap on windows by VinsWorldcom
in thread decoding libpcap on windows by jwillis

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others meditating upon the Monastery: (4)
As of 2024-04-25 15:40 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found