@@ -588,9 +588,8 @@ func trustedRootCmd(t *testing.T, downloadDirectory, tsaURL string) *trustedroot
588588 defer rekorFP .Close ()
589589 must (downloadFile (rekorURL + "/api/v1/log/publicKey" , rekorFP ), t )
590590 ctfePath := filepath .Join (downloadDirectory , "ctfe.pub" )
591- home , err := os .UserHomeDir ()
592- must (err , t )
593- must (copyFile (filepath .Join (home , "fulcio" , "config" , "ctfe" , "pubkey.pem" ), ctfePath ), t )
591+ ctLogKey := os .Getenv ("CT_LOG_KEY" )
592+ must (copyFile (ctLogKey , ctfePath ), t )
594593 out := filepath .Join (downloadDirectory , "trusted_root.json" )
595594 cmd := & trustedroot.CreateCmd {
596595 CertChain : []string {caPath },
@@ -624,8 +623,7 @@ func prepareTrustedRootWithSelfSignedCertificate(t *testing.T, certPath, tsaURL
624623}
625624
626625func TestSignVerifyWithTUFMirror (t * testing.T ) {
627- home , err := os .UserHomeDir () // fulcio repo was downloaded to $HOME in e2e_test.sh
628- must (err , t )
626+ ctLogKey := os .Getenv ("CT_LOG_KEY" )
629627 tufLocalCache := t .TempDir ()
630628 t .Setenv ("TUF_ROOT" , tufLocalCache )
631629 tufMirror := t .TempDir ()
@@ -652,7 +650,7 @@ func TestSignVerifyWithTUFMirror(t *testing.T) {
652650 targets : []targetInfo {
653651 {
654652 name : "ct.pub" ,
655- source : filepath . Join ( home , "fulcio" , "config" , "ctfe" , "pubkey.pem" ) ,
653+ source : ctLogKey ,
656654 },
657655 },
658656 wantSignErr : true ,
@@ -670,7 +668,7 @@ func TestSignVerifyWithTUFMirror(t *testing.T) {
670668 },
671669 {
672670 name : "ctfe.pub" ,
673- source : filepath . Join ( home , "fulcio" , "config" , "ctfe" , "pubkey.pem" ) ,
671+ source : ctLogKey ,
674672 },
675673 {
676674 name : "tsa_leaf.crt.pem" ,
@@ -699,7 +697,7 @@ func TestSignVerifyWithTUFMirror(t *testing.T) {
699697 },
700698 {
701699 name : "ctfe.pub" ,
702- source : filepath . Join ( home , "fulcio" , "config" , "ctfe" , "pubkey.pem" ) ,
700+ source : ctLogKey ,
703701 },
704702 {
705703 name : "tsaleaf.pem" ,
@@ -737,7 +735,7 @@ func TestSignVerifyWithTUFMirror(t *testing.T) {
737735 {
738736 name : "cert-transparency.pem" ,
739737 usage : "CTFE" ,
740- source : filepath . Join ( home , "fulcio" , "config" , "ctfe" , "pubkey.pem" ) ,
738+ source : ctLogKey ,
741739 },
742740 {
743741 name : "tsaleaf.pem" ,
@@ -813,7 +811,7 @@ func TestSignVerifyWithTUFMirror(t *testing.T) {
813811 must (gotErr , t )
814812
815813 // Verify an image
816- issuer := os .Getenv ("OIDC_URL " )
814+ issuer := os .Getenv ("ISSUER_URL " )
817815 verifyCmd := cliverify.VerifyCommand {
818816 CertVerifyOptions : options.CertVerifyOptions {
819817 CertOidcIssuer : issuer ,
@@ -959,7 +957,7 @@ func TestSignAttestVerifyBlobWithSigningConfig(t *testing.T) {
959957 must (err , t )
960958
961959 // Verify a blob
962- issuer := os .Getenv ("OIDC_URL " )
960+ issuer := os .Getenv ("ISSUER_URL " )
963961 verifyBlobCmd := cliverify.VerifyBlobCmd {
964962 KeyOpts : ko ,
965963 CertVerifyOptions : options.CertVerifyOptions {
@@ -1074,7 +1072,7 @@ func TestSignAttestVerifyContainerWithSigningConfig(t *testing.T) {
10741072 // Verify Fulcio-signed image
10751073 cmd := cliverify.VerifyCommand {
10761074 CertVerifyOptions : options.CertVerifyOptions {
1077- CertOidcIssuer : os .Getenv ("OIDC_URL " ),
1075+ CertOidcIssuer : os .Getenv ("ISSUER_URL " ),
10781076 CertIdentity : certID ,
10791077 },
10801078 NewBundleFormat : true ,
@@ -1102,7 +1100,7 @@ func TestSignAttestVerifyContainerWithSigningConfig(t *testing.T) {
11021100 // Verify attestation
11031101 verifyAttestation := cliverify.VerifyAttestationCommand {
11041102 CertVerifyOptions : options.CertVerifyOptions {
1105- CertOidcIssuer : os .Getenv ("OIDC_URL " ),
1103+ CertOidcIssuer : os .Getenv ("ISSUER_URL " ),
11061104 CertIdentity : certID ,
11071105 },
11081106 CommonVerifyOptions : options.CommonVerifyOptions {
@@ -1412,7 +1410,7 @@ func TestSignVerifyBundle(t *testing.T) {
14121410 // Verify Fulcio-signed image
14131411 cmd = cliverify.VerifyCommand {
14141412 CertVerifyOptions : options.CertVerifyOptions {
1415- CertOidcIssuer : os .Getenv ("OIDC_URL " ),
1413+ CertOidcIssuer : os .Getenv ("ISSUER_URL " ),
14161414 CertIdentityRegexp : ".+" ,
14171415 },
14181416 CommonVerifyOptions : options.CommonVerifyOptions {
@@ -3998,7 +3996,7 @@ from %s
39983996` , signedImg1 )
39993997 withLowercaseDockerfile := mkfile (withLowercaseDockerfileContents , td , t )
40003998
4001- issuer := os .Getenv ("OIDC_URL " )
3999+ issuer := os .Getenv ("ISSUER_URL " )
40024000
40034001 tests := []struct {
40044002 name string
@@ -4127,7 +4125,7 @@ spec:
41274125 unsignedManifestContents := fmt .Sprintf (manifestTemplate , "unsigned-img" , unsignedImg )
41284126 unsignedManifest := mkfileWithExt (unsignedManifestContents , td , ".yaml" , t )
41294127
4130- issuer := os .Getenv ("OIDC_URL " )
4128+ issuer := os .Getenv ("ISSUER_URL " )
41314129
41324130 tests := []struct {
41334131 name string
0 commit comments