Add `nx sign` and `nx verify` for module releases
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 5/5
- Estimated time
- Over a week
- Newbie friendliness
- 35/100
Research direction
Read the related issues NexyPy/nexy#686 and #687 and the registry data contract in NexyPy/nx-registry#1 first; this issue defines signing and verification only. Identify the existing nx/nexy CLI entry points and release archive checksum flow. Done means signing and nx verify meet the listed acceptance criteria, including tampering, namespace ownership, key handling, and unsigned releases, with tests and a documentation page.
Written by the indexing model from the issue text.
Description
Problem
A checksum proves that a downloaded archive was not corrupted in transit, but it does not prove who published it. A Nexy module can edit nexyconfig.py, install packages and run migrations, so a developer needs a way to verify the identity of a release before nx add writes anything.
Proposed solution
Add nx sign (also available as nexy sign) that signs a module release before publishing:
- Sign the archive checksum, not the whole registry record, so the signature stays valid across metadata edits.
- Support a local key stored outside the project and a keyless CI signature. The choice and the key format must be documented before implementation.
- Embed the signer identity, the module name, the version and the checksum in the signature file.
- Let
nx publishcarry the signature with the release; letnx addverify it before writing files. - Add
nx verify <name>@<version>to check a release without installing it. - Refuse to verify when the signer does not match the namespace owner recorded by the registry.
- Keep private keys out of the archive, the repository and terminal output.
Acceptance criteria:
- A signed release verifies with
nx verifyand installs withnx add. - A changed archive fails verification before any file is written.
- A signature from a signer who does not own the namespace is refused.
- An unsigned release is clearly labelled as unsigned, and the project trust setting decides whether it may install.
- Tests cover signing, verification, tampering, namespace mismatch, key handling and unsigned releases.
- A docs page explains key storage, CI signing, verification and what the signature does not guarantee.
Alternative solutions
Publish checksums only and ask developers to compare them by hand. That detects corruption but not a replacement of both archive and checksum by the same attacker.
Additional context
This issue depends on NexyPy/nx-registry#1 for the registry data contract. nx publish in NexyPy/nexy#687 carries the signature and nx add in NexyPy/nexy#686 verifies it. This issue covers signing and verification only, not dependency installation or registry hosting.
Validation
- I have searched existing issues and this is not a duplicate.
- I would be willing to help implement this feature.
- Dominant language
- Python
- Stars
- 11
- Forks
- 6
- Avg merge
- 2h 14m
- Merged PRs (30d)
- 265
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from NexyPy/nexy
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
area:cli difficulty:intermediate enhancement
Difficulty 2/5 Half a day Newbie friendliness 85/100
Maintainers usually reply within 1 day
-
area:cli area:docs question
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
area:docs difficulty:beginner good first issue priority:3
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Maintainers usually reply within 1 day
-
area:docs difficulty:beginner good first issue priority:3
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
Similar issues
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
jxxghp/MoviePilot#7699 ·
Maintainers usually reply within 1 day
-
bug TAG: unit tests
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
learningequality/ricecooker#898 ·
-
next
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
j3ko/agent-plugins#80 ·
Maintainers usually reply within 1 day
-
bug:unconfirmed
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
Heroic-Games-Launcher/HeroicGamesLauncher#6187 ·
Maintainers usually reply within 1 day
-
Difficulty 1/5 1-3 hours Newbie friendliness 82/100
BCStudentSoftwareDevTeam/cas#491 ·
Maintainers usually reply within 8 days