Security
SafeDeal security audit — Level 6
Overall security score
100%
25/25 checks passed
100%
Smart contract security
8/8Reentrancy protection implemented
merchant-escrow/src/lib.rs:line 112
Integer overflow checks in place
All amounts use i128 with validation
Access control on admin functions
seller-verification/src/lib.rs:verify_kyc
Event emissions for all state changes
All contracts emit events on mutation
Contract initialization protection
initialize() can only be called once
Token transfer validation
Amount checked before USDC transfer
Escrow expiry auto-refund mechanism
auto_refund() in merchant-escrow
148 unit tests passing
All 5 contracts — cargo test
Frontend security
6/6No private keys stored in browser
Only publicKey stored in WalletContext
All API calls use HTTPS only
Horizon URL uses https://
Environment variables not exposed
All secrets in .env.local and Vercel
XSS protection via React
React escapes all rendered values
Wallet connection permission scoped
Freighter only gets publicKey access
No hardcoded credentials in code
GitHub repo has zero hardcoded secrets
Operational security
5/5GitHub secrets properly configured
VERCEL_TOKEN, ORG_ID, PROJECT_ID set
Contract IDs in environment variables
All IDs in Vercel env vars
CI/CD pipeline secured
Only main branch triggers deploy
Vercel deployment protected
Auto-deploy only from GitHub Actions
Dependencies regularly updated
Using latest Next.js 14 and SDKs
User protection
6/6AI fraud detection on buyer wallets
fraud-detection contract scans wallets
Escrow protects both parties
Funds locked until delivery confirmed
Dispute resolution mechanism
dispute-resolution contract handles cases
Auto-refund on deal expiry
auto_refund() releases after expiry
Seller trust badge system
seller-verification contract tracks history
Transaction amount validation
Min 0.01 USDC, max 10000 USDC per deal