kaitoy / pcap4j

A Java library for capturing, crafting, and sending packets.

Home Page:https://www.pcap4j.org/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Data Hex Stream

Voltz45 opened this issue · comments

is it possible for me to parse packet and take Hex stream data only on TCP Header?

TcpPacket tcpPacket = pcap4jPacket.get(TcpPacket.class));

if (tcpPacket != null) {
    TcpHeader pcap4jTCPHeader = tcpPacket.getHeader();
    // Do stuff here
}

Hope this helps.