Skip to content
Open
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
4 changes: 2 additions & 2 deletions appengine/endpoints/seed.go
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ func (SeedRequestHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
if err := validateSeedRequest(u, sr, acceptedHashes); err != nil {
log.Errorf(ctx, "validateSeedRequest(%s,%#v,%#v): %v", u.String(), sr, acceptedHashes, err)
if !strings.Contains(err.Error(), "not in allowlist") || hashCheck == "true" {
http.Error(w, fmt.Sprintf(errSeedResp, err, models.StatusReqUnreadable), http.StatusInternalServerError)
http.Error(w, fmt.Sprintf(errSeedResp, "seed request validation failed", models.StatusReqUnreadable), http.StatusInternalServerError)
return
}
}
Expand Down Expand Up @@ -161,7 +161,7 @@ func validateSeedRequest(u *user.User, sr models.SeedRequest, ah map[string]bool
return nil
}

return fmt.Errorf("request hash %v not in allowlist: %#v", hex.EncodeToString(sr.Hash), ah)
return fmt.Errorf("request hash %v not in allowlist", hex.EncodeToString(sr.Hash))
}

// signSeed will generate a seed response from a valid seed.
Expand Down
Loading