Smart Contracts

Overview & Contract Addresses

Code Repository

https://github.com/superstateinc/ustb/tree/main

Audits

Contract Addresses

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:

  1. USTB/USCC check that all holders are on the Superstate controlled Allowlist contract and are authorized for that token.

  2. Encumber functionality (see below)

  3. Burn - Investors can call the burn function or transfer their USTB/USCC to the contract address to kick off a redemption

  4. Mint - 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 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