tenseleyflow/shithub / abfac46

Browse files

Address lint: gofumpt sshkey.go; nolint static-argv ssh-keygen call in test

Authored by mfwolffe <wolffemf@dukes.jmu.edu>
SHA
abfac461cb0032fa12f254681e0f02134c58e4e9
Parents
0936fec
Tree
701f9c1

2 changed files

StatusFile+-
M internal/auth/sshkey/sshkey.go 1 1
M internal/auth/sshkey/sshkey_test.go 2 1
internal/auth/sshkey/sshkey.gomodified
@@ -8,7 +8,7 @@
88
 package sshkey
99
 
1010
 import (
11
-	"crypto/dsa"   //nolint:staticcheck // DSA detection only — never accepted.
11
+	"crypto/dsa" //nolint:staticcheck // DSA detection only — never accepted.
1212
 	"crypto/ecdsa"
1313
 	"crypto/ed25519"
1414
 	"crypto/rsa"
internal/auth/sshkey/sshkey_test.gomodified
@@ -35,7 +35,8 @@ func TestParse_AcceptsEd25519(t *testing.T) {
3535
 	}
3636
 	// Cross-check against ssh-keygen if available — defensive.
3737
 	if _, err := exec.LookPath("ssh-keygen"); err == nil {
38
-		out, err := exec.Command("ssh-keygen", "-E", "sha256", "-lf",
38
+		// G204: argv is a static list with a fixed test fixture path.
39
+		out, err := exec.Command("ssh-keygen", "-E", "sha256", "-lf", //nolint:gosec
3940
 			filepath.Join("testdata", "ed25519.pub")).Output()
4041
 		if err != nil {
4142
 			t.Fatalf("ssh-keygen: %v", err)