docs/protocol.md
{: .fs-9 }
Wire-format reference for the Network-infrastructure Hiding Protocol as implemented by OpenNHP. If you are building a new client, porting NHP to another language, or writing tooling that needs to decode NHP packets, this is the authoritative starting point. {: .fs-6 .fw-300 }
Implements the CSA "Stealth Mode SDP for Zero Trust Network Infrastructure" whitepaper — §NHP Message Header, §NHP Message Types, and Appendix 2.
| CSA spec section | OpenNHP code |
|---|---|
| NHP Message Header (Table 3) | nhp/core/scheme/curve/header.go, nhp/core/scheme/gmsm/header.go, nhp/core/packet.go |
| NHP Message Types (Table 4, Appendix 2) | nhp/common/nhpmsg.go |
| Cryptographic Algorithms and Frameworks | nhp/core/crypto.go, nhp/core/device.go |
| NHP Workflow (Figure 3) | endpoints/agent/, endpoints/server/, endpoints/ac/ |
| Integration with SDP | See [Deploy]({{ '/deploy/' |
| Logging | nhp/log/ |
OpenNHP follows the CSA NHP whitepaper published by the CSA Zero Trust Working Group. The whitepaper cites OpenNHP v0.6.0 as the reference implementation. When the spec and code disagree, the code wins in this repository and we raise the discrepancy with the Working Group.
The Protocol Reference covers the wire format:
It does not cover:
This section uses the canonical terms defined in the [Glossary]({{ '/glossary/' | relative_url }}). The spec occasionally uses SDP-flavored synonyms (e.g., "gateway" for NHP-AC); we stick to the NHP names here to match the Go code.