OasisSwap security record

As of 3 Nov 2026, OasisSwap has 1 audit report on Trustblock, by Quantstamp, dated 8 Aug 2023. That report lists no open critical findings.

Critical findings
No open critical findings
In 1 report.
Open the latest report
Your label, live
Get the label for your site

Record last updated . It holds audits, findings and contracts up to Nov 2026, and incidents up to Oct 2026. Trustblock does not review code.

Audits1

Newest first

AuditSecurity firmDateScopeCritical findingsReport
OasisSwapSecurity firm: QuantstampDate: Scope: Files named in the reportNo open critical findingsOpen · certificate.quantstamp.com

Findings15

Statuses are the security firm’s own, from each report.

SeverityOpenAcknowledgedFixed
Critical000
High000
Medium011
Low265
MediumRebate Estimator Address DesyncOasisSwap · Quantstamp · 8 Aug 2023Fixed

The `OasisSwapFactory` and `OasisSwapRouter` contracts both contain the `setRebateEstimator` function, which allows the setting of the rebate estimator address. However, an update in one does not necessitate an update in the other. There is a possible scenario that both `OasisSwapFactory` and `OasisSwapRouter` contracts will refer to different rebate estimator contracts upon reconfiguration. Having ability to configure the rebate estimator address independently at both contract leads to potential desync issues when calling `OasisSwapFactory.getRebate()` versus `OasisSwapRouter.getRebate()`.

Open the report
LowChecks Effects Interactions Pattern ViolationOasisSwap · Quantstamp · 8 Aug 2023Fixed

The [Checks-Effects-Interactions](https://solidity.readthedocs.io/en/latest/security-considerations.html#use-the-checks-effects-interactions-pattern) coding pattern is meant to mitigate any chance of other contracts manipulating the state of the blockchain in unexpected and possibly malicious ways before control is returned to the original contract. As the name implied, only after checking whether appropriate conditions are met and acting internally on those conditions should any external calls to, or interactions with, other contracts be done. The following instance that violates this pattern has been identified in `OasisSwapPair.withdrawFee()`: ```=304 if (_send0) { _safeTransfer(token0, _to, _toSend0); <-- external call _toSend0 = 0; } if (_send1) { _safeTransfer(token1, _to, _toSend1); <-- external call _toSend1 = 0; } feeCache0 = _toSend0; <-- state change happens after external call feeCache1 = _toSend1; <-- state change happens after external call ``` The severity of this issue has been set to informational, because the re-entrancy guard has been properly implemented throughout the contract, mitigating the issue. However, it's best to adhere to this pattern throughout the code life cycle.

Open the report
LowLoss of Precision Due to Division Before MultiplicationOasisSwap · Quantstamp · 8 Aug 2023Fixed

Division before multiplication may result in a loss of precision when the operations are carried over integer numbers in Solidity. Specifically the following calculations within the internal `_swap` function of the `OasisSwapPair` contract can result in a loss of precision: ``` oasisFee0 = feeTaken0.div(FEE_DIVISOR).mul(_oasisFeeProportion).div(FEE_DIVISOR); oasisFee1 = feeTaken1.div(FEE_DIVISOR).mul(_oasisFeeProportion).div(FEE_DIVISOR); ```

Open the report
LowPragma Solidity UnlockedOasisSwap · Quantstamp · 8 Aug 2023Fixed

Every Solidity file specifies in the header a version number of the format `pragma solidity (^)0.8.*`. The caret (`^`) before the version number implies an unlocked pragma, meaning that the compiler will use the specified version _and above_, hence the term "unlocked".

Open the report
LowSpecification Missmatch in the Growth of KOasisSwap · Quantstamp · 8 Aug 2023Fixed

In a comment on top of the `_mintFee` function of the `OasisSwapPair` contract, it is stated that the function should "mint liquidity equivalent to 1/6th of the growth in sqrt(k)". The code to calculate the amount to mint is different from the specification. There is an example of the formula from the actual code implementation: <img src="https://github.com/pavel-quantstamp/test/blob/main/Screenshot%202023-06-09%20at%2008.35.21.png?raw=true" alt="actual-code-implementation" width="200"/> When there is an example of the formula from technical specification: <img src="https://github.com/pavel-quantstamp/test/blob/main/Screenshot%202023-06-09%20at%2008.31.41.png?raw=true" alt="technical-specification" width="200"/> Therefore, the actual fees in this system are lower than 1/6th of the growth in sqrt(k) because the denominator in the implemented formula is larger than 6 * sqrt(kLast) given sqrt(kLast) < sqrt(k). The code comments stating the function mints liquidity equivalent to "1/6th of the growth in sqrt(k)" are therefore misleading. So, it seems that either the code comments or the code implementation are incorrect, as the two are not consistent. As such, it's important to reconcile the two for accurate understanding and implementation of the desired functionality.

Open the report
LowUser-Specific Fee Calculation in `OasisSwapRouter.getAmountsOut()` and `OasisSwapRouter.getAmountsIn()`OasisSwap · Quantstamp · 8 Aug 2023Fixed

In the current system, functions such as `OasisSwapRouter.getAmountsOut()` and `OasisSwapRouter.getAmountsIn()` have become user-specific. This is because these functions now calculate the fee based on the msg.sender address, which means the results vary depending on the user making the call.

Open the report

Contracts

No deployed address is recorded for these audits.

The reports name a repository or files. Open a report to see its scope.

The repositories and files the reports name

Show this on your site

Is this your project? Show this record on your own website. The label states what the record holds, links to this page and updates by itself. It is free and needs no sign-in.

Content

Facts

Automatic: the three strongest facts of this project’s own record (its last audit and two more), highlighted. They update with the record. Picking a fact turns Automatic off.

Fixed as
Language

Style

Layout
Theme
Accent
Corners

Format

Size
Date
Embed as
HTML
<head>
<script src="https://widget.trustblock.run/project-widget.min.js" defer></script>
</head>
<body>
<div
data-tb-project-widget
data-tb-project-slug="oasisswap-1"
></div>
</body>

Paste the code where the label should appear. It uses no API credit and updates by itself.

Something wrong on this page? A missing report, a wrong date, a finding that was fixed since. Tell us and we check it against its source.

Tell us