Skip to content

Latest commit

 

History

History
42 lines (31 loc) · 1.32 KB

File metadata and controls

42 lines (31 loc) · 1.32 KB

handshake

ci codecov License: AGPL-3.0

Handshake plugin for the Pilot Protocol daemon. Manages node-to-node trust:

  • listens on port 444 for incoming handshake offers
  • emits handshake.requested events to the daemon
  • persists accepted trust records to trust.json
  • consults the trustedagents allowlist for auto-accept of public peers
  • handles both direct and relayed handshakes (NAT-traversal cases)

Install

import "github.com/pilot-protocol/handshake"

Usage

s := handshake.NewService(handshake.Config{
    TrustPath:         "~/.pilot/trust.json",
    AutoApprovePublic: true,
})
rt.Register(s)

Layout

File What it does
handshake.go Wire format and Manager (in-memory trust + pending state).
runtime.go Daemon-facing interface for trust lookup and auto-approve flag.
service.go *Servicecoreapi.Service adapter.

License

AGPL-3.0-or-later. See LICENSE.