ERC-20 & PERC-20
PERC-20 Tokens
We introduce a new type of token β PERC20 (private ERC-20). It has two main differences from regular ERC-20 standards:
default
balanceOf
andallowance
functions are disabled in favor of your own implementation function. You should implement some access control logic or usemsg.sender
to check who sent that call. Ifeth_call
was sent from EOA and was signed, it will recovermsg.sender
from provided signature, otherwise, itmsg.sender
will be empty addressTransfer
andApproval
events are disabled, since they can leak sensitive information
You can find example of PERC-20 contract in the interaction guide: Sample PERC20 contract
EVM Tokensβ
Swisstronik is compatible with ERC-20 tokens and other non-fungible token standards (ERC-721, ERC-1155) that are natively supported by the EVM.
The main problem with the usage of the ERC-20 and other non-modified ERC token standards is that it will disable a lot of functionality such as private transfers and data protection (balance is visible to anyone)
Only OpenZeppelin versions up to 4.9.6 are supported. OpenZeppelin version 5 and above are not supported
Last updated