Skip to content

Commit

Permalink
update to not public func
Browse files Browse the repository at this point in the history
  • Loading branch information
nitro-neal committed Jan 31, 2023
1 parent abe6bb7 commit a6bfcde
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions credential/status/statuslist2021.go
Original file line number Diff line number Diff line change
Expand Up @@ -249,10 +249,10 @@ func bitstringExpansion(compressedBitstring string) ([]string, error) {

// ValidateCredentialInStatusList determines whether a credential is contained in a status list 2021 credential
// https://w3c-ccg.github.io/vc-status-list-2021/#validate-algorithm
// NOTE: this method does perform credential signature/proof block verification
// NOTE: this method does not perform credential signature/proof block verification
func ValidateCredentialInStatusList(credentialToValidate credential.VerifiableCredential, statusCredential credential.VerifiableCredential) (bool, error) {
// 1. Let credentialToValidate be a verifiable credentials containing a credentialStatus entry that is a StatusList2021Entry.
statusListEntryValue, ok := ToStatusList2021Entry(credentialToValidate.CredentialStatus)
statusListEntryValue, ok := toStatusList2021Entry(credentialToValidate.CredentialStatus)
if !ok {
return false, fmt.Errorf("credential to validate<%s> not using the StatusList2021 credentialStatus "+
"property", credentialToValidate.ID)
Expand Down Expand Up @@ -304,7 +304,7 @@ func ValidateCredentialInStatusList(credentialToValidate credential.VerifiableCr
return false, nil
}

func ToStatusList2021Entry(credStatus interface{}) (*StatusList2021Entry, bool) {
func toStatusList2021Entry(credStatus interface{}) (*StatusList2021Entry, bool) {
statusListEntryValue, ok := credStatus.(StatusList2021Entry)
if ok {
return &statusListEntryValue, true
Expand Down

0 comments on commit a6bfcde

Please sign in to comment.