• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

cameri / nostream / 41349169575
78%

Build:
DEFAULT BRANCH: main
Ran 01 Nov 2026 08:57PM UTC
Jobs 2
Files 321
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

01 Nov 2026 08:53PM UTC coverage: 77.582% (+0.09%) from 77.493%
41349169575

push

github

web-flow
feat(peering): authenticate peer relays with NIP-42  (#1030)

<!--- Provide a general summary of your changes in the Title above -->

## Description
<!--- Describe your changes in detail -->
This PR :- 
- Adds \`peering.peers[]\` (pubkey and relayUrl) as the
operator-configured trust list. Peers are identified by relay pubkey,
never by URL alone.
- Adds outbound NIP-42 AUTH signed with the relay's own keypair:
connect, wait for the challenge, send kind 22242, require \`OK true\`.
- Inbound: only a verified AUTH from an enabled configured pubkey marks
the connection as a peer. Unconfigured valid keys stay ordinary clients.
- Attaches the peer pubkey to connection state via
\`getPeerPubkey()\`/\`setPeerPubkey()\`; it expires with the NIP-42
session and clears on socket close.
- Documents relay key storage and the AUTH exchange in
\`docs/PEERING.md\`, plus the new settings in \`CONFIGURATION.md\`.

## Security
- Identity is proven only by signature verification; a URL or
self-declared key never grants peer status.
- Disabled/unconfigured peers get no recognition.
- Peer state is session-scoped, so an expired AUTH cannot retain peer
treatment.


## Related Issue
<!--- This project only accepts pull requests related to open issues -->
<!--- If suggesting a new feature or change, please discuss it in an
issue first -->
<!--- If fixing a bug, there should be an issue describing it with steps
to reproduce -->
<!--- Please link to the issue here: -->
Closes :- #933

## Motivation and Context
<!--- Why is this change required? What problem does it solve? -->

## How Has This Been Tested?
<!--- Please describe in detail how you tested your changes. -->
<!--- Include details of your testing environment, and the tests you ran
to -->
<!--- see how your change affects other areas of the code, etc. -->

## Screenshots (if appropriate):

## Types of changes
<!--- What types of changes does your code introduce? Put an `x` in all
the boxes that apply: -->
- [ ] Non-func... (continued)

4501 of 6342 branches covered (70.97%)

Branch coverage included in aggregate %.

114 of 129 new or added lines in 4 files covered. (88.37%)

9792 of 12081 relevant lines covered (81.05%)

760.82 hits per line

Uncovered Changes

Lines Coverage ∆ File
10
82.68
src/utils/peering-auth.ts
5
87.31
-0.13% src/utils/settings-config.ts
Jobs
ID Job ID Ran Files Coverage
1 Integration - 41349169575.1 01 Nov 2026 08:56PM UTC 321
32.98
GitHub Action Run
2 Unit - 41349169575.2 01 Nov 2026 08:59PM UTC 321
75.03
GitHub Action Run
Source Files on build 41349169575
  • Tree
  • List 321
  • Changed 3
  • Source Changed 3
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Github Actions Build #41349169575
  • 18125d4d on github
  • Prev Build on main (#41336938316)
  • Next Build on main (#41438344400)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc