demo

command
v0.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 27, 2026 License: Apache-2.0 Imports: 6 Imported by: 0

README

Demo guest

This guest is packaged as share/debuglet/demo.wasm and run by dbl demo. It takes exactly two arguments, [targetAddr, nonce], directly as WASI os.Args without a program-name element. The nonce is 16 random bytes encoded as 32 lowercase hexadecimal characters.

The guest connects through pkg/debuglet to the demo's loopback TCP target. It accumulates fragmented reads with a 4096-byte buffer and a 128-byte line limit, requires exactly DEBUGLET/1 <nonce>\n, and writes ACK <nonce>\n. After the target closes normally with no trailing data, it prints DEBUGLET_DEMO_OK <nonce>\n. A wrong reply, premature EOF, or socket failure exits unsuccessfully without that marker.

The package build compiles this source with Go 1.25.11, CGO_ENABLED=0 GOOS=wasip1 GOARCH=wasm, -mod=readonly, and -trimpath. The complete installed demo needs no compiler or checkout.

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL