Skip to content

[contracts] Add a bridge contract example demonstrating cross-chain asset transfer risks #1033

Description

@CelestinaBeing

Context

contracts/bridge/ exists. A bridge contract that demonstrates the most common cross-chain security issues (replay attacks, signature validation) would make an excellent advanced example.

Work

  • Implement a simplified Stellar ↔ EVM asset bridge contract
  • Demonstrate: replay attack vulnerability (unsigned message reuse), correct nonce-based protection
  • Add cross-chain signature validation (Ethereum eth_sign format)
  • Write tests showing both the attack and the defense
  • sanctifier analyze should flag the replay vulnerability

Acceptance criteria

  • Replay attack demonstrated in test
  • Nonce-protected version is replay-resistant
  • sanctifier analyze detects the replay vulnerability

Metadata

Metadata

Assignees

Labels

Stellar WaveIssues in the Stellar wave program

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions