hermes-agent/plugins/platforms
Shannon Sands e24bb0b42f fix(line): dual-stack webhook bind — 0.0.0.0 default unreachable over IPv6-only networks
The LINE adapter's webhook server defaulted to host="0.0.0.0", which
binds IPv4 ONLY. On IPv6-only private networks — notably Fly.io 6PN,
where the hosted edge router reverse-proxies LINE ingest to
<app>.internal:8646 over an fdaa: IPv6 address — nothing is listening
on the dialed address: connection refused → customer-visible 502 when
LINE's console verifies the webhook (NS-603).

This is the same bug the generic webhook adapter fixed in d542894ad;
the LINE adapter was never updated to match. Fix mirrors that commit:

- DEFAULT_HOST = None → asyncio/aiohttp create_server binds one socket
  per address family (v4 + v6), regardless of the bindv6only sysctl.
  "::" is NOT a valid substitute — Fly machines set bindv6only=1, so
  it would yield an IPv6-only socket and break IPv4 loopback probes.
- Empty-string host collapses to None; LINE_HOST/extra.host still pin
  a specific bind address.
- reuse_address=False scoped to macOS only (BSD wildcard-socket
  traffic-splitting footgun), mirroring 9420ad946.
- The three outbound-media guards compared webhook_host == "0.0.0.0"
  by string equality; extracted to _missing_public_url() which treats
  None/0.0.0.0/::/"" as "no fetchable hostname" so the LINE_PUBLIC_URL
  requirement still fires under the new default. _media_url() falls
  back to 127.0.0.1 instead of interpolating 'None' into URLs.

Tests: dual-stack default decision table (default None, empty→None,
pinned preserved, LINE_HOST override), behavioural both-families bind
proof via runner.addresses, and the media public-URL guard matrix.
88 passed, ruff clean.

Companion router fix (hermes-agent-router) routes /webhooks/line and
/line/webhook|/line/media to :8646 over 6PN; both are needed for
end-to-end hosted LINE delivery.

Fixes NS-603
2026-07-28 22:42:41 -07:00
..
buzz feat(buzz): WebSocket inbound transport — NIP-42 auth, live DM discovery, poll fallback 2026-07-28 21:45:34 -07:00
dingtalk fix(dingtalk): don't let richText re-derivation clobber VOICE classification 2026-07-28 14:06:56 -07:00
discord refactor(discord): delegate ffmpeg discovery to shared tools.transcription_tools helper 2026-07-28 11:56:37 -07:00
email fix(email): harden adapter against malformed IMAP responses 2026-07-02 03:12:53 -07:00
feishu fix(feishu): classify native voice messages as VOICE for auto-transcription 2026-07-28 14:06:56 -07:00
google_chat fix(gateway): extend the utf-8 file-I/O guard to google_chat + whatsapp 2026-07-24 15:47:12 -07:00
homeassistant fix(gateway): validate multiplex adapter config by platform 2026-07-16 05:39:58 -07:00
irc fix(telegram): preserve Bot API update queue on watcher reconnect 2026-06-25 21:29:57 -07:00
line fix(line): dual-stack webhook bind — 0.0.0.0 default unreachable over IPv6-only networks 2026-07-28 22:42:41 -07:00
matrix fix(tts): improve Opus encoding quality for voice messages 2026-07-28 11:55:48 -07:00
mattermost fix(platforms): clear home channel when setup prompt left blank 2026-07-23 12:01:24 -07:00
ntfy fix(telegram): preserve Bot API update queue on watcher reconnect 2026-06-25 21:29:57 -07:00
photon refactor(photon): resolve sidecar dir lazily, not at import time 2026-07-28 22:41:32 -07:00
raft fix(security): widen non-ASCII compare_digest crash fix to all sibling sites 2026-07-16 07:22:24 -07:00
simplex fix(telegram): preserve Bot API update queue on watcher reconnect 2026-06-25 21:29:57 -07:00
slack fix(slack): prefer live send adapter and try multi-workspace tokens individually 2026-07-23 12:01:24 -07:00
sms fix(security): widen non-ASCII compare_digest crash fix to all sibling sites 2026-07-16 07:22:24 -07:00
teams fix(security): pin DNS resolutions for SSRF-safe fetches 2026-07-23 11:44:43 -07:00
telegram fix(telegram): render markdown in voice-message captions 2026-07-28 11:55:48 -07:00
wecom fix(platforms): clear home channel when setup prompt left blank 2026-07-23 12:01:24 -07:00
whatsapp fix(whatsapp): preserve voice notes when STT fails 2026-07-28 14:06:56 -07:00