Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: remove bucketdeleted status #54

Merged
merged 1 commit into from
Jun 27, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion attest/attest_monitor.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ func (a *AttestMonitor) UpdateAttestedChallengeIdLoop() {
logging.Logger.Errorf("update latest attested challenge error, err=%+v", err)
continue
}
logging.Logger.Infof("latest attested challenge ids: %+v", challengeIds)
a.mtx.Lock()
a.updateAttestedCacheAndEventStatus(a.attestedChallengeIds, challengeIds)
for _, id := range challengeIds {
Expand Down
1 change: 0 additions & 1 deletion db/model/event.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,5 +51,4 @@ const (
Unknown VerifyResult = iota // Event not been verified
HashMatched // The challenge failed, hashes are matched
HashMismatched // The challenge succeed, hashed are not matched
BucketDeleted
)
4 changes: 0 additions & 4 deletions verifier/hash_verifier.go
Original file line number Diff line number Diff line change
Expand Up @@ -142,10 +142,6 @@ func (v *Verifier) verifyForSingleEvent(event *model.Event) error {
if err != nil {
logging.Logger.Errorf("error getting challenge result from sp for challengeId: %d, objectId: %s, err=%s", event.ChallengeId, event.ObjectId, err.Error())
// TODO: Create error code list for SP side
if strings.Contains(err.Error(), "35201") {
err := v.dataProvider.UpdateEventStatusVerifyResult(event.ChallengeId, model.Verified, model.BucketDeleted)
return err
}
err := v.dataProvider.UpdateEventStatusVerifyResult(event.ChallengeId, model.Verified, model.HashMismatched)
return err
}
Expand Down