Skip to content

Commit

Permalink
fix(rot): fixed inventory type conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
spbsoluble committed Oct 4, 2023
1 parent 518ef3b commit a4c82f1
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions cmd/rot.go
Original file line number Diff line number Diff line change
Expand Up @@ -322,7 +322,7 @@ func readCertsFile(certsFilePath string, kfclient *api.Client) (map[string]strin
return certs, nil
}

func isRootStore(st *api.GetCertificateStoreResponse, invs *[]api.CertStoreInventory, minCerts int, maxKeys int, maxLeaf int) bool {
func isRootStore(st *api.GetCertificateStoreResponse, invs *[]api.CertStoreInventoryV1, minCerts int, maxKeys int, maxLeaf int) bool {
leafCount := 0
keyCount := 0
certCount := 0
Expand Down Expand Up @@ -445,7 +445,7 @@ kfutil stores rot reconcile --import-csv <audit-file>
continue
}

inventory, invErr := kfClient.GetCertStoreInventory(entry[0])
inventory, invErr := kfClient.GetCertStoreInventoryV1(entry[0])
if invErr != nil {
log.Printf("[ERROR] getting cert store inventory for: %s\n%s", entry[0], invErr)
}
Expand Down Expand Up @@ -748,7 +748,7 @@ the utility will first generate an audit report and then execute the add/remove
lookupFailures = append(lookupFailures, entry[0])
continue
}
inventory, invErr := kfClient.GetCertStoreInventory(entry[0])
inventory, invErr := kfClient.GetCertStoreInventoryV1(entry[0])
if invErr != nil {
log.Fatalf("[ERROR] getting cert store inventory: %s", invErr)
}
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ require (
github.com/Azure/azure-sdk-for-go/sdk/azidentity v1.3.1
github.com/Jeffail/gabs v1.4.0
github.com/Keyfactor/keyfactor-go-client-sdk v1.0.2
github.com/Keyfactor/keyfactor-go-client/v2 v2.1.3
github.com/Keyfactor/keyfactor-go-client/v2 v2.1.4
github.com/google/go-cmp v0.5.9
github.com/joho/godotenv v1.5.1
github.com/rs/zerolog v1.30.0
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ github.com/Jeffail/gabs v1.4.0/go.mod h1:6xMvQMK4k33lb7GUUpaAPh6nKMmemQeg5d4gn7/
github.com/Keyfactor/keyfactor-go-client v1.4.3 h1:CmGvWcuIbDRFM0PfYOQH6UdtAgplvZBpU++KTU8iseg=
github.com/Keyfactor/keyfactor-go-client-sdk v1.0.2 h1:caLlzFCz2L4Dth/9wh+VlypFATmOMmCSQkCPKOKMxw8=
github.com/Keyfactor/keyfactor-go-client-sdk v1.0.2/go.mod h1:Z5pSk8YFGXHbKeQ1wTzVN8A4P/fZmtAwqu3NgBHbDOs=
github.com/Keyfactor/keyfactor-go-client/v2 v2.1.3 h1:r0397OGm7SmEZJAI9OO5EUkWRUsEGZhGkCNWG1OeSYw=
github.com/Keyfactor/keyfactor-go-client/v2 v2.1.3/go.mod h1:3mfxdcwntB532QIATokBEkBCH0eXN2G/cdMZtu9NwNg=
github.com/Keyfactor/keyfactor-go-client/v2 v2.1.4 h1:PClA1rsT6YA3jsIcTeBROlaEBOqeYeFcXT3mx7FoWcQ=
github.com/Keyfactor/keyfactor-go-client/v2 v2.1.4/go.mod h1:3mfxdcwntB532QIATokBEkBCH0eXN2G/cdMZtu9NwNg=
github.com/Netflix/go-expect v0.0.0-20220104043353-73e0943537d2 h1:+vx7roKuyA63nhn5WAunQHLTznkw5W8b1Xc0dNjp83s=
github.com/Netflix/go-expect v0.0.0-20220104043353-73e0943537d2/go.mod h1:HBCaDeC1lPdgDeDbhX8XFpy1jqjK0IBG8W5K+xYqA0w=
github.com/coreos/go-systemd/v22 v22.5.0/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc=
Expand Down

0 comments on commit a4c82f1

Please sign in to comment.