Skip to content
This repository has been archived by the owner on Jul 6, 2022. It is now read-only.

Commit

Permalink
offering deployment + infura setup with privKey
Browse files Browse the repository at this point in the history
  • Loading branch information
pabloruiz55 committed Feb 25, 2018
1 parent 661bb0b commit 3fc7541
Show file tree
Hide file tree
Showing 23 changed files with 4,708 additions and 108 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Expand Up @@ -5,3 +5,6 @@ coverage/
coverageEnv/
coverage.json
.idea

infura_privKey
infura_apiKey
24 changes: 12 additions & 12 deletions build/contracts/Compliance.json

Large diffs are not rendered by default.

14 changes: 7 additions & 7 deletions build/contracts/Customers.json

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions build/contracts/ICompliance.json
Expand Up @@ -275,10 +275,10 @@
"sourceMap": "",
"deployedSourceMap": "",
"source": "pragma solidity ^0.4.18;\r\n\r\n/*\r\n Polymath compliance protocol is intended to ensure regulatory compliance\r\n in the jurisdictions that security tokens are being offered in. The compliance\r\n protocol allows security tokens remain interoperable so that anyone can\r\n build on top of the Polymath platform and extend it's functionality.\r\n*/\r\n\r\ninterface ICompliance {\r\n\r\n /**\r\n * @dev `setRegistrarAddress` This function set the SecurityTokenRegistrar contract address.\r\n * @param _STRegistrar It is the `this` reference of STR contract\r\n * @return bool\r\n */\r\n\r\n function setRegistrarAddress(address _STRegistrar) public returns (bool);\r\n\r\n /**\r\n * @dev `createTemplate` is a simple function to create a new compliance template\r\n * @param _offeringType The name of the security being issued\r\n * @param _issuerJurisdiction The jurisdiction id of the issuer\r\n * @param _accredited Accreditation status required for investors\r\n * @param _KYC KYC provider used by the template\r\n * @param _details Details of the offering requirements\r\n * @param _expires Timestamp of when the template will expire\r\n * @param _fee Amount of POLY to use the template (held in escrow until issuance)\r\n * @param _quorum Minimum percent of shareholders which need to vote to freeze\r\n * @param _vestingPeriod Length of time to vest funds\r\n */\r\n function createTemplate(\r\n string _offeringType,\r\n bytes32 _issuerJurisdiction,\r\n bool _accredited,\r\n address _KYC,\r\n bytes32 _details,\r\n uint256 _expires,\r\n uint256 _fee,\r\n uint8 _quorum,\r\n uint256 _vestingPeriod\r\n ) public;\r\n\r\n /**\r\n * @dev Propose a bid for a security token issuance\r\n * @param _securityToken The security token being bid on\r\n * @param _template The unique template address\r\n * @return bool success\r\n */\r\n function proposeTemplate(\r\n address _securityToken,\r\n address _template\r\n ) public returns (bool success);\r\n\r\n /**\r\n * @dev Propose a Security Token Offering Contract for an issuance\r\n * @param _securityToken The security token being bid on\r\n * @param _factoryAddress The security token offering contract address\r\n * @return bool success\r\n */\r\n function proposeOfferingFactory(\r\n address _securityToken,\r\n address _factoryAddress\r\n ) public returns (bool success);\r\n\r\n /**\r\n * @dev Cancel a Template proposal if the bid hasn't been accepted\r\n * @param _securityToken The security token being bid on\r\n * @param _templateProposalIndex The template proposal array index\r\n * @return bool success\r\n */\r\n function cancelTemplateProposal(\r\n address _securityToken,\r\n uint256 _templateProposalIndex\r\n ) public returns (bool success);\r\n\r\n /**\r\n * @dev Register the Offering factory by the developer.\r\n * @param _factoryAddress address of the offering factory\r\n * @return bool success\r\n */\r\n function registerOfferingFactory (\r\n address _factoryAddress\r\n ) public returns (bool success);\r\n\r\n /**\r\n * @dev Cancel a Offering factory proposal if the bid hasn't been accepted\r\n * @param _securityToken The security token being bid on\r\n * @param _offeringFactoryProposalIndex The offeringFactory proposal array index\r\n * @return bool success\r\n */\r\n function cancelOfferingFactoryProposal(\r\n address _securityToken,\r\n uint256 _offeringFactoryProposalIndex\r\n ) public returns (bool success);\r\n\r\n /**\r\n * @dev `updateTemplateReputation` is a constant function that updates the\r\n history of a security token template usage to keep track of previous uses\r\n * @param _template The unique template address\r\n * @param _polyRaised Poly raised by template\r\n */\r\n function updateTemplateReputation (address _template, uint256 _polyRaised) external returns (bool success);\r\n\r\n /**\r\n * @dev `updateOfferingReputation` is a constant function that updates the\r\n history of a security token offering contract to keep track of previous uses\r\n * @param _offeringFactory The smart contract address of the STO contract\r\n * @param _polyRaised Poly raised by template\r\n */\r\n function updateOfferingFactoryReputation (address _offeringFactory, uint256 _polyRaised) external returns (bool success);\r\n\r\n /**\r\n * @dev Get template details by the proposal index\r\n * @param _securityTokenAddress The security token ethereum address\r\n * @param _templateIndex The array index of the template being checked\r\n * @return Template struct\r\n */\r\n function getTemplateByProposal(address _securityTokenAddress, uint8 _templateIndex) view public returns (\r\n address _template\r\n );\r\n\r\n /**\r\n * @dev Get security token offering smart contract details by the proposal index\r\n * @param _securityTokenAddress The security token ethereum address\r\n * @param _offeringFactoryProposalIndex The array index of the STO contract being checked\r\n * @return Contract struct\r\n */\r\n function getOfferingFactoryByProposal(address _securityTokenAddress, uint8 _offeringFactoryProposalIndex) view public returns (\r\n address _offeringFactoryAddress\r\n );\r\n}\r\n",
"sourcePath": "/Users/everhusk/Ethereum/Polymath/Core/contracts/interfaces/ICompliance.sol",
"sourcePath": "/Users/pabloruiz55/DocumentsBackup/Polymath/polymath-core/contracts/interfaces/ICompliance.sol",
"ast": {
"attributes": {
"absolutePath": "/Users/everhusk/Ethereum/Polymath/Core/contracts/interfaces/ICompliance.sol",
"absolutePath": "/Users/pabloruiz55/DocumentsBackup/Polymath/polymath-core/contracts/interfaces/ICompliance.sol",
"exportedSymbols": {
"ICompliance": [
4989
Expand Down Expand Up @@ -1695,5 +1695,5 @@
},
"networks": {},
"schemaVersion": "1.0.1",
"updatedAt": "2018-02-25T06:59:38.714Z"
"updatedAt": "2018-02-25T12:43:54.396Z"
}
6 changes: 3 additions & 3 deletions build/contracts/ICustomers.json
Expand Up @@ -178,10 +178,10 @@
"sourceMap": "",
"deployedSourceMap": "",
"source": "pragma solidity ^0.4.18;\n\ninterface ICustomers {\n\n /**\n * @dev Allow new provider applications\n * @param _name The provider's name\n * @param _details A SHA256 hash of the new providers details\n * @param _fee The fee charged for customer verification\n */\n function newProvider(string _name, bytes32 _details, uint256 _fee) public returns (bool success);\n\n /**\n * @dev Change a providers fee\n * @param _newFee The new fee of the provider\n */\n function changeFee(uint256 _newFee) public returns (bool success);\n\n /**\n * @dev Verify an investor\n * @param _customer The customer's public key address\n * @param _countryJurisdiction The country urisdiction code of the customer\n * @param _divisionJurisdiction The subdivision jurisdiction code of the customer\n * @param _role The type of customer - investor:1, delegate:2, issuer:3, marketmaker:4, etc.\n * @param _accredited Whether the customer is accredited or not (only applied to investors)\n * @param _expires The time the verification expires\n */\n function verifyCustomer(\n address _customer,\n bytes32 _countryJurisdiction,\n bytes32 _divisionJurisdiction,\n uint8 _role,\n bool _accredited,\n uint256 _expires,\n uint _nonce,\n uint8 _v,\n bytes32 _r,\n bytes32 _s\n ) public returns (bool success);\n\n ///////////////////\n /// GET Functions\n //////////////////\n\n /**\n * @dev Get customer attestation data by KYC provider and customer ethereum address\n * @param _provider Address of the KYC provider.\n * @param _customer Address of the customer ethereum address\n */\n function getCustomer(address _provider, address _customer) public view returns (\n bytes32,\n bytes32,\n bool,\n uint8,\n uint256\n );\n\n /**\n * Get provider details and fee by ethereum address\n * @param _providerAddress Address of the KYC provider\n */\n function getProvider(address _providerAddress) public view returns (\n string name,\n uint256 joined,\n bytes32 details,\n uint256 fee\n );\n}\n",
"sourcePath": "/Users/everhusk/Ethereum/Polymath/Core/contracts/interfaces/ICustomers.sol",
"sourcePath": "/Users/pabloruiz55/DocumentsBackup/Polymath/polymath-core/contracts/interfaces/ICustomers.sol",
"ast": {
"attributes": {
"absolutePath": "/Users/everhusk/Ethereum/Polymath/Core/contracts/interfaces/ICustomers.sol",
"absolutePath": "/Users/pabloruiz55/DocumentsBackup/Polymath/polymath-core/contracts/interfaces/ICustomers.sol",
"exportedSymbols": {
"ICustomers": [
5065
Expand Down Expand Up @@ -1170,5 +1170,5 @@
},
"networks": {},
"schemaVersion": "1.0.1",
"updatedAt": "2018-02-25T06:59:38.714Z"
"updatedAt": "2018-02-25T12:43:54.419Z"
}
6 changes: 3 additions & 3 deletions build/contracts/IERC20.json
Expand Up @@ -180,10 +180,10 @@
"sourceMap": "",
"deployedSourceMap": "",
"source": "pragma solidity ^0.4.18;\n\n/// ERC Token Standard #20 Interface (https://github.com/ethereum/EIPs/blob/master/EIPS/eip-20-token-standard.md)\ninterface IERC20 {\n function balanceOf(address _owner) public view returns (uint256 balance);\n function transfer(address _to, uint256 _value) public returns (bool success);\n function transferFrom(address _from, address _to, uint256 _value) public returns (bool success);\n function approve(address _spender, uint256 _value) public returns (bool success);\n function allowance(address _owner, address _spender) public view returns (uint256 remaining);\n function totalSupply() public view returns (uint256);\n event Transfer(address indexed _from, address indexed _to, uint256 _value);\n event Approval(address indexed _owner, address indexed _spender, uint256 _value);\n}\n",
"sourcePath": "/Users/everhusk/Ethereum/Polymath/Core/contracts/interfaces/IERC20.sol",
"sourcePath": "/Users/pabloruiz55/DocumentsBackup/Polymath/polymath-core/contracts/interfaces/IERC20.sol",
"ast": {
"attributes": {
"absolutePath": "/Users/everhusk/Ethereum/Polymath/Core/contracts/interfaces/IERC20.sol",
"absolutePath": "/Users/pabloruiz55/DocumentsBackup/Polymath/polymath-core/contracts/interfaces/IERC20.sol",
"exportedSymbols": {
"IERC20": [
5134
Expand Down Expand Up @@ -1072,5 +1072,5 @@
},
"networks": {},
"schemaVersion": "1.0.1",
"updatedAt": "2018-02-25T06:59:38.747Z"
"updatedAt": "2018-02-25T12:43:54.440Z"
}
6 changes: 3 additions & 3 deletions build/contracts/IOfferingFactory.json
Expand Up @@ -68,10 +68,10 @@
"sourceMap": "",
"deployedSourceMap": "",
"source": "pragma solidity ^0.4.18;\n\ninterface IOfferingFactory {\n\n /**\n * @dev It facilitate the creation of the STO contract with essentials parameters\n * @param _startTime Unix timestamp to start the offering\n * @param _endTime Unix timestamp to end the offering\n * @param _polyTokenRate Price of one security token in terms of poly\n * @param _maxPoly Maximum amount of poly issuer wants to collect\n * @return address Address of the new offering instance\n */\n function createOffering(\n uint256 _startTime,\n uint256 _endTime,\n uint256 _polyTokenRate,\n uint256 _maxPoly\n ) public returns (address);\n\n /**\n * @dev `getUsageDetails` is a function to get all the details on factory usage fees\n * @return uint256 fee, uint8 quorum, uint256 vestingPeriod, address owner, string description\n */\n function getUsageDetails() view public returns (uint256, uint8, uint256, address, bytes32);\n\n}\n",
"sourcePath": "/Users/everhusk/Ethereum/Polymath/Core/contracts/interfaces/IOfferingFactory.sol",
"sourcePath": "/Users/pabloruiz55/DocumentsBackup/Polymath/polymath-core/contracts/interfaces/IOfferingFactory.sol",
"ast": {
"attributes": {
"absolutePath": "/Users/everhusk/Ethereum/Polymath/Core/contracts/interfaces/IOfferingFactory.sol",
"absolutePath": "/Users/pabloruiz55/DocumentsBackup/Polymath/polymath-core/contracts/interfaces/IOfferingFactory.sol",
"exportedSymbols": {
"IOfferingFactory": [
5163
Expand Down Expand Up @@ -462,5 +462,5 @@
},
"networks": {},
"schemaVersion": "1.0.1",
"updatedAt": "2018-02-25T06:59:38.746Z"
"updatedAt": "2018-02-25T12:43:54.440Z"
}
6 changes: 3 additions & 3 deletions build/contracts/ISecurityToken.json
Expand Up @@ -291,10 +291,10 @@
"sourceMap": "",
"deployedSourceMap": "",
"source": " pragma solidity ^0.4.18;\n\n interface ISecurityToken {\n\n /**\n * @dev `selectTemplate` Select a proposed template for the issuance\n * @param _templateIndex Array index of the delegates proposed template\n * @return bool success\n */\n function selectTemplate(uint8 _templateIndex) public returns (bool success);\n\n /**\n * @dev Update compliance proof hash for the issuance\n * @param _newMerkleRoot New merkle root hash of the compliance Proofs\n * @param _complianceProof Compliance Proof hash\n * @return bool success\n */\n function updateComplianceProof(\n bytes32 _newMerkleRoot,\n bytes32 _complianceProof\n ) public returns (bool success);\n\n /**\n * @dev `selectOfferingFactory` Select an security token offering proposal for the issuance\n * @param _offeringFactoryProposalIndex Array index of the STO proposal\n * @return bool success\n */\n function selectOfferingFactory (\n uint8 _offeringFactoryProposalIndex\n ) public returns (bool success);\n\n /**\n * @dev Start the offering by sending all the tokens to STO contract\n * @param _startTime Unix timestamp to start the offering\n * @param _endTime Unix timestamp to end the offering\n * @param _polyTokenRate Price of one security token in terms of poly\n * @param _maxPoly Maximum amount of poly issuer wants to collect\n * @param _lockupPeriod Length of time raised POLY will be locked up for dispute\n * @param _quorum Percent of initial investors required to freeze POLY raise\n * @return bool\n */\n function initialiseOffering(uint256 _startTime, uint256 _endTime, uint256 _polyTokenRate, uint256 _maxPoly, uint256 _lockupPeriod, uint8 _quorum) external returns (bool success);\n\n /**\n * @dev Add a verified address to the Security Token whitelist\n * @param _whitelistAddress Address attempting to join ST whitelist\n * @return bool success\n */\n function addToWhitelist(address _whitelistAddress) public returns (bool success);\n\n /**\n * @dev Add verified addresses to the Security Token whitelist\n * @param _whitelistAddresses Array of addresses attempting to join ST whitelist\n * @return bool success\n */\n function addToWhitelistMulti(address[] _whitelistAddresses) public returns (bool success);\n\n /**\n * @dev Removes a previosly verified address to the Security Token blacklist\n * @param _blacklistAddress Address being added to the blacklist\n * @return bool success\n */\n function addToBlacklist(address _blacklistAddress) public returns (bool success);\n\n /**\n * @dev Removes previously verified addresseses to the Security Token whitelist\n * @param _blacklistAddresses Array of addresses attempting to join ST whitelist\n * @return bool success\n */\n function addToBlacklistMulti(address[] _blacklistAddresses) public returns (bool success);\n\n /**\n * @dev Allow POLY allocations to be withdrawn by owner, delegate, and the STO auditor at appropriate times\n * @return bool success\n */\n function withdrawPoly() public returns (bool success);\n\n /**\n * @dev Vote to freeze the fee of a certain network participant\n * @param _recipient The fee recipient being protested\n * @return bool success\n */\n function voteToFreeze(address _recipient) public returns (bool success);\n\n /**\n * @dev `issueSecurityTokens` is used by the STO to keep track of STO investors\n * @param _contributor The address of the person whose contributing\n * @param _amountOfSecurityTokens The amount of ST to pay out.\n * @param _polyContributed The amount of POLY paid for the security tokens.\n */\n function issueSecurityTokens(address _contributor, uint256 _amountOfSecurityTokens, uint256 _polyContributed) public returns (bool success);\n\n /// Get token details\n function getTokenDetails() view public returns (address, address, bytes32, address, address, address);\n\n /// Get token decimals\n function decimals() view public returns (uint8);\n }\n",
"sourcePath": "/Users/everhusk/Ethereum/Polymath/Core/contracts/interfaces/ISecurityToken.sol",
"sourcePath": "/Users/pabloruiz55/DocumentsBackup/Polymath/polymath-core/contracts/interfaces/ISecurityToken.sol",
"ast": {
"attributes": {
"absolutePath": "/Users/everhusk/Ethereum/Polymath/Core/contracts/interfaces/ISecurityToken.sol",
"absolutePath": "/Users/pabloruiz55/DocumentsBackup/Polymath/polymath-core/contracts/interfaces/ISecurityToken.sol",
"exportedSymbols": {
"ISecurityToken": [
5279
Expand Down Expand Up @@ -1787,5 +1787,5 @@
},
"networks": {},
"schemaVersion": "1.0.1",
"updatedAt": "2018-02-25T06:59:38.749Z"
"updatedAt": "2018-02-25T12:43:54.442Z"
}
6 changes: 3 additions & 3 deletions build/contracts/ISecurityTokenRegistrar.json
Expand Up @@ -76,10 +76,10 @@
"sourceMap": "",
"deployedSourceMap": "",
"source": "pragma solidity ^0.4.18;\r\n\r\ninterface ISecurityTokenRegistrar {\r\n\r\n /**\r\n * @dev Creates a new Security Token and saves it to the registry\r\n * @param _nameSpace Name space for this security token\r\n * @param _name Name of the security token\r\n * @param _ticker Ticker name of the security\r\n * @param _totalSupply Total amount of tokens being created\r\n * @param _owner Ethereum public key address of the security token owner\r\n * @param _type Type of security being tokenized\r\n */\r\n function createSecurityToken (\r\n string _nameSpace,\r\n string _name,\r\n string _ticker,\r\n uint256 _totalSupply,\r\n uint8 _decimals,\r\n address _owner,\r\n uint8 _type\r\n ) external;\r\n\r\n /**\r\n * @dev Get Security token details by its ethereum address\r\n * @param _STAddress Security token address\r\n */\r\n function getSecurityTokenData(address _STAddress) public view returns (\r\n string,\r\n string,\r\n address,\r\n uint8\r\n );\r\n\r\n}\r\n",
"sourcePath": "/Users/everhusk/Ethereum/Polymath/Core/contracts/interfaces/ISecurityTokenRegistrar.sol",
"sourcePath": "/Users/pabloruiz55/DocumentsBackup/Polymath/polymath-core/contracts/interfaces/ISecurityTokenRegistrar.sol",
"ast": {
"attributes": {
"absolutePath": "/Users/everhusk/Ethereum/Polymath/Core/contracts/interfaces/ISecurityTokenRegistrar.sol",
"absolutePath": "/Users/pabloruiz55/DocumentsBackup/Polymath/polymath-core/contracts/interfaces/ISecurityTokenRegistrar.sol",
"exportedSymbols": {
"ISecurityTokenRegistrar": [
5312
Expand Down Expand Up @@ -522,5 +522,5 @@
},
"networks": {},
"schemaVersion": "1.0.1",
"updatedAt": "2018-02-25T06:59:38.748Z"
"updatedAt": "2018-02-25T12:43:54.443Z"
}

0 comments on commit 3fc7541

Please sign in to comment.