Skip to content

PingKit 0.1.0

Choose a tag to compare

@gewill gewill released this 13 Jul 04:43
· 34 commits to main since this release

First release: IPv4 ICMP ping for Swift over unprivileged datagram sockets.

Features

  • Pinger actor with an AsyncSequence API (for try await response in pinger.responses), plus one-shot Pinger.ping(_:)
  • Configurable interval, timeout, probe count, and payload size
  • ICMP error mapping: Destination Unreachable and Time Exceeded are reported per-probe instead of being silently dropped (including a workaround for XNU byte-swapping the quoted IP header of error messages)
  • ping(8)-style statistics: transmitted/received/loss, min/avg/max/stddev RTT
  • Strict lifecycle semantics: single consumer, cancellation-aware teardown, idempotent stop()
  • Zero runtime dependencies; Swift 6 strict concurrency throughout
  • ping-cli demo executable
  • CI-verified on macOS and Linux (real loopback pings on both)

Platforms

macOS 13+ / iOS 16+; Linux best-effort (requires net.ipv4.ping_group_range).

🤖 Generated with Claude Code