-{ pkgs, lib, config, ... }:
+{
+ pkgs,
+ lib,
+ config,
+ ...
+}:
{
imports = [
./avahi.nix
services.resolved.extraConfig = ''
MulticastDNS=false
'';
- networking.nftables.ruleset = ''
- table inet filter {
- chain output-lan {
- tcp dport { ipp, ipps } counter accept comment "printing: IPP"
- tcp dport sane-port counter accept comment "sane-net: control port"
- tcp dport {40000 - 40100} counter accept comment "saned: data ports"
+ networking.nftables.ruleset =
+ ''
+ table inet filter {
+ chain output-lan {
+ tcp dport { ipp, ipps } counter accept comment "printing: IPP"
+ tcp dport sane-port counter accept comment "sane-net: control port"
+ tcp dport {40000 - 40100} counter accept comment "saned: data ports"
+ }
}
- }
- '' + lib.optionalString config.hardware.sane.openFirewall ''
- table inet filter {
- chain input-lan {
- udp canon-bjnp2 counter accept comment "sane: discovery of scanners on the local network"
+ ''
+ + lib.optionalString config.hardware.sane.openFirewall ''
+ table inet filter {
+ chain input-lan {
+ udp canon-bjnp2 counter accept comment "sane: discovery of scanners on the local network"
+ }
}
- }
- '';
+ '';
}