Skip to content

seedbloom/uport-identity

 
 

Repository files navigation

uPort Identity Contracts

Please read our Whitepaper for information on what uPort is, and what is currently possible as far as integration.

Contract Deployments

Mainnet (id: 1)

Contract Address
ArrayLib 0x5bfa4582b0c48cb375b9e8322b57ac025965c148
IdentityFactory 0x12e627125abcfa989de831572f198577780d7127
IdentityFactoryWithRecoveryKey (not deployed)

Ropsten testnet (id: 3)

Contract Address
ArrayLib 0x957eb298a72167367fa210fc1aa3faba1d2b629c
IdentityFactory 0x1c9d9e1962985c9b8101777cae25c46279fe2a9c
IdentityFactoryWithRecoveryKey 0xb7d66b18fbe8eb655ce7daa5d616d908c25c32a7

Rinkeby testnet (id: 4)

Contract Address
ArrayLib 0xb8a00506e12d39522cd1787389ae8f83db536e46
IdentityFactory 0x6a841ba0ea1a88cfbc085220fc6b65973afca431
IdentityFactoryWithRecoveryKey 0xd7dc3926bc6089a5be4815215ceaa6e707591023

Kovan testnet (id: 42)

Contract Address
ArrayLib 0x6a841ba0ea1a88cfbc085220fc6b65973afca431
IdentityFactory 0xd7dc3926bc6089a5be4815215ceaa6e707591023
IdentityFactoryWithRecoveryKey 0xdc420f5d89ef5c729c63cf05b0ceda364d5a8b1d

Using the contracts

To use the contract we provide truffle artifacts. You can use truffle-contract to utilize these.

const uportIdentity = require('uport-identity')
const Contract = require('truffle-contract')

let IdentityFactory = Contract(uportIdentity.IdentityFactory)
let identityFactory = IdentityFactory.deployed()

You can also use web3.

let networkId = 1
let IdentityFactory = web3.eth.contract(uportIdentity.IdentityFactory.abi)
let identityFactory = IdentityFactory.at(uportIdentity.IdentityFactory.networks[networkId].address)

Contracts

This repository contains the contracts currently in use by uPort. This is also where you find the addresses of these contracts currently deployed on Ropsten and Mainnet.

IdentityFactory

A factory that creates new identities with a Proxy, RecoverableController and RecoveryQuorum.

IdentityFactoryWithRecoveryKey

A factory that creates new identities with a Proxy and RecoverableController.

Proxy

This is the main identity contract. All your transactions are forwarded through this contract which acts as your persistent identifier.

RecoverableController

This is a controller which plugs in to the proxy contract. It gives you the ability to have one key that can make transactions through the proxy, but can't change the owner of the proxy, and another key that acts as a recovery key that can change the owner of the proxy. This gives you the ability to store a recovery key in cold storage while you can use your main key for regular transactions. If your main key is lost you can change it using the recovery key from cold storage.

RecoveryQuorum

This contract plugs into the RecoverableController to provide recovery with a n-of-m setup. This allows for creating recovery networks consisting of your friends.

ArrayLib

A library for finding and removing addresses in arrays.

Contributing

Want to contribute to uport-contracts? Cool, please read our contribution guidelines to get an understanding of the process we use for making changes to this repo.

About

uPort Contracts for managing identity

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 99.8%
  • Shell 0.2%