mirror of
https://github.com/soypat/lneto.git
synced 2026-09-10 16:49:37 +00:00
update README with pcap and fix innaccuracies
This commit is contained in:
@@ -11,7 +11,9 @@ Userspace networking primitives.
|
|||||||
|
|
||||||
## Packages
|
## Packages
|
||||||
- `lneto`: Low-level Networking Operations, or "El Neto", the networking package. Zero copy network frame marshalling and unmarshalling.
|
- `lneto`: Low-level Networking Operations, or "El Neto", the networking package. Zero copy network frame marshalling and unmarshalling.
|
||||||
- [`lneto/frames.go`](./frames.go): Ethernet, IPv4/IPv6, ARP, TCP, UDP packet marshalling/unmarshalling.
|
- [`lneto/validation.go`](./validation.go): Packet validation utilities
|
||||||
|
- [`lneto/internet`](./internet): Userspace IP/TCP networking stack. This is where the magic happens. Integrates many of the listed packages.
|
||||||
|
- [`lneto/internet/pcap`](./internal/pcap): Packet capture and field breakdown utilities. Wireshark in the making.
|
||||||
- [`lneto/http/httpraw`](./http/httpraw/): Heapless HTTP header processing and validation. Does no implement header normalization.
|
- [`lneto/http/httpraw`](./http/httpraw/): Heapless HTTP header processing and validation. Does no implement header normalization.
|
||||||
- [`lneto/tcp`](./ntp): TCP implementation and low level logic.
|
- [`lneto/tcp`](./ntp): TCP implementation and low level logic.
|
||||||
- [`lneto/dhcpv4`](./dhcpv4): DHCP version 4 protocol implementation and low level logic.
|
- [`lneto/dhcpv4`](./dhcpv4): DHCP version 4 protocol implementation and low level logic.
|
||||||
|
|||||||
@@ -52,8 +52,11 @@ func (pc *PacketBreakdown) CaptureEthernet(dst []Frame, pkt []byte, bitOffset in
|
|||||||
}
|
}
|
||||||
switch etype {
|
switch etype {
|
||||||
case ethernet.TypeARP:
|
case ethernet.TypeARP:
|
||||||
|
dst, err = pc.CaptureARP(dst, pkt, end)
|
||||||
case ethernet.TypeIPv4:
|
case ethernet.TypeIPv4:
|
||||||
dst, err = pc.CaptureIPv4(dst, pkt, end)
|
dst, err = pc.CaptureIPv4(dst, pkt, end)
|
||||||
|
default:
|
||||||
|
dst = append(dst, remainingFrameInfo(nil, FieldClassPayload, end, octet*len(pkt)))
|
||||||
}
|
}
|
||||||
return dst, err
|
return dst, err
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user