Skip to content

feat(contracts): sc-hard-17/18/19/20 reentrancy guard, fixed-point ma… - #1460

Merged
ayomideadeniran merged 2 commits into
StellarDevHub:mainfrom
topboy192:feature/sc-hard-17-18-19-20
Oct 2, 2026
Merged

ayomideadeniran merged 2 commits into
StellarDevHub:mainfrom
topboy192:feature/sc-hard-17-18-19-20

Conversation

@topboy192

Copy link
Copy Markdown
Contributor

…th, rbac, contracterror

Closes #1363
close #1364
close #1365
close #1366

…th, rbac, contracterror

- StellarDevHub#1363 sc-hard-17: zero-cost atomic reentrancy guard via soroban temporary
  storage mutex locks in lending_pool and smart_vault. nested reentrant
  calls revert with typed ReentrancyGuardTriggered error.

- StellarDevHub#1364 sc-hard-18: replaced raw arithmetic with checked_add/checked_sub/
  checked_mul/checked_div in continuous_bonding_curve and lending_pool.
  added fp18 module with 18-decimal fixed-point helpers and typed
  Overflow/Underflow/DivisionByZero error variants.

- StellarDevHub#1365 sc-hard-19: introduced reusable access_control crate (300-399 range)
  with Admin/Operator/Guardian roles, timelocked role transfers, and atomic
  circuit-breaker pause/unpause. emergency withdrawals are exempt.

- StellarDevHub#1366 sc-hard-20: eliminated all panic!("...") strings across every
  workspace contract. added documented #[contracterror] enums with
  partitioned discriminant ranges: lending_pool 1-99, smart_vault 100-199,
  continuous_bonding_curve 200-299, access_control 300-399, others 400+.
  affected: certificate_nft, oracle_aggregator, quadratic_voting,
  token_migration, sybil_resistance, freelance-platform/reputation_system,
  hello_world/freelance_platform, hello_world/reputation_system.

- .gitignore: added .soroban/, *.wasm entries to exclude build artifacts.

Closes StellarDevHub#1363, StellarDevHub#1364, StellarDevHub#1365, StellarDevHub#1366
@vercel

vercel Bot commented Sep 27, 2026

Copy link
Copy Markdown

@topboy192 is attempting to deploy a commit to the Ayomide Adeniran's projects Team on Vercel.

A member of the Team first needs to authorize it.

@drips-wave

drips-wave Bot commented Sep 27, 2026

Copy link
Copy Markdown

@topboy192 Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@ayomideadeniran

Copy link
Copy Markdown
Contributor

pr under review, if i find any wrong implementation i will let you know

@ayomideadeniran
ayomideadeniran merged commit a4ffaff into StellarDevHub:main Oct 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

2 participants