Skip to content

HSRP protocol support (RFC 2281) #195

Description

@EONRaider

Target: 2.6.0 (Tier 4 — AAA & infrastructure services)

Context

HSRP is Cisco's router-redundancy protocol, UDP port 1985 — the same
role VRRP fills (Tier 2, this roadmap), and close enough in shape
that it's worth doing after VRRP ships, so both can share test-fixture
conventions.

Deliverable

Add netprotocols.HSRP (layer 7, dispatched from udp.port):

  • Decode the 20-byte HSRPv1 header (RFC 2281 §5.1 — HSRP is a Cisco
    protocol documented only informationally): Version (1 byte), Op Code
    (1 byte), State (1 byte), Hellotime (1 byte), Holdtime (1 byte),
    Priority (1 byte), Group (1 byte), Reserved (1 byte), Authentication
    Data (8 bytes, plaintext — no cryptographic meaning, decode as-is),
    Virtual IP Address (4 bytes).
  • Dispatch on Op Code: Hello (0), Coup (1), Resign (2) — all share
    the same fixed header shape, so this is a field-value distinction,
    not a structural branch like VRRP's version differences.
  • Register udp.port 1985 → HSRP, best-effort like every other
    port-table entry.

Acceptance criteria

  • HSRP decodes the fixed header for all three Op Codes;
    bytes(HSRP.decode(x)) == x.
  • UDP port 1985 dispatches to HSRP.
  • Fixture covering Hello and at least one of Coup/Resign;
    truncation.
  • CHANGELOG entry; full ladder green.

References

RFC 2281 (informational) · Router-redundancy sibling: VRRP (#172)

Part of #174

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions