CertiK reviewed BackedBy (BackedBy - Audit) on 4 Jan 2023: 6 findings, 0 critical; 5 marked fixed, 1 acknowledged.
Report hosted on skynet.certik.com.
Trustblock does not review code.
Statuses are the security firm’s own, from its report.
| Severity | Open | Acknowledged | Fixed |
|---|---|---|---|
| Critical | 0 | 0 | 0 |
| High | 0 | 1 | 1 |
| Medium | 0 | 0 | 0 |
| Low | 0 | 0 | 4 |
There is an issue with the current logic for updating the `_ownedProfiles` mapping within the `editProfile()` code for the original owner when ownership transfers occur. The current logic sets the final index of the `_ownedProfiles` mapping of the original owner to the `profileId` of the profile that is being set to change owners: ```solidity=97 _ownedProfiles[msg.sender][_ownersTotalProfiles[msg.sender] - 1] = _ownedProfiles[msg.sender][_ownedProfilesIndexes[msg.sender][profileId]]; ``` This line of code overwrites the last profile index of the caller's `_ownedProfiles` mapping to the profile that is being transferred to the new owner. This means that the profile that is supposed to be transferred remains in the caller's mapping and even overwrites the caller's last active profile. This would also have an impact when `getOwnersProfiles()` is run since the `profileId` that is being transferred is still being shown under the previous owner in the `_ownedProfiles` mapping.
The current logic for `performUpKeep()` might result in the function reverting after a series of updates and payments, which will be a waste of gas, and updates will need to be executed again from the beginning. The issue is mainly related to the two require statements as shown below: ```solidity=95 require(_subscriptions[renewIndexes[i]].expiration < block.timestamp, BBErrorCodesV01.SUBSCRIPTION_NOT_EXPIRED); require(_subscriptions[renewIndexes[i]].cancelled == false, BBErrorCodesV01.SUBSCRIPTION_CANCELLED); ```
The design currently allows anyone to run the `deploySubscriptions()` function and set a subscription to allow any valid currency contract address. This might allow attackers to use malicious contracts included as a `currency` contract.
For both functions `checkUpkeep()` and `performUpkeep()` there is no checking of the parameters decoded from the input data. Specifically for sensitive information like the `renewIndexes` and `refundReceiver` addresses, it would be useful to have a check to ensure that valid input values have been submitted into the function.
The two loops within function `checkUpKeep()` are essentially looping through the same values twice.
The report names a repository or files. Open the report to see its scope.
Repository and files the report names (13)
1,044 projects reviewed · 1,375 reports · latest May 2025
See CertiK’s auditsSomething 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