nixpkgs/nixos/modules/programs/sniffnet.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

25 lines
469 B
Nix
Raw Normal View History

2023-05-09 21:48:56 +02:00
{ config, lib, pkgs, ... }:
let
cfg = config.programs.sniffnet;
in
{
options = {
programs.sniffnet = {
enable = lib.mkEnableOption (lib.mdDoc "sniffnet");
};
};
config = lib.mkIf cfg.enable {
security.wrappers.sniffnet = {
owner = "root";
group = "root";
capabilities = "cap_net_raw,cap_net_admin=eip";
source = "${pkgs.sniffnet}/bin/sniffnet";
};
};
meta.maintainers = with lib.maintainers; [ figsoda ];
}