Skip to content

Align allowance admission with liquidation threshold#613

Open
KillariDev wants to merge 2 commits into
mainfrom
t3code/solidity-security-audit-13
Open

Align allowance admission with liquidation threshold#613
KillariDev wants to merge 2 commits into
mainfrom
t3code/solidity-security-audit-13

Conversation

@KillariDev

Copy link
Copy Markdown
Collaborator

Summary

  • require new security-bond allowances to satisfy the same multiplier-adjusted boundary used by liquidation
  • align the UI Max calculation, atomic rounding, documentation, generated contract reference, and deterministic mainnet addresses
  • add contract and UI regressions for equality, unsafe admission, aggregate backing, rounding, and accessibility

Boundary semantics

Allowance admission now requires:

repBacking * PRICE_PRECISION >= allowance * securityMultiplier * repEthPrice

Liquidation keeps the strict inverse > comparison, so equality is admissible and non-liquidatable. Later REP withdrawals and escalation deposits intentionally retain their face-value coverage checks.

Validation

  • final full suite: 2,343 passed, 16 documented network-dependent skips, 0 failed
  • bun run tsc
  • bun run format:check
  • bun run check
  • bun run docs:check
  • bun run knip
  • bun run check:generated-clean
  • git diff --check

Final independent review: 93/100, no findings. Final visual review: 89/100, no findings.

Visual evidence

Documentation was checked at 1440x900 and 390x844. The UI change preserves the existing visible Max control and changes its calculated value plus accessible name only. A live UI screenshot could not be attached because the collaborative preview required authentication and the fallback simulation capture hung; focused DOM tests and production Chromium scenarios passed.

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.

1 participant