24 Commits

Author SHA1 Message Date
Pat Whittingslow 1a474154cb more httpraw bug fixes (#160)
* more httpraw bug fixes

* add http-linux example and add httpraw.Header.SetInt

* finish http-linux example

* fix CI vet
2026-07-19 11:09:09 -03:00
Pat Whittingslow 157a8537a2 testing.B.Loop() standardization and StackAsync.Debug improvement (#156)
* testing.B.Loop() standardization and StackAsync.Debug heap debugging improvement

* apply @MDr164 fixes

* @MDr164 great suggestions to prevent panic and print correct mallocs
2026-07-17 11:59:27 -03:00
Pat Whittingslow 766e03e90e httpraw: fix overrwrite/empty val bugs in Header.Set/SetBytes (#159) 2026-07-17 11:07:59 -03:00
Marvin Drees 46d4c06b9f fix: clean up misc TODO comments and improve UDP source filtering (#89)
- http/httpraw: cap header slice growth to pre-allocated capacity, fix
  benchmark to reuse Header across iterations (0 allocs/op)
- internal/ring: replace TODO panic comments with invariant explanations
- tcp/conn: document truncated-frame offset check
- tcp/handler: replace TODO with net.ErrClosed on RST-closed connection
- internet/stack-udpport: filter incoming packets by remote IP address
  when configured via SetStackNode; skip filter for IPv4 multicast
  destinations (class D) so mDNS and similar protocols work correctly

Generated with LLM assistance.

Signed-off-by: Marvin Drees <marvin.drees@9elements.com>
2026-05-20 14:29:09 -03:00
Marvin Drees f87761f777 chore: bump minimum Go version to 1.24 (#85)
Signed-off-by: Marvin Drees <marvin.drees@9elements.com>
2026-04-16 17:21:23 -03:00
Pat Whittingslow bd645b5e1e Add mdns package and Client implementation (#55)
* add mdns

* define mdns.Client

* fix some mdns stuff

* refine dns package for use with mdns

* remove Querier and Responder and replace with Client

* add record setting methods on dns.record to reuse record buffer

* protect against unbounded client answer growth

* round off sharp mdns edges; reduce allocs

* add mutlicast to stacks; add xnet tests for mdns

* fix documentation on acceptmulticast field

* mdns working
2026-03-16 15:48:17 -03:00
Pat Whittingslow de2e756628 HTTP bugfixes and tests + LLM Policy (#54)
* claude: add http tests+bugfix for parsing first line; incomplete line handling; detect Connection:close

* add more http tests
2026-03-14 20:10:08 -03:00
Patricio Whittingslow f6e7801d8c heap: remove heap alloc in pcap of HTTP content type; more debugging logs 2026-02-28 17:46:08 -03:00
Pat Whittingslow 989bb6a0b9 Reduce heap allocs 2 (#46)
* reduce heap allocations in tcp logging; omit use of AppendFloat which allocates a metric sh*tton

* debugheaplog: better heap statistic logging

* heap: use string for pcap.Frame.Protocol

* add potential to eliminate Flags.String heap alloc, remove incorrect HEAP comments

* add StackAsync.DebugErr and httpraw.SetBytes

* many heap alloc reductions and replacement of bytes.Equal with internal.BytesEqual
2026-02-28 15:20:46 -03:00
Pat Whittingslow 151133dfb4 HTTP and Listener improvements and bugfixes (#17)
* listener revamp

* improvements to conn lifetimes
2026-01-11 10:29:16 -03:00
Patricio Whittingslow 5731a378dd skip infinite loop in http parsing 2026-01-01 12:21:58 -03:00
soypat 9bd906326e solve #4 by adding features and use cases to README 2025-07-19 17:52:42 -03:00
soypat 6884d5e859 add HTTP normalize tests and fix bugs triggered by tests 2025-06-28 13:10:36 -03:00
soypat 26b3adc777 work on httpraw normalization and dns/dhcp bridge example 2025-06-28 12:39:38 -03:00
soypat 23212d8dc6 CopyFrom pattern for DNS and use it for Cookie 2025-06-25 09:32:35 -03:00
soypat 7c5b427b14 refactor http packet capture 2025-06-03 23:48:51 -03:00
soypat 2d71907241 fix TCP flags not being extracted from capture correctly 2025-06-03 00:45:11 -03:00
soypat a29bad9ac9 begin working on making response quicker (why is tap interface so slow?) 2025-06-01 01:29:07 -03:00
soypat 6cd786a199 better httpraw documentation 2025-05-31 14:28:40 -03:00
soypat 1ae8fab210 receive HTTP request success; still working on response 2025-05-31 14:08:32 -03:00
soypat 20946c7e22 fix TCP checksum in internet.StackBasic; more logging 2025-05-27 23:37:21 -03:00
soypat 969243d480 return error when no cookies found 2025-05-25 17:10:49 -03:00
soypat c3f0c218f7 add httpraw to readme 2025-05-25 17:01:31 -03:00
soypat ca7bf2f366 httpraw looking good 2025-05-25 16:58:52 -03:00