mirror of
https://github.com/soypat/lneto.git
synced 2026-09-10 08:39:30 +00:00
HTTP server example and DHCP Server rewrite (#38)
* improvements to dhcpv4 server * begin adding examples/httpserver * add better VLAN tagging methods * pcap: add error printing; fix bug in CRC * ipv4: ToS and Flags construction and flag manipulation improvements * add dhcp interception to httptap and improve httpserver example
This commit is contained in:
+5
-1
@@ -2,6 +2,7 @@ package dhcpv4
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"net/netip"
|
||||
"testing"
|
||||
)
|
||||
|
||||
@@ -25,7 +26,10 @@ func TestClientServer(t *testing.T) {
|
||||
t.Errorf("want client state %s, got %s", state.String(), cl.State().String())
|
||||
}
|
||||
}
|
||||
sv.Reset(svAddr, DefaultServerPort)
|
||||
sv.Configure(ServerConfig{
|
||||
ServerAddr: svAddr,
|
||||
Subnet: netip.PrefixFrom(netip.AddrFrom4(svAddr), 24),
|
||||
})
|
||||
// CLIENT DISCOVER.
|
||||
assertClState(StateInit)
|
||||
var buf [1024]byte
|
||||
|
||||
Reference in New Issue
Block a user