Smart Contracts
Overview & Contract Addresses
Code Repository
https://github.com/superstateinc/ustb/tree/main
Audits
Contract Addresses
Allowlist Proxy - https://etherscan.io/address/0x42d75c8fdbbf046df0fe1ff388da16ff99de8149
USTB Token Proxy - https://etherscan.io/address/0x43415eB6ff9DB7E26A15b704e7A3eDCe97d31C4e
USCC Token Proxy - https://etherscan.io/address/0x14d60e7fdc0d71d8611742720e4c50e7a974020c
Chainlink USTB Oracle - https://etherscan.io/address/0x289B5036cd942e619E1Ee48670F98d214E745AAC
Chainlink USCC Oracle - https://etherscan.io/address/0xAfFd8F5578E8590665de561bdE9E7BAdb99300d9
Our smart contracts are upgradable and various functions are gated behind the Superstate Admin Address calling them. This includes all minting, adding or removing users from the allowlist, and forcibly burning an investor’s tokens (if required by exogenous legal circumstances, for example).
USTB and USCC
A standard Upgradable OpenZeppelin ERC-20 implementation with a few changes:
USTB/USCC check that all holders are on the Superstate controlled Allowlist contract and are authorized for that token.
Encumber functionality (see below)
Burn - Investors can call the
burn
function or transfer their USTB/USCC to the contract address to kick off a redemptionMint - Superstate can call the
mint
function to mint new shares of USTB/USCC when investors subscribe to the fund
Transfers
USTB/USCC is freely transferrable between Ethereum addresses that are on the Allowlist via transfer
or transferFrom
. Each function checks that the sender and receiver are both on the Allowlist and authorized for that specific token.
Allowlist
Adds/Removes Ethereum addresses to/from the allowlist with certain permissions. Right now, only the first two booleans in the Permission
struct are used. Permission.isAllowed
means the entity is onboarded to USTB. Permission.state1
means the entity is onboarded to USCC.
Ethereum addresses are also grouped by their Entity Id. Entity Ids are how Superstate identifies investors.
The USTB/USCC token contract calls getPermission
on the Allowlist contract to see if the sender and receiver of USTB are allowed to hold it.
Only the Superstate Admin Address can make any changes to the allowlist, using the following functions setEntityIdForAddress
, setEntityIdForMultipleAddresses
, setPermission
, setEntityPermissionAndAddresses
, and setNthPermission
. We call these functions when onboarding or offboarding an investor.
We only add Ethereum addresses for investors that have made it through our KYC / Investment Agreement processes.
Chainlink USTB Oracle
Chainlink puts the USTB Net Asset Value per Share price onchain once per day. The Oracle contract uses the AggregatorV3Interface.https://docs.chain.link/data-feeds/api-reference#functions-in-aggregatorv3interface
This oracle has the daily USTB NAV/S price and can be used like any other Chainlink oracle.
Last updated