chore(rust): upgrade ed25519-dalek and rand - #3418
chore(rust): upgrade ed25519-dalek and rand#3418Floze (floze-the-genius) wants to merge 1 commit into
Conversation
Signed-off-by: Floze <88098863+floze-the-genius@users.noreply.github.com>
|
Azure Pipelines: There may be pipelines that require an authorized user to comment /azp run to run. |
|
Welcome to the Agent Governance Toolkit! Thanks for your first pull request. |
🤖 AI Agent: test-generator — View details
Test coverage looks good. No gaps identified. |
🤖 AI Agent: contributor-guide — Welcome, and thank you for contributing! Great job on the detailed summary and thorough validation steps.
Welcome, and thank you for contributing! Great job on the detailed summary and thorough validation steps. Before merging, please address the following:
For guidance, refer to CONTRIBUTING.md. Let us know if you need help! |
🤖 AI Agent: breaking-change-detector — API Compatibility
API Compatibility
|
🤖 AI Agent: docs-sync-checker — Docs Sync
Docs Sync
|
🤖 AI Agent: security-scanner — View details
No security issues found. |
🤖 AI Agent: code-reviewer — View details
TL;DR: 0 blockers, 1 warning. [Upgrade appears secure but requires follow-up validation for cryptographic changes.]
Action items:
Warnings:
|
PR Review Summary
Verdict: AI review comments are untrusted advisory output. The summary reports workflow-generated completion status only, not model-authored pass/fail claims. |
|
🟡 Contributor Check: MEDIUM
Automated check by AGT Contributor Check. |
|
@microsoft-github-policy-service agree |
There was a problem hiding this comment.
Pull request overview
TL;DR: 0 blockers, 0 warnings. No issues found. Clean change.
Upgrades the Rust workspace dependencies in agent-governance-rust/ to ed25519-dalek 3.0.0 and rand 0.10.2, including the required source-level API migrations in identity, vault crypto, and nonce generation.
Changes:
- Bump
ed25519-dalekto 3.0.0 andrandto 0.10.2 (workspace + lockfile refresh). - Migrate OS-backed Ed25519 key generation to
SysRngviarand_core::UnwrapErrwhere required by the new fallible RNG API. - Update nonce generation to
rand::distr+SampleStringand add a regression test for the 32-char ASCII-alphanumeric nonce format.
Reviewed changes
Copilot reviewed 5 out of 6 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
agent-governance-rust/Cargo.toml |
Pins workspace dependencies to ed25519-dalek 3.0.0 and rand 0.10.2. |
agent-governance-rust/Cargo.lock |
Updates the resolved dependency graph to match the new major versions. |
agent-governance-rust/agentmesh/src/identity.rs |
Migrates Ed25519 key generation to SysRng with UnwrapErr for the updated RNG API. |
agent-governance-rust/agentmesh/src/identity_support.rs |
Aligns credential issuance / key rotation keygen with the updated RNG + dalek API expectations. |
agent-governance-rust/agentmesh/src/credential_vault.rs |
Replaces thread_rng() with rng() for key/nonce generation under rand 0.10. |
agent-governance-rust/agentmesh-mcp/src/mcp/clock.rs |
Migrates alphanumeric nonce generation to rand::distr + SampleString and adds a format regression test. |
|
Thanks Floze (@floze-the-genius). This targets the same six files and the same ed25519-dalek 2.x to 3.x / rand upgrade as #3420, which is already mergeable and linked to the tracking issue #3355. To keep the review in one place we are consolidating on #3420. Closing this as a duplicate, with no reflection on the work here. Please feel free to review #3420 or pick up another open issue. |
Summary
Upgrade the Rust workspace from
ed25519-dalek2.2.0 to 3.0.0 and fromrand0.8.6 to 0.10.2, including the required source-level API migration.Changes
rand::distributionstorand::distrand useSampleStringthread_rng()calls withrng()RngCoreimport withRngSysRngwrapped byrand_core::UnwrapErr, matching the new fallible system-RNG APIed25519-dalek3.0.0,curve25519-dalek5.0.0,and the
rand0.10 dependency stack32 ASCII-alphanumeric characters
The migration does not change serialized identity formats, public-key sizes,
signature sizes, nonce length, or credential-vault encryption behavior.
Security invariants
UnwrapErr(SysRng)preserves the previous fail-closed behavior if systementropy is unavailable.
generator seeded and periodically reseeded from the system RNG.
oversized signatures, cross-identity rejection, distinct generated keypairs,
key rotation, and encrypted vault persistence.
existing 32-character ASCII-alphanumeric contract.
Validation
rustup run 1.89.0 cargo test --release --workspacecargo check --workspace --all-targets-D warningsafter allowing only existing,unrelated repository warnings (
deprecated,single_element_loop,format_in_format_args,io_other_error, andmanual_is_multiple_of)rand0.8 /rand_core0.6 anded25519-dalek2.x are no longer presentcargo audit --file Cargo.lockrand/ Ed25519 dependency stackregorus 0.10.1:anyhow 1.0.102(RUSTSEC-2026-0190) and yankedspin 0.10.0AI Assistance
OpenAI Codex assisted with the API migration, regression test, and validation.
The implementation was checked against the exact crate sources, compiler
diagnostics, the repository's declared Rust 1.89 MSRV, and the complete release
test suite before submission.
Fixes #3355