Skip to content

Commit

Permalink
add log to coordiantor log check (#1473)
Browse files Browse the repository at this point in the history
Co-authored-by: georgehao <[email protected]>
Co-authored-by: colinlyguo <[email protected]>
  • Loading branch information
3 people authored Aug 6, 2024
1 parent 073e9e8 commit daca3ae
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
2 changes: 1 addition & 1 deletion common/version/version.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"runtime/debug"
)

var tag = "v4.4.40"
var tag = "v4.4.41"

var commit = func() string {
if info, ok := debug.ReadBuildInfo(); ok {
Expand Down
7 changes: 5 additions & 2 deletions coordinator/internal/logic/auth/login.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,8 @@ func (l *LoginLogic) Check(login *types.LoginParameter) error {
if login.PublicKey != "" {
verify, err := login.Verify()
if err != nil || !verify {
log.Error("auth message verify failure", "prover_name", login.Message.ProverName,
"prover_version", login.Message.ProverVersion, "message", login.Message)
return errors.New("auth message verify failure")
}
}
Expand All @@ -84,13 +86,14 @@ func (l *LoginLogic) Check(login *types.LoginParameter) error {
vks[vk] = struct{}{}
}
default:
log.Error("invalid prover_type", "value", proverType)
log.Error("invalid prover_type", "value", proverType, "prover name", login.Message.ProverName, "prover_version", login.Message.ProverVersion)
}
}

for _, vk := range login.Message.VKs {
if _, ok := vks[vk]; !ok {
log.Error("vk inconsistency", "prover vk", vk)
log.Error("vk inconsistency", "prover vk", vk, "prover name", login.Message.ProverName,
"prover_version", login.Message.ProverVersion, "message", login.Message)
if !version.CheckScrollProverVersion(login.Message.ProverVersion) {
return fmt.Errorf("incompatible prover version. please upgrade your prover, expect version: %s, actual version: %s",
version.Version, login.Message.ProverVersion)
Expand Down

0 comments on commit daca3ae

Please sign in to comment.