Repository navigation
nixos/nordvpn: make more secure and robust - #547437
Conversation
|
Could you read through the Automation/AI policy and state whether the contribution adheres to it? |
69baa5d to
070174d
Compare
9cd50f7 to
7f8316a
Compare
7f8316a to
e887ec9
Compare
e887ec9 to
8179b6e
Compare
8179b6e to
4ccb9b3
Compare
390f526 to
f98575c
Compare
|
Hello again. I could use your qa testing of the changes in this pr as well to facilitate review. Ty. |
|
Built a VM from this PR and verified the sandboxing lands and doesn't break anything:
Looks good from my side |
Is this an approval for merging? |
There was a problem hiding this comment.
We can remove line 16 now since networking.firewall.checkReversePath now defaults to loose (see #550306) . This also means that the comment below (L20) can also be removed.
There was a problem hiding this comment.
Oh, very cool. Thank you for pointing this out. I intend to include the following changes in the next pr (for meshnet):
Additionally, others may only want to update the unstable commit for nordvpn package and therefore might miss the new firewall change, making the proposed documentation changes premature.
I therefore think it more appropriate to move the proposed documentation changes to the next pr (which would include meshnet).
Edit: oops, I confused my local setup with unstable. Sounds good.
e186511 to
b004542
Compare
@romildo yes; GITHUB actions seems to not work on this PR atm. The URL to this PR responds with a 404. I don't quite understand yet why this has happened. |
b004542 to
fbb5e13
Compare
fbb5e13 to
7d39ca0
Compare
There was a problem hiding this comment.
Thanks for contributing to the documentation.
Follow the documentation style guide, especially:
- Show, don’t tell. Start with a minimal working example. Explain after the code.
- Avoid meta-commentary. Don’t write "This section explains how to…".
- Use present tense, imperative mood, and active voice. For example: "Run the command," not "The user should run the following command."
- Avoid vague references like "this" when the referent is unclear. Write "This command creates a folder," not "This will create a folder."
- Be direct. Avoid "should", "might", "typically", and "usually".
- Cut filler words like "simply", "just", "easily", and "basically". Use "to" instead of "in order to".
For larger changes, such as adding or removing whole sections, ask the NixOS documentation team for review.
7d39ca0 to
581e26f
Compare
- shrink blast radius of a compromised nordvpnd - ensure prerequisite kernel modules have loaded - fix norduserd systemd user service to restart on rebuilds - run go test recursively - update documentation; firewall.checkReversePath defaults to "loose" Assisted-by: Claude Code (Claude Sonnet 5)
581e26f to
c1fd43f
Compare
Adds meshnet (libtelio) and fileshare (libdrop) support, both fully open-source/GPLv3 and gated behind upstream's own telio/drop/cdnrc Go build tags (moose/quench stay out of scope, proprietary-only). - nordvpnd gains a --hosts-readonly flag backed by a NoopHostsSetter (daemon/dns/hosts.go), so /etc/hosts is never written to. Peer hostnames do not resolve as a result; connect by meshnet IP instead. - builds and installs cmd/fileshare as nordfileshare; its and norduserd's unix sockets are chowned to the nordvpn group so processes running as a different user than nordvpnd (which runs unprivileged) can reach them. - only start the norduserd user service for members of the configured group, since other users cannot assign their socket to that group. - adds CAP_NET_RAW (libtelio needs it for ping) and nordlynx to networking.firewall.trustedInterfaces. - sets the RemotePath ldflag to upstream's documented default (.env.sample: /apps/linux/config). Without it, remote-config downloads that gate meshnet/libtelio resolve to the wrong CDN path. - run daemon/dns tests, including the read-only hosts setter, except nameserver discovery, which needs a gateway absent from the sandbox. - expand nixosTests.nordvpn to check trusted interfaces, socket modes and groups, the expected fileshare exit code while meshnet is disabled, and skipped services for non-members across all user/group combinations. - document meshnet support and its hostname limitation in the release notes. Rebased onto master's merged nixos/nordvpn: make more secure and robust (NixOS#547437): reconciled the refactored nixosTests.nordvpn UserGroupTestCase, the broader checkPhase daemon test coverage, and the full systemd sandboxing directive set with this branch's meshnet-specific additions on top. Based on independent work by different-error, who could not push this directly due to a disputed account suspension. Credited via Co-authored-by. Co-authored-by: different-error <[email protected]> Assisted-by: Claude Code (Sonnet 5, claude-sonnet-5) Assisted-by: OpenCode (GPT-6.1 Sol, openai/gpt-6.1-sol)
Adds meshnet (libtelio) and fileshare (libdrop) support, both fully open-source/GPLv3 and gated behind upstream's own telio/drop/cdnrc Go build tags (moose/quench stay out of scope, proprietary-only). - nordvpnd gains a --hosts-readonly flag backed by a NoopHostsSetter (daemon/dns/hosts.go), so /etc/hosts is never written to. Peer hostnames can be mapped declaratively via networking.hosts instead (documented). - builds and installs cmd/fileshare as nordfileshare; its and norduserd's unix sockets are chowned to the nordvpn group so processes running as a different user than nordvpnd (which runs unprivileged) can reach them. - only start the norduserd user service for members of the configured group, since other users cannot assign their socket to that group. - adds CAP_NET_RAW (libtelio needs it for ping) and nordlynx to networking.firewall.trustedInterfaces. - sets the RemotePath ldflag to upstream's documented default (.env.sample: /apps/linux/config). Without it, remote-config downloads that gate meshnet/libtelio resolve to the wrong CDN path. - run daemon/dns tests, including the read-only hosts setter, except nameserver discovery, which needs a gateway absent from the sandbox. - expand nixosTests.nordvpn to check trusted interfaces, socket modes and groups, the expected fileshare exit code while meshnet is disabled, and skipped services for non-members across all user/group combinations. - document meshnet support and its hostname limitation in the release notes. Rebased onto master's merged nixos/nordvpn: make more secure and robust (NixOS#547437): reconciled the refactored nixosTests.nordvpn UserGroupTestCase, the broader checkPhase daemon test coverage, and the full systemd sandboxing directive set with this branch's meshnet-specific additions on top. Based on independent work by different-error, who could not push this directly due to a disputed account suspension. Credited via Co-authored-by. Co-authored-by: different-error <[email protected]> Assisted-by: Claude Code (Sonnet 5, claude-sonnet-5) Assisted-by: OpenCode (GPT-6.1 Sol, openai/gpt-6.1-sol) Assisted-by: Claude Code (Opus 5.5, claude-opus-5-5)
Adds meshnet (libtelio) and fileshare (libdrop) support, both fully open-source/GPLv3 and gated behind upstream's own telio/drop/cdnrc Go build tags (moose/quench stay out of scope, proprietary-only). - nordvpnd gains a --hosts-readonly flag backed by a NoopHostsSetter (daemon/dns/hosts.go), so /etc/hosts is never written to. Peer hostnames can be mapped declaratively via networking.hosts instead (documented). - builds and installs cmd/fileshare as nordfileshare; its and norduserd's unix sockets are chowned to the nordvpn group so processes running as a different user than nordvpnd (which runs unprivileged) can reach them. - only start the norduserd user service for members of the configured group, since other users cannot assign their socket to that group. - adds CAP_NET_RAW (libtelio needs it for ping) and nordlynx to networking.firewall.trustedInterfaces. - sets the RemotePath ldflag to upstream's documented default (.env.sample: /apps/linux/config). Without it, remote-config downloads that gate meshnet/libtelio resolve to the wrong CDN path. - run daemon/dns tests, including the read-only hosts setter, except nameserver discovery, which needs a gateway absent from the sandbox. - expand nixosTests.nordvpn to check trusted interfaces, socket modes and groups, the expected fileshare exit code while meshnet is disabled, and skipped services for non-members across all user/group combinations. - document meshnet support and its hostname limitation in the release notes. Rebased onto master's merged nixos/nordvpn: make more secure and robust (NixOS#547437): reconciled the refactored nixosTests.nordvpn UserGroupTestCase, the broader checkPhase daemon test coverage, and the full systemd sandboxing directive set with this branch's meshnet-specific additions on top. Based on independent work by different-error, who could not push this directly due to a disputed account suspension. Credited via Co-authored-by. Co-authored-by: different-error <[email protected]> Assisted-by: Claude Code (Sonnet 5, claude-sonnet-5) Assisted-by: OpenCode (GPT-6.1 Sol, openai/gpt-6.1-sol) Assisted-by: Claude Code (Opus 5.5, claude-opus-5-5)
Assisted-by: Claude Code (Sonnet 5)
(edit note: I initially patched nordvpn-linux's source directly; I decided to move that change upstream instead)
Spin up a VM for manual verification:
Note: since this package/service hasn't made it to stable yet, I've not updated the release notes.
Things done
passthru.tests.nixpkgs-reviewon this PR. See nixpkgs-review usage../result/bin/.