Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nullidentdmod: Init at 1.3 #46040

Merged
merged 1 commit into from Sep 5, 2018
Merged

nullidentdmod: Init at 1.3 #46040

merged 1 commit into from Sep 5, 2018

Conversation

dasJ
Copy link
Member

@dasJ dasJ commented Sep 4, 2018

Motivation for this change

I'd like to send fake idents from my system to prevent attackers from spying on my local users.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Fits CONTRIBUTING.md.

@xeji
Copy link
Contributor

xeji commented Sep 4, 2018

@GrahamcOfBorg build nullidentdmod

@GrahamcOfBorg
Copy link

Success on aarch64-linux (full log)

Attempted: nullidentdmod

Partial log (click to expand)

gcc -o nullidentdmod nullidentdmod.o -D_POSIX_SOURCE -std=c99 -Wall -Os
installing
post-installation fixup
shrinking RPATHs of ELF executables and libraries in /nix/store/6mnlbmq5jda5ry6ri76ls7vc6xya0avy-nullidentdmod-1.3
shrinking /nix/store/6mnlbmq5jda5ry6ri76ls7vc6xya0avy-nullidentdmod-1.3/bin/nullidentdmod
strip is /nix/store/y4ymnvgxygpq05h03kyzbj572zmh6zla-binutils-2.30/bin/strip
stripping (with command strip and flags -S) in /nix/store/6mnlbmq5jda5ry6ri76ls7vc6xya0avy-nullidentdmod-1.3/bin
patching script interpreter paths in /nix/store/6mnlbmq5jda5ry6ri76ls7vc6xya0avy-nullidentdmod-1.3
checking for references to /build in /nix/store/6mnlbmq5jda5ry6ri76ls7vc6xya0avy-nullidentdmod-1.3...
/nix/store/6mnlbmq5jda5ry6ri76ls7vc6xya0avy-nullidentdmod-1.3

@GrahamcOfBorg
Copy link

No attempt on x86_64-darwin (full log)

The following builds were skipped because they don't evaluate on x86_64-darwin: nullidentdmod

Partial log (click to expand)


a) For `nixos-rebuild` you can set
  { nixpkgs.config.allowUnsupportedSystem = true; }
in configuration.nix to override this.

b) For `nix-env`, `nix-build`, `nix-shell` or any other Nix command you can add
  { allowUnsupportedSystem = true; }
to ~/.config/nixpkgs/config.nix.


@GrahamcOfBorg
Copy link

Success on x86_64-linux (full log)

Attempted: nullidentdmod

Partial log (click to expand)

gcc -o nullidentdmod nullidentdmod.o -D_POSIX_SOURCE -std=c99 -Wall -Os
installing
post-installation fixup
shrinking RPATHs of ELF executables and libraries in /nix/store/jxq3mxsblixhh2jxia4y87cg6j10kdrw-nullidentdmod-1.3
shrinking /nix/store/jxq3mxsblixhh2jxia4y87cg6j10kdrw-nullidentdmod-1.3/bin/nullidentdmod
strip is /nix/store/h0lbngpv6ln56hjj59i6l77vxq25flbz-binutils-2.30/bin/strip
stripping (with command strip and flags -S) in /nix/store/jxq3mxsblixhh2jxia4y87cg6j10kdrw-nullidentdmod-1.3/bin
patching script interpreter paths in /nix/store/jxq3mxsblixhh2jxia4y87cg6j10kdrw-nullidentdmod-1.3
checking for references to /build in /nix/store/jxq3mxsblixhh2jxia4y87cg6j10kdrw-nullidentdmod-1.3...
/nix/store/jxq3mxsblixhh2jxia4y87cg6j10kdrw-nullidentdmod-1.3

@xeji
Copy link
Contributor

xeji commented Sep 4, 2018

out of curiosity: I'm not clear about the use case. Why bother running a fake identd on your system when you could just disable it?

@dasJ
Copy link
Member Author

dasJ commented Sep 5, 2018

On most IRC networks, when the server fails to get an Ident response it falls back to the username given by client, but marks it as "not verified", usually by prefixing with a tilde; e.g. ~josh. Some IRC servers even go as far as blocking clients without an ident response,[2] the main reason being that it makes it much harder to connect via an "open proxy" or a system where you have compromised a single account of some form but do not have root (on Unix-like systems, only root can listen for network connections on ports below 1024).
-- Wikipedia

@xeji
Copy link
Contributor

xeji commented Sep 5, 2018

Thanks.

@xeji xeji merged commit a885e88 into NixOS:master Sep 5, 2018
@dasJ dasJ deleted the nullidentdmod branch September 5, 2018 10:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants