fix: Use proper key when signing kubelet certificate

I assume this was a mistake when copying and the kubelet key should have been used here.

This bug was introduced in #11471.

Signed-off-by: Aaron Dewes <aaron@nirvati.org>
(cherry picked from commit 147a3c0daf)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
This commit is contained in:
Aaron Dewes
2025-03-24 14:54:38 +01:00
committed by Brad Davidson
parent cb50fe1472
commit fd4d3be4d4

View File

@@ -95,7 +95,7 @@ func ClientKubeletCert(control *config.Control, auth nodepassword.NodeAuthValida
util.SendError(err, resp, req, errCode)
return
}
signAndSend(resp, req, control.Runtime.ClientCA, control.Runtime.ClientCAKey, control.Runtime.ClientKubeProxyKey, certutil.Config{
signAndSend(resp, req, control.Runtime.ClientCA, control.Runtime.ClientCAKey, control.Runtime.ClientKubeletKey, certutil.Config{
CommonName: "system:node:" + nodeName,
Organization: []string{user.NodesGroup},
Usages: []x509.ExtKeyUsage{x509.ExtKeyUsageClientAuth},