Keys and certificates for YubiKeys, written in Go
Full Changelog: https://github.com/go-piv/piv-go/compare/v1.10.0...v1.11.0
Full Changelog: https://github.com/go-piv/piv-go/compare/v1.9.0...v1.10.0
Updates:
NOTE: previous uses of SetCertificate for the SlotAuthentication and SlotCardAuthentication used the wrong object IDs. This updates them to use the correct values, which may cause breaking changes for previously written certificate. To migrate to the correct slots, use:
mk := piv.DefaultManagementKey
// Migrate SlotAuthenication certificate to the correct slot.
authCert, err := yk.Certificate(piv.SlotCardAuthentication)
if err != nil {
// ...
}
if err := yk.SetCertificate(mk, piv.SlotAuthentication, authCert); err != nil {
// ...
}
// Migrate SlotCardAuthentication certificate to the correct slot.
cardAuthCert, err := yk.Certificate(piv.SlotKeyManagement)
if err != nil {
// ...
}
if err := yk.SetCertificate(mk, piv.SlotCardAuthentication, cardAuthCert); err != nil {
// ...
}