nixos/hostapd: fix regression after refactoring to RFC42. Switching from submodule notation from ({name, ...}: {}) to (submob: {}) seems to require a different accessing scheme.

oddlama 0ac2ba76 7ce0abe7

Changed files
+3 -5
nixos
modules
services
networking
tests
+2 -5
nixos/modules/services/networking/hostapd.nix
···
};
config = let
-
bss = bssSubmod.name;
bssCfg = bssSubmod.config;
-
pairwiseCiphers =
concatStringsSep " " (unique (bssCfg.authentication.pairwiseCiphers
++ optionals bssCfg.authentication.enableRecommendedPairwiseCiphers ["CCMP" "CCMP-256" "GCMP" "GCMP-256"]));
···
} // optionalAttrs (bssCfg.bssid != null) {
bssid = bssCfg.bssid;
} // optionalAttrs (bssCfg.macAllow != [] || bssCfg.macAllowFile != null || bssCfg.authentication.saeAddToMacAllow) {
-
accept_mac_file = "/run/hostapd/${bss}.mac.allow";
+
accept_mac_file = "/run/hostapd/${bssCfg._module.args.name}.mac.allow";
} // optionalAttrs (bssCfg.macDeny != [] || bssCfg.macDenyFile != null) {
-
deny_mac_file = "/run/hostapd/${bss}.mac.deny";
+
deny_mac_file = "/run/hostapd/${bssCfg._module.args.name}.mac.deny";
} // optionalAttrs (bssCfg.authentication.mode == "none") {
wpa = mkDefault 0;
} // optionalAttrs (bssCfg.authentication.mode == "wpa3-sae") {
···
};
config.settings = let
-
radio = radioSubmod.name;
radioCfg = radioSubmod.config;
in {
driver = radioCfg.driver;
+1
nixos/tests/wpa_supplicant.nix
···
ssid = "nixos-test-mixed";
authentication = {
mode = "wpa3-sae-transition";
+
saeAddToMacAllow = true;
saePasswordsFile = pkgs.writeText "password" "reproducibility";
wpaPasswordFile = pkgs.writeText "password" "reproducibility";
};