Prepared by:
HALBORN
Last Updated 04/20/2026
Date of Engagement: March 23rd, 2026 - April 15th, 2026
100% of all REPORTED Findings have been addressed
All findings
41
Critical
0
High
4
Medium
16
Low
14
Informational
7
Temple, a decentralized finance (DeFi) platform built on the Canton Network, commissioned a penetration test and automated security scan of its backend API. The engagement was performed by Halborn, Inc. The review targeted the orderbook-v2-do-NOT-apply-now branch of the temple-backend-api repository, at commit e88c6228ebb93e88609f0760b9166f97112e8479, hosted at https://github.com/Temple-Digital-Group/temple-backend-api/tree/orderbook-v2-do-NOT-apply-now.
The defined scope encompassed the public trading API endpoints, internal frontend-facing trading endpoints, API key self-service and administrative management endpoints, and the API key authentication mechanism. Key trading operations reviewed included order creation and cancellation, balance and trade history retrieval, withdrawal requests, and deposit and withdrawal history.
The purpose of this engagement was to identify security vulnerabilities, misconfigurations, and logic weaknesses across the authentication, session management, trading, and API key management surfaces of the Temple backend API prior to production deployment.
The engagement was scoped at a complexity level of 2 and spanned 18 days, during which Halborn specialist conducted a combined penetration test and automated scan of the Temple backend API. The primary objectives were to evaluate the security of trading endpoints, API key authentication flows, session and MFA management, and business logic controls.
The overall security posture of the assessed codebase revealed a significant number of findings spanning authentication, session management, cryptographic implementation, audit integrity, business logic enforcement, and privacy controls. While several fundamental security controls were correctly implemented, including transport security, SQL injection resistance, role separation, and cookie hardening; a broad set of weaknesses was identified that collectively represented meaningful risk to the platform's users, operators, and trading integrity.
The most important areas of remediation identified during the engagement include:
Partial MFA session tokens being accepted on administrative, trading, bridge, settings, and wallet routes without full-session enforcement, allowing unauthenticated or MFA-incomplete identities to reach sensitive handlers.
Missing balance, asset validity, order cap, minimum quantity, and trading-pause enforcement at order submission and withdrawal boundaries, undermining the integrity of core trading controls.
Multiple authentication bypass and session-revocation weaknesses, including revoked partial MFA sessions completing login, email verification auto-login bypassing account lock checks, and stale KMS public keys continuing to validate revoked tokens.
Audit log deficiencies including sensitive data persistence, incorrect authorization outcome fields, and incomplete sanitization of query parameters and case-variant field names.
Cryptographic and entropy weaknesses including UUID generation panics on entropy failure, insufficient MFA backup code entropy, and a double-hashing defect in a KMS signing helper.
Privacy and data handling issues including excessive email address logging across operational paths and incomplete user data erasure across ancillary tables.
Cross-origin and CSRF control gaps on password reset endpoints, and query parameter injection in outbound CoinGecko API requests.
All of findings were marked as solved at the time of reporting, with one finding accepted as a known risk.
| Security analysis | Risk level | Remediation |
|---|---|---|
| Concurrent Access to Shared Passkey Session State | High | Solved - 03/24/2026 |
| Wallet Linking Trusts Client-Side Party Ownership Checks | High | Solved - 04/03/2026 |
| Email Verification Auto-Login Bypasses Account Lock Checks | High | Solved - 03/27/2026 |
| Withdrawal Submission Does Not Enforce Balance or Asset Validity | High | Solved - 04/10/2026 |
| Reset and Email Verification Tokens Are Placed in URL Query Strings | Medium | Solved - 04/09/2026 |
| Missing Full-Session Enforcement on Administrative Routes | Medium | Solved - 03/23/2026 |
| Admin CSV Exports Allow Spreadsheet Formula Injection | Medium | Solved - 04/15/2026 |
| Invalid Identity State in Partial MFA Sessions | Medium | Solved - 03/25/2026 |
| Revoked Partial MFA Sessions Can Still Complete Login | Medium | Solved - 03/30/2026 |
| Order Submission Does Not Enforce Configured `Maximum Limits | Medium | Solved - 04/09/2026 |
| Trading Pause Does Not Block Order Creation | Medium | Solved - 04/10/2026 |
| Incomplete Audit Log Sanitization | Medium | Solved - 03/24/2026 |
| UUID Generation Panics on Entropy Failure | Medium | Solved - 04/02/2026 |
| Settings Re-Authentication Bypasses Password-Failure Accounting | Medium | Solved - 04/01/2026 |
| Email Changes Silently Disable Email-Keyed TOTP and Passkeys Methods | Medium | Solved - 04/07/2026 |
| Sensitive Data Stored in Audit Logs | Medium | Solved - 03/23/2026 |
| Incomplete Passkey Login Completion | Medium | Solved - 03/25/2026 |
| Amulet Disclosures Endpoint Queries Arbitrary Party IDs | Medium | Solved - 03/30/2026 |
| Order Submission Does Not Enforce Symbol minimum_quantity | Medium | Solved - 04/10/2026 |
| Partial MFA Login Fails Open on CSRF Generation Errors | Medium | Solved - 04/02/2026 |
| Unbounded Background Task Creation | Low | Solved - 03/26/2026 |
| Password Reset Rate-Limit Misconfiguration | Low | Solved - 03/24/2026 |
| Incorrect Client IP Attribution in Audit Logs | Low | Solved - 03/23/2026 |
| Insufficient Entropy in MFA Backup Codes | Low | Solved - 03/24/2026 |
| Client-IP Parse Failures Collapse to Localhost | Low | Solved - 04/01/2026 |
| Production Build Uses Out-of-Support Runtime Components Without Enforced Vulnerability Gates | Low | Solved - 04/13/2026 |
| Best-Effort Session Revocation in Security-Sensitive Flows | Low | Solved - 03/26/2026 |
| Weak Cross-Origin Validation on Password Reset Endpoints | Low | Solved - 03/23/2026 |
| Missing Full-Session Enforcement on Sensitive Routes | Low | Solved - 03/26/2026 |
| Re-Authentication Password Lockout Is Not Enforced | Low | Solved - 03/31/2026 |
| Stale KMS Public Key Accepts Revoked JWTs | Low | Solved - 04/01/2026 |
| Password Reset Bypasses HIBP-Backed Compromised-Password Policy | Low | Solved - 04/03/2026 |
| Sensitive Token Exposure in CSRF Logs | Low | Solved - 03/23/2026 |
| Query Parameter Injection in Outbound API Requests | Low | Solved - 03/24/2026 |
| Misleading Authorization Status in Audit Logs | Informational | Solved - 03/23/2026 |
| Dead Security Verification Logic | Informational | Solved - 03/24/2026 |
| Ambiguous Cryptographic Helper Contract | Informational | Solved - 03/24/2026 |
| Incomplete User Data Erasure | Informational | Risk Accepted - 03/25/2026 |
| Excessive Logging of Personal Data | Informational | Solved - 03/24/2026 |
| Missing Revocation Checks in Optional Authentication | Informational | Solved - 03/25/2026 |
| Email Verification Token Validation Does Not Enforce Canonical Encoding | Informational | Solved - 04/03/2026 |
Halborn strongly recommends conducting a follow-up assessment of the project either within six months or immediately following any material changes to the codebase, whichever comes first. This approach is crucial for maintaining the project’s integrity and addressing potential vulnerabilities introduced by code modifications.
// Download the full report
API Pentest + Halborn One Scanner
* Use Google Chrome for best results
** Check "Background Graphics" in the print settings if needed