This guide is for contributors preparing the QuickLendX Soroban smart contracts for an external security audit. It outlines exactly what to provide to the auditor, what the audit process looks like, and what to verify before handing over the codebase.
Before creating the audit commit hash, ensure all the following checks pass locally. Do not hand over code with failing tests or unaddressed lints.
cd quicklendx-contracts
# 1. Build for the target architecture
cargo build --target wasm32-unknown-unknown --release
# 2. Run all tests (including fuzz tests if applicable)
cargo test --workspace
# 3. Check for any clippy warnings
cargo clippy --workspace --all-targets -- -D warningsEnsure no std:: dependencies have leaked into the contract code. The contract must maintain #![no_std] discipline. Use soroban_sdk primitives exclusively.
Search the codebase for TODO or FIXME and either resolve them or move them to the issue tracker. The auditor will flag unresolved inline TODOs as potential risks.
When engaging the audit firm, provide a single zip file or a direct link to a specific commit hash containing the following:
Clearly define what is in and out of scope. For example:
- In Scope:
quicklendx-contracts/src/**/*.rs - Out of Scope:
quicklendx-frontend/,quicklendx-backend/
Never give a branch name (e.g., main). Always provide the exact commit hash:
Commit: a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6q7r8s9t0
Point the auditor to the rustdoc output. Provide them with the command to generate it locally:
cargo doc --no-deps --openLink the auditors directly to our core design documents:
Auditors will typically spend the first week reviewing the architecture and asking clarifying questions. Expect them to ask for concrete examples of state transitions.
Example Auditor Question:
"How does an invoice transition from
FundedtoRepaidif the borrower only sends a partial payment?"
Example Contributor Response:
"Partial payments do not automatically transition the invoice to
Repaid. The entrypointrecord_payment(env, invoice_id, amount)updates theremaining_balance. Only whenremaining_balance == 0does the state machine allow the transition toRepaid."
You will receive a draft report detailing vulnerabilities categorized by severity (Critical, High, Medium, Low, Informational).
You will have a window (usually 1-2 weeks) to fix the identified issues. For each finding, you will either:
- Fix the issue: Submit a PR addressing the vulnerability.
- Acknowledge/Accept the risk: Provide a documented justification for why the behavior is intended.
After reviewing your fixes, the auditor will publish the final report, verifying that the critical and high vulnerabilities have been resolved.