Skip to content
Merged
Show file tree
Hide file tree
Changes from 14 commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
221599b
update dep and renaming modules
noel2004 Aug 6, 2025
8970299
refactor for dynamic loading
noel2004 Aug 8, 2025
8e8da95
dynamic asset loading
noel2004 Aug 8, 2025
8607162
fmt
noel2004 Aug 8, 2025
52db8ad
fix base64 issue for url safe
noel2004 Aug 9, 2025
6fc583f
Merge remote-tracking branch 'origin/develop' into feat/dyn_asset_loa…
noel2004 Aug 18, 2025
617271a
update zkvm-prover dep and fix
noel2004 Aug 18, 2025
e4bd639
remove "dump" util, fmt and clippy
noel2004 Aug 18, 2025
47bcca3
purge deprecated entry
noel2004 Aug 18, 2025
072475a
update gpu build lock
noel2004 Aug 18, 2025
e325b82
fixings for updating vk to hexstring
noel2004 Aug 19, 2025
c681446
lint
noel2004 Aug 19, 2025
8ef21f0
update according to reviews
noel2004 Aug 22, 2025
a75f857
purge out-dated comment
noel2004 Aug 22, 2025
7999f0d
update gpu for 0.5.6
noel2004 Aug 22, 2025
77d8b5b
fix issue in config template
noel2004 Aug 22, 2025
ab86d33
Merge remote-tracking branch 'origin/develop' into feat/dyn_asset_loa…
noel2004 Aug 25, 2025
65fa249
bump dep of zkvm-prover
noel2004 Aug 25, 2025
2afa27d
new metrics for proof stat
noel2004 Aug 25, 2025
6a9a34b
update metrics
noel2004 Aug 26, 2025
710e38e
Merge remote-tracking branch 'origin/develop' into feat/dyn_asset_loa…
noel2004 Aug 26, 2025
3cbd07c
one line command to setup coordinator configurations
noel2004 Aug 26, 2025
8593bb2
Merge branch 'feat/prover_metric' into feat/dyn_asset_loading
noel2004 Aug 27, 2025
ce7dcaf
Fix hardfork min version check
noel2004 Aug 27, 2025
6f60a8d
fix according to AI review
noel2004 Aug 27, 2025
e1286da
Revert config.json
noel2004 Aug 28, 2025
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
440 changes: 156 additions & 284 deletions Cargo.lock

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@ repository = "https://github.com/scroll-tech/scroll"
version = "4.5.8"

[workspace.dependencies]
scroll-zkvm-prover-euclid = { git = "https://github.com/scroll-tech/zkvm-prover", branch = "feat/0.5.1", package = "scroll-zkvm-prover" }
scroll-zkvm-verifier-euclid = { git = "https://github.com/scroll-tech/zkvm-prover", branch = "feat/0.5.1", package = "scroll-zkvm-verifier" }
scroll-zkvm-types = { git = "https://github.com/scroll-tech/zkvm-prover", branch = "feat/0.5.1" }
scroll-zkvm-prover = { git = "https://github.com/scroll-tech/zkvm-prover", rev = "d871af1" }
scroll-zkvm-verifier = { git = "https://github.com/scroll-tech/zkvm-prover", rev = "d871af1" }
scroll-zkvm-types = { git = "https://github.com/scroll-tech/zkvm-prover", rev = "d871af1" }

sbv-primitives = { git = "https://github.com/scroll-tech/stateless-block-verifier", branch = "chore/openvm-1.3", features = ["scroll"] }
sbv-utils = { git = "https://github.com/scroll-tech/stateless-block-verifier", branch = "chore/openvm-1.3" }
Expand Down
24 changes: 21 additions & 3 deletions coordinator/internal/logic/verifier/verifier.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ package verifier

import (
"encoding/base64"
"encoding/hex"
"encoding/json"
"fmt"
"io"
Expand Down Expand Up @@ -129,6 +130,23 @@ const blocked_vks = `
D6YFHwTLZF/U2zpYJPQ3LwJZRm85yA5Vq2iFBqd3Mk4iwOUpS8sbOp3vg2+NDxhhKphgYpuUlykpdsoRhEt+cw==,
`

// tries to decode s as hex, and if that fails, as base64.
func decodeVkString(s string) ([]byte, error) {
// Try hex decoding first
if b, err := hex.DecodeString(s); err == nil {
return b, nil
}
// Fallback to base64 decoding
b, err := base64.StdEncoding.DecodeString(s)
if err != nil {
return nil, err
}
if len(b) == 0 {
return nil, fmt.Errorf("decode vk string %s fail (empty bytes)", s)
}
return b, nil
}

func (v *Verifier) loadOpenVMVks(cfg config.AssetConfig) error {

vkFileName := cfg.Vkfile
Expand Down Expand Up @@ -165,17 +183,17 @@ func (v *Verifier) loadOpenVMVks(cfg config.AssetConfig) error {
v.OpenVMVkMap[dump.Bundle] = struct{}{}
log.Info("Load vks", "from", cfg.AssetsPath, "chunk", dump.Chunk, "batch", dump.Batch, "bundle", dump.Bundle)

decodedBytes, err := base64.StdEncoding.DecodeString(dump.Chunk)
decodedBytes, err := decodeVkString(dump.Chunk)
if err != nil {
return err
}
v.ChunkVk[cfg.ForkName] = decodedBytes
decodedBytes, err = base64.StdEncoding.DecodeString(dump.Batch)
decodedBytes, err = decodeVkString(dump.Batch)
if err != nil {
return err
}
v.BatchVk[cfg.ForkName] = decodedBytes
decodedBytes, err = base64.StdEncoding.DecodeString(dump.Bundle)
decodedBytes, err = decodeVkString(dump.Bundle)
if err != nil {
return err
}
Expand Down
83 changes: 52 additions & 31 deletions crates/gpu_override/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading