ERC20
This contract is an ERC20 token.
Name
Civic
Symbol
CVC
Decimals
8
Total Supply
1,000,000,000 CVC
About
link
description
### What is CVC?
The CVC token is intended to be used to incentivize stakeholders to participate and behave correctly in the Identity.com marketplace as described in the CVC white paper. Identity.com owns the CVC utility token and the Identity.com marketplace.
Identity.com is the leading identity-verification nonprofit providing an open-source, decentralized ecosystem. It also provides a marketplace focusing on verifying credentials rather than exchanging personally identifiable information. Together with Identity.com, companies and developers may create convenient, on-demand identity verification solutions that offer consumers more control over their digital identities.
Identity.com’s first partner is Civic Technologies, which provides consumers with a safer, easier way to transact via Civic Wallet, a non-custodial, multisig digital wallet. Civic uses Identity.com's open-source, blockchain-based ecosystem to verify credentials.
### How can you buy CVC?
You may buy CVC at supporting exchanges, and a full list is available on the Market Pairs tab.
### How can you store CVC?
You may store CVC at a supporting exchange, in a hot or cold storage wallet, or in Civic Wallet.
Stats
Public Functions
12
Event Types
6
Code Size
10,909 bytes
Events (6) keyboard_arrow_up
Functions
balanceOf keyboard_arrow_up
allowance keyboard_arrow_up
transfer keyboard_arrow_up
Source Code
function transfer(address _to, uint _value) returns (bool success) {
balances[msg.sender] = safeSub(balances[msg.sender], _value);
balances[_to] = safeAdd(balances[_to], _value);
Transfer(msg.sender, _to, _value);
return true;
}
transferFrom keyboard_arrow_up
Source Code
function transferFrom(address _from, address _to, uint _value) returns (bool success) {
uint _allowance = allowed[_from][msg.sender];
balances[_to] = safeAdd(balances[_to], _value);
balances[_from] = safeSub(balances[_from], _value);
allowed[_from][msg.sender] = safeSub(_allowance, _value);
Transfer(_from, _to, _value);
return true;
}
approve keyboard_arrow_up
Requirements help
One or more of the following:
Source Code
function approve(address _spender, uint _value) returns (bool success) {
// To change the approve amount you first have to reduce the addresses`
// allowance to zero by calling `approve(_spender, 0)` if it is not
// already 0 to mitigate the race condition described here:
// https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
if ((_value != 0) && (allowed[msg.sender][_spender] != 0)) throw;
allowed[msg.sender][_spender] = _value;
Approval(msg.sender, _spender, _value);
return true;
}
isToken keyboard_arrow_up
upgrade keyboard_arrow_up
Source Code
function upgrade(uint256 value) public {
UpgradeState state = getUpgradeState();
if(!(state == UpgradeState.ReadyToUpgrade || state == UpgradeState.Upgrading)) {
// Called in a bad state
throw;
}
// Validate input value.
if (value == 0) throw;
balances[msg.sender] = safeSub(balances[msg.sender], value);
// Take tokens out from circulation
totalSupply = safeSub(totalSupply, value);
totalUpgraded = safeAdd(totalUpgraded, value);
// Upgrade agent reissues the tokens
upgradeAgent.upgradeFrom(msg.sender, value);
Upgrade(msg.sender, upgradeAgent, value);
}
setUpgradeAgent keyboard_arrow_up
Requirements help
Source Code
function setUpgradeAgent(address agent) external {
if(!canUpgrade()) {
// The token is not yet in a state that we could think upgrading
throw;
}
if (agent == 0x0) throw;
// Only a master can designate the next agent
if (msg.sender != upgradeMaster) throw;
// Upgrade has already begun for an agent
if (getUpgradeState() == UpgradeState.Upgrading) throw;
upgradeAgent = UpgradeAgent(agent);
// Bad interface
if(!upgradeAgent.isUpgradeAgent()) throw;
// Make sure that token supplies match in source and target
if (upgradeAgent.originalSupply() != totalSupply) throw;
UpgradeAgentSet(upgradeAgent);
}
getUpgradeState keyboard_arrow_up
Parameters help
This function has no parameters.
Source Code
function getUpgradeState() public constant returns(UpgradeState) {
if(!canUpgrade()) return UpgradeState.NotAllowed;
else if(address(upgradeAgent) == 0x00) return UpgradeState.WaitingForAgent;
else if(totalUpgraded == 0) return UpgradeState.ReadyToUpgrade;
else return UpgradeState.Upgrading;
}
setUpgradeMaster keyboard_arrow_up
Requirements help
Source Code
function setUpgradeMaster(address master) public {
if (master == 0x0) throw;
if (msg.sender != upgradeMaster) throw;
upgradeMaster = master;
NewUpgradeMaster(upgradeMaster);
}
canUpgrade keyboard_arrow_up
setTokenInformation keyboard_arrow_up
Requirements help
Source Code
function setTokenInformation(string _name, string _symbol) {
if(msg.sender != upgradeMaster) {
throw;
}
if(bytes(name).length > 0 || bytes(symbol).length > 0) {
// Information already set
// Allow owner to set this information only once
throw;
}
name = _name;
symbol = _symbol;
UpdatedTokenInformation(name, symbol);
}