Skip to content

Enforce multi sig upgrades#67

Open
gloskull wants to merge 5 commits into
Vero-protocol:mainfrom
gloskull:enforce-multi-sig-upgrades
Open

Enforce multi sig upgrades#67
gloskull wants to merge 5 commits into
Vero-protocol:mainfrom
gloskull:enforce-multi-sig-upgrades

Conversation

@gloskull

Copy link
Copy Markdown
Contributor

This PR implements a secure, multi-signature governance process for the Vero Protocol's contract upgrades.

Key changes:

VeroCore Contract: A new contract entry point in engine-core/src/lib.rs that integrates governance, ZK-audit, and circuit-breaker logic.
Governance FSM: A finite state machine for proposals ensuring they transition from Pending to Approved (on quorum) and finally to Executed (after a timelock).
Upgrade Mechanism: The upgrade function validates the proposal state and uses env.deployer().update_current_contract_wasm() to apply the new code.
Security Gating:
init is now protected against re-initialization.
require_auth() is enforced for all sensitive operations (propose, approve, trip, reset, commit).
The circuit breaker halts all state-mutating transitions when open.
Production Readiness:
Refactored audit.rs to use host-provided crypto instead of external crates, ensuring no_std / WASM compatibility.
Cleaned up Cargo.toml dependencies.
Comprehensive Testing:
Fixed and restored unit tests for audit and circuit_breaker.
Added integration tests in governance_tests.rs covering the full lifecycle and security guards.
Closes gloskull#1

google-labs-jules Bot and others added 2 commits June 19, 2026 15:22
- Implemented VeroCore Soroban contract with multi-sig upgrade logic.
- Introduced Proposal FSM: Pending -> Approved -> Executed.
- Enforced quorum and timelock for contract upgrades.
- Added re-initialization protection to init.
- Ensured require_auth on all administrative entry points.
- Refactored audit hashing to use env.crypto() for WASM compatibility.
- Restored and updated unit tests for all modules.

Co-authored-by: gloskull <189399494+gloskull@users.noreply.github.com>
…41329769837677

Enforce Multi-sig Upgrades with Governance FSM
@N-thnI

N-thnI commented Jun 19, 2026

Copy link
Copy Markdown
Contributor

please resolve conflicts and it will be ready for merge

@gloskull gloskull marked this pull request as draft June 25, 2026 22:26
@gloskull gloskull marked this pull request as ready for review June 25, 2026 22:26
@gloskull

Copy link
Copy Markdown
Contributor Author

Conflicts resolved. Please review

@N-thnI

N-thnI commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

Well done, but it's not complete

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants