linux: patch request-key binary path

This is necessary for id mapping to work with NFS + Kerberos, and also
touches #68106 and 634638.

+32
+5
pkgs/os-specific/linux/kernel/patches.nix
··· 6 6 patch = ./bridge-stp-helper.patch; 7 7 }; 8 8 9 + request_key_helper = 10 + { name = "request-key-helper"; 11 + patch = ./request-key-helper.patch; 12 + }; 13 + 9 14 p9_fixes = 10 15 { name = "p9-fixes"; 11 16 patch = ./p9-fixes.patch;
+13
pkgs/os-specific/linux/kernel/request-key-helper.patch
··· 1 + diff --git a/security/keys/request_key.c b/security/keys/request_key.c 2 + index 957b9e3e1492..5436a0d8b81d 100644 3 + --- a/security/keys/request_key.c 4 + +++ b/security/keys/request_key.c 5 + @@ -114,7 +114,7 @@ static int call_usermodehelper_keys(const char *path, char **argv, char **envp, 6 + */ 7 + static int call_sbin_request_key(struct key *authkey, void *aux) 8 + { 9 + - static char const request_key[] = "/sbin/request-key"; 10 + + static char const request_key[] = "/run/current-system/sw/bin/request-key"; 11 + struct request_key_auth *rka = get_request_key_auth(authkey); 12 + const struct cred *cred = current_cred(); 13 + key_serial_t prkey, sskey;
+14
pkgs/top-level/all-packages.nix
··· 16145 16145 linux_mptcp_94 = callPackage ../os-specific/linux/kernel/linux-mptcp-94.nix { 16146 16146 kernelPatches = 16147 16147 [ kernelPatches.bridge_stp_helper 16148 + kernelPatches.request_key_helper 16148 16149 kernelPatches.cpu-cgroup-v2."4.11" 16149 16150 kernelPatches.modinst_arg_list_too_long 16150 16151 ] ··· 16162 16163 linux_rpi1 = callPackage ../os-specific/linux/kernel/linux-rpi.nix { 16163 16164 kernelPatches = with kernelPatches; [ 16164 16165 bridge_stp_helper 16166 + request_key_helper 16165 16167 ]; 16166 16168 rpiVersion = 1; 16167 16169 }; ··· 16169 16171 linux_rpi2 = callPackage ../os-specific/linux/kernel/linux-rpi.nix { 16170 16172 kernelPatches = with kernelPatches; [ 16171 16173 bridge_stp_helper 16174 + request_key_helper 16172 16175 ]; 16173 16176 rpiVersion = 2; 16174 16177 }; ··· 16176 16179 linux_rpi3 = callPackage ../os-specific/linux/kernel/linux-rpi.nix { 16177 16180 kernelPatches = with kernelPatches; [ 16178 16181 bridge_stp_helper 16182 + request_key_helper 16179 16183 ]; 16180 16184 rpiVersion = 3; 16181 16185 }; ··· 16183 16187 linux_rpi4 = callPackage ../os-specific/linux/kernel/linux-rpi.nix { 16184 16188 kernelPatches = with kernelPatches; [ 16185 16189 bridge_stp_helper 16190 + request_key_helper 16186 16191 ]; 16187 16192 rpiVersion = 4; 16188 16193 }; ··· 16190 16195 linux_4_4 = callPackage ../os-specific/linux/kernel/linux-4.4.nix { 16191 16196 kernelPatches = 16192 16197 [ kernelPatches.bridge_stp_helper 16198 + kernelPatches.request_key_helper 16193 16199 kernelPatches.cpu-cgroup-v2."4.4" 16194 16200 kernelPatches.modinst_arg_list_too_long 16195 16201 # https://github.com/NixOS/nixpkgs/issues/42755 ··· 16203 16209 linux_4_9 = callPackage ../os-specific/linux/kernel/linux-4.9.nix { 16204 16210 kernelPatches = 16205 16211 [ kernelPatches.bridge_stp_helper 16212 + kernelPatches.request_key_helper 16206 16213 kernelPatches.cpu-cgroup-v2."4.9" 16207 16214 kernelPatches.modinst_arg_list_too_long 16208 16215 ]; ··· 16211 16218 linux_4_14 = callPackage ../os-specific/linux/kernel/linux-4.14.nix { 16212 16219 kernelPatches = 16213 16220 [ kernelPatches.bridge_stp_helper 16221 + kernelPatches.request_key_helper 16214 16222 # See pkgs/os-specific/linux/kernel/cpu-cgroup-v2-patches/README.md 16215 16223 # when adding a new linux version 16216 16224 kernelPatches.cpu-cgroup-v2."4.11" ··· 16222 16230 linux_4_19 = callPackage ../os-specific/linux/kernel/linux-4.19.nix { 16223 16231 kernelPatches = 16224 16232 [ kernelPatches.bridge_stp_helper 16233 + kernelPatches.request_key_helper 16225 16234 kernelPatches.modinst_arg_list_too_long 16226 16235 kernelPatches.export_kernel_fpu_functions."4.14" 16227 16236 ]; ··· 16230 16239 linux_5_3 = callPackage ../os-specific/linux/kernel/linux-5.3.nix { 16231 16240 kernelPatches = [ 16232 16241 kernelPatches.bridge_stp_helper 16242 + kernelPatches.request_key_helper 16233 16243 kernelPatches.export_kernel_fpu_functions."5.3" 16234 16244 ]; 16235 16245 }; ··· 16237 16247 linux_5_4 = callPackage ../os-specific/linux/kernel/linux-5.4.nix { 16238 16248 kernelPatches = [ 16239 16249 kernelPatches.bridge_stp_helper 16250 + kernelPatches.request_key_helper 16240 16251 ]; 16241 16252 }; 16242 16253 16243 16254 linux_testing = callPackage ../os-specific/linux/kernel/linux-testing.nix { 16244 16255 kernelPatches = [ 16245 16256 kernelPatches.bridge_stp_helper 16257 + kernelPatches.request_key_helper 16246 16258 ]; 16247 16259 }; 16248 16260 16249 16261 linux_testing_bcachefs = callPackage ../os-specific/linux/kernel/linux-testing-bcachefs.nix { 16250 16262 kernelPatches = 16251 16263 [ kernelPatches.bridge_stp_helper 16264 + kernelPatches.request_key_helper 16252 16265 kernelPatches.modinst_arg_list_too_long 16253 16266 ]; 16254 16267 }; ··· 16256 16269 linux_hardkernel_4_14 = callPackage ../os-specific/linux/kernel/linux-hardkernel-4.14.nix { 16257 16270 kernelPatches = [ 16258 16271 kernelPatches.bridge_stp_helper 16272 + kernelPatches.request_key_helper 16259 16273 kernelPatches.modinst_arg_list_too_long 16260 16274 ]; 16261 16275 };