Giter Site home page Giter Site logo

acostarodrigo / simple-restricted-token Goto Github PK

View Code? Open in Web Editor NEW

This project forked from simple-restricted-token/simple-restricted-token

0.0 1.0 0.0 168 KB

ERC-1404: An easily extendable standard for issuing tokens with transfer restrictions

Home Page: https://erc1404.org

JavaScript 100.00%

simple-restricted-token's Introduction

Simple Restricted Token Standard

An easily extendable standard for issuing tokens with transfer restrictions.

Read ERC-1404 to learn more.

For Developers

Use of the standard lends to writing small, reusable smart contracts that are responsible for enforcing a single transfer restriction pattern.

Tokens implementing the standard are best constructed by composing said restrictions through multiple contract inheritance.

For Lawyers

You may have been seeking a way for your issuers to enforce investor limits, control flowback between US and non-US investors, or other similar restrictions.

The standard provides an avenue by which a team of capable engineers may meet those requirements.

For Issuers

Your counsel may have asked you questions similar to the following:

  • "How can we limit the number of token holders to 2,000 persons or less?"
  • "How can we prevent flowback from non-US token holders to US token holders?"
  • "What if a sanctioned persons gets a hold of the token? Can you take it away?"

While this standard does not inherently enable compliance, it does provide the tools necessary to comply with requirements as put forth by counsel.

The Standard

The standard builds on ERC-20's interface, adding two functions:

// The Simple Restricted Token Standard Interface

contract ERC1404 is ERC20 {
  // returns a restriction code, where 0 is reserved for success
  function detectTransferRestriction (address from, address to, uint256 value) public view returns (uint8);

  // returns a messsage string -- a human-readable message for the passed restriction code 
  function messageForTransferRestriction (uint8 restrictionCode) public view returns (string);
}

Examples

Common Restricted Tokens

Below are several common transfer restriction patterns implemented on ERC-1404.

These contracts are fully composable with each other. Inherit from one or several to build out a bespoke restricted token contract.

  1. Account Ownership Percentage
  2. Account Holding Periods - WIP
  3. Number of Accounts
  4. Account Whitelists
  5. Token Divisibility

Other Standards

We have included example implementations of the following high-profile standards proposals on top of ERC-1404:

  1. Polymath's ST-20 Token
  2. Harbor's R-Token
  3. Delaware General Corporations Law (DGCL) ERC-884 Token - WIP

simple-restricted-token's People

Contributors

masonicgit avatar youfoundron avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.