Skip to content

Releases: sidick/sana2loop

sana2loop v1.1

Choose a tag to compare

@github-actions github-actions released this 04 Aug 18:43

All additive and backward-compatible with v1.0 — existing configs and consumers are unaffected by default. Six milestones (M14–M19), most inspired by reviewing nullsana and comm/net/sanamon, the prior art discovered after v1.0 shipped. Full details in the Changelog.

New config keys

  • replaycap=N (M14) — per-unit override of the mode=replay record ceiling (1–256, default still 4), for captures bigger than 4 records on machines with the memory to spare.
  • wire=ethernet|slip|cslip|ppp (M15) — a unit can now pretend to be a point-to-point serial wire: 4-byte IP-style addressing, per-wire MTU/BPS defaults, no broadcast/multicast/raw. Exercise a stack's SLIP/PPP code paths with zero hardware.
  • bps=N (M15) — the link speed S2_DEVICEQUERY reports (previously hardcoded 10000000). Reported only, never a throttle.
  • mintu=N (M15) — minimum write size; shorter writes fail S2ERR_BAD_ARGUMENT. Catches stacks that forget minimum-frame padding.
  • addr=02:11:22:33:44:55 (M16) — pin a unit's factory station address from config, for reproducible fixtures and mimicking a specific real topology.
  • errors=N (M16) — 1-in-N writes fail visibly (S2ERR_TX_FAILURE + S2EVENT_TX|S2EVENT_ERROR) — the loud counterpart to the silent-loss knobs, for exercising a stack's error-handling/retry paths.
  • loss=N (M16) — 1-in-N silent packet loss, for rates finer than droppct's 1% floor (loss=1000 ≈ 0.1%).
  • delay=N/deviation=N (M17) — simulated link latency with optional symmetric jitter, in VBlank ticks; runs last in the fault-injection pipeline. CMD_FLUSH/S2_OFFLINE/last-close still deliver anything waiting immediately.

Core delivery semantics (M18)

  • Multi-open fan-out: open a unit more than once (a stack plus a passive monitor, the sanamon-style pattern) and every open with a matching typed CMD_READ now gets its own independent copy of each packet, not just whichever opened first.
  • Real S2_PacketFilter dispatch: previously accepted but never invoked; now genuinely called per candidate before the copy hook, so a caller can reject packets without paying for the copy.
  • SANA2OPF_MINE (exclusive access) is now enforced.

Companion tools become general-purpose SANA-II utilities (M19)

  • DEVICE= on all four tools (SanaInfo/SanaDump/SanaSend/SanaConform) — point them at any real SANA-II driver, not just loopback.device. SanaConform is arguably most useful probing an unknown real driver.
  • CONFIG (opt-in) — issue S2_CONFIGINTERFACE with the driver's own factory address, for drivers with no stack running to configure them.
  • ONLINE default flipped on SanaDump/SanaSend/SanaConform — forcing a unit online is now opt-in, the safer default once a tool can target a live driver a stack is managing.
  • SanaConform now probes S2_PacketFilter dispatch — whether a driver actually invokes a negotiated filter hook, not just accepts the tag.
  • SanaDump DUMP/LEN — live sanamon-style console packet view (type, length, flags, addresses, hex) alongside the existing .pcap output.

Other changes

  • Docs now credit nullsana and vlink as prior art (retracting v1.0's "no null/dummy SANA-II device has ever existed" claim) — sana2loop still differentiates on being open source, KS1.3-capable, and on pcap replay/record, fault injection, and conformance tooling.
  • On-target testing upgraded to Copperline 0.14.0; CI converted to the shared sidick/amiga-workflows toolchain.
  • Every milestone validated on-target against bundled AROS and real Kickstart 1.3 and 3.1 ROMs before merge.

What's Changed

  • chore: Configure Renovate by @renovate[bot] in #21
  • chore(deps): update actions/download-artifact action to v8 by @renovate[bot] in #22

New Contributors

Full Changelog: v1.0...v1.1

sana2loop v1.0

Choose a tag to compare

@github-actions github-actions released this 31 Jul 16:18

sana2loop builds loopback.device, a hardware-free SANA-II network
device for AmigaOS: echo, crossover, and pcap replay/capture modes,
plus companion Shell tools (SanaInfo, SanaDump, SanaSend, SanaConform).
No null/dummy SANA-II device has ever existed before this, despite
being the obvious first tool for testing any network stack, shim, or
driver-consuming software - deterministically, with zero hardware and
zero emulator network support required.

Features:

  • Echo mode: a CMD_WRITE is delivered straight back to a matching queued
    CMD_READ (typed, orphan, or a bounded rxqueue), with real SANA-II
    src/dst address semantics.
  • Crossover mode: pair two units so traffic written to one is
    delivered to the other, with real unswapped addressing and
    unicast/broadcast/multicast/promiscuous receive filtering.
  • Real SANA-II buffer-management hooks (S2_CopyToBuff/CopyFromBuff/
    PacketFilter), broadcast/multicast writes and group membership,
    S2_ONEVENT, global/type/special stats, and per-unit config files
    (ENV:/S: sana2loop/unitN.config).
  • Fault injection pipeline, all off by default: packet drop, duplicate,
    truncate, reorder, forced online/offline flapping, and an
    "oversilent" PMTUD black hole - an overlong crossover write
    vanishes silently instead of erroring, so a stack's actual PMTUD
    black-hole detection/recovery can be tested, not just assumed - all
    seeded and reproducible.
  • pcap replay (on-demand or real-time VBlank-scheduled) and pcap
    recording, both driven off a hand-rolled classic pcap reader/writer
    with no host dependency.
  • SANA-II Rev 2/3/4/7 conformance: wider buffer-management hooks
    (S2_CopyToBuff16/32, genuinely invoked, not just accepted),
    S2_GETPEERADDRESS/S2_GETDNSADDRESS, Sana2DeviceQuery.RawMTU, and Rev 7
    DMA hook negotiation (accepted and counted, gracefully never invoked).
  • Companion Shell tools: SanaInfo (open/query/online-offline a unit),
    SanaDump (capture a unit's traffic to a pcap file), SanaSend (replay a
    pcap file's frames onto a unit), SanaConform (probes a unit's SANA-II
    Rev 2/3/4/7 conformance and reports what it finds).
  • Targets plain 68000 and Kickstart 1.3 for the device itself - a test
    tool's value is universality, and nothing here needs more.

See docs/PLAN.md for the full milestone history and the full documentation site (also included as sana2loop.guide in this release's archive).