Questions tagged [zeppelin]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
1
vote
2answers
47 views

SafeMath and user input: it's always possible to overflow/underflow. No way out?

SafeMath doesn't prevent overflow/underflow from user input. Example: function sub(uint8 a, uint8 b) public returns(uint8) { require(b <= a); uint8 c = a - b; return c; } Say the user ...
0
votes
1answer
41 views

Is it ok to build app with huge data in ethereum blockchain

I agree that the smart contract works well for small Apps. Is it ok to develop a app with huge data. For this let us take an example of building a huge patient database across hospitals (only with key ...
3
votes
2answers
240 views

Zeppelin OS: revert Cannot call fallback function from the proxy admin

I have been attempting to create a simple upgradable contract using Zeppelin OS: Following the tutorial I have been able to: - Create a new contract - Deploy it using zos push - Create the proxy ...
6
votes
1answer
109 views

Does OpenZeppelin make security audits? [closed]

Does the OpenZeppelin project offer security audit services for other projects and companies?
0
votes
1answer
48 views

While compiling contract i got an error “Error: Could not find path from any sources; imported from path”

pragma solidity ^0.4.22; import './NewToken.sol'; import 'zeppelin-solidity/contracts/crowdsale/emission/MintedCrowdsale.sol'; import 'zeppelin-solidity/contracts/crowdsale/validation/...
2
votes
2answers
83 views

bool side = coinFlip == 1 ? true : false;

I'm currently attempting to solve the Coinflip challenge by Ethernaut and I have trouble understanding the following line of code (after ==): bool side = coinFlip == 1 ? true : false; I can't seem ...
0
votes
2answers
123 views

Create and Run an AllowanceCrowdSale With Zeppelin-OS Contracts

I use the openzeppelin library: https://github.com/OpenZeppelin/openzeppelin-solidity/tree/v1.12.0 token I create a BurnableToken: pragma solidity 0.4.24; import 'openzeppelin-solidity/contracts/...
1
vote
1answer
83 views

OpenZeppelin MintableToken error only on private network

I started a new private network by geth command. geth --networkid "198" --nodiscover --datadir "~/test-geth" --rpc --rpcaddr "0.0.0.0" --rpcport "8545" --rpccorsdomain "*" --rpcvhosts "*" --rpcapi ...
2
votes
1answer
124 views

Created Crowdsales contract, sending ropsten ETH to the contract and Failed

I created crowdsale contract - https://ropsten.etherscan.io/address/0xfbb2759ef0b7169d0a2effa971845ea0f99f87b1 My token - https://ropsten.etherscan.io/token/0x0f26c1c05f1bbBC7Eff0488F1a98619e8a9758cf ...
1
vote
2answers
404 views

zeppelinSales contract constructor expected 3 arguments, received 0

I am trying to deploy Crowdsale contract, but when I do "truffle migrate --network ropsten" I get these errors: Running migration: 1_initial_migration.js Deploying Migrations... ... ...
1
vote
1answer
54 views

Error encountered, bailing. Network state unknown. Review successful transactions manually. exceeds block gas limit

I am trying to deploy my crowdsale contract using "truffle migrate --network ropsten". I encounter this problem "Error encountered, bailing. Network state unknown. Review successful transactions ...
2
votes
2answers
1k views

Type address is not implicitly convertible to expected type contract ERC20

I am trying to compile my crowdsale contract and get this error: " TypeError: Type address is not implicitly convertible to expected type contract ERC20. token = ...
2
votes
2answers
1k views

How do I import from / install OpenZeppelin properly?

I'm a newb dev and want to play with smart contracts, and was trying to figure this out. Ive installed truffle and openzeppelin, everything seems to check out, but in Mist I still get an error when I ...
3
votes
2answers
131 views

Openzeppelin ERC20/StandardToken.sol changes some state variable to private

I made token based on Openzeppelin ERC20. Few days before, StandardToken.sol which I imported changed some of its state variables(total supply_, balances) from internal to private. github history ...
0
votes
1answer
104 views

Is the Truffle Migrations contract the same as OpenZeppelin's Ownable?

Please help me to understand what the Migrations contract in the truffle suite does. Are we supposed to inherit from it? What if I'm using OpenZepp's Ownable? Or does this file allow for long term ...
0
votes
1answer
101 views

Created Standard Token, deployed successfully but on Myetherwallet error

Here is the token contract I created - https://ropsten.etherscan.io/address/0x2cccce414fcdf028c0574766af4302a4abeb5788 Address: 0x2CCcCe414FCdF028C0574766Af4302A4aBEB5788 For some reason I can not ...
2
votes
2answers
82 views

The contract code couldn't be stored, please check your gas amount. [Zeppelin, Truffle.js, Ropsten]

I am having some problem with deploying the simple Token Contract to Ropsten network. Error is "The contract code couldn't be stored, please check your gas amount". I tried to change Gas values ...
1
vote
1answer
399 views

DeclarationError: Identifier already declared. Two imports import the same ERC721 contract

Im building a contract that uses two contracts that both use the ERC721 zeppelin contract, when I import the two as such: import nonFungableWidthAddedFunctionality1.sol; import ...
0
votes
1answer
41 views

When extending a contract how to call the external constructor and pass parameters?

I have the following contract import "zeppelin-solidity/contracts/token/ERC721/ERC721Token.sol"; contract Contract is ERC721Token { function Contract(string _name, string _symbol) public { ...
0
votes
1answer
238 views

Truffle react with Proxy Contract of OpenZeppelin

Is it possible to create a react app with truffle framework using the Proxy Contract of OpenZeppelin for upgradable contract? What I understood is that one should send a transaction at Proxy ...
0
votes
1answer
143 views

Cannot deploy contact to ropsten via remix

I'm trying to deploy a token contract and a crowdsale contract via Remix on Ropsten. However I am running into trouble. Below are both of my smart contracts and an explanation of what is happening. ...
1
vote
0answers
144 views

How to Deploy non-Migratable Contract in Zeppelin OS?

I am using Zeppelin OS to create a migratable contract MyContract, which will be imported into another contract Foo. Foo calls the baz() function of MyContract, so when MyContract is upgraded, Foo ...
0
votes
1answer
213 views

SenTransaction can't send Ether to a contract address

I am using openzeppelin, Ganache and truffle, here's a very simple smart contract for fundraising: pragma solidity 0.4.24; import 'openzeppelin-solidity/contracts/crowdsale/Crowdsale.sol'; contract ...
2
votes
1answer
99 views

Correct way to transfer ERC-20 tokens and keeping decimals in count?

I have a token with 18 decimals, I'm using the OpenZeppelin StandardToken example and have figured out that when I want to send value I have to keep the decimals in count as such: _value * 10**...
1
vote
1answer
162 views

How do OpenZeppelin ERC721 tests pass?

I don't understand how the following test can pass. I tried it in my application and it fails. The entry point is the description 'when called by the owner'. In this function two test cases are ...
0
votes
1answer
64 views

Can a smart contract be set up so that a function to forward funds sends a set percentage of the Ether received to 2 or more contracts?

For example the the openzeppelin crowdsale contract has a function that sends ether to a wallet address. Could this method include logic to send 60% of the funds received to Alice's wallet and 40% to ...
0
votes
1answer
120 views

Does an ERC721 contract have to rely on an external agent to be the approved spender?

I am creating a dApp that services a game. The "house" in the game is my game server that creates the smart contract using Web3.js. It also owns all the non-fungible assets at the start of the game, ...
3
votes
1answer
515 views

What's the point of ERC721Receiver.sol and ERC721Holder.sol in OpenZeppelin's implementation?

I'm studying OpenZeppelin's ERC721 token implementation and I'm having a hard time making sense of ERC721Receiver.sol and ERC721Holder.sol and how they relate to eachother. In the file ...
1
vote
1answer
134 views

Help with inheritance and Truffle tests

I have two contracts that both inherit from OpenZeppelin's Whitelist. After deploying both contracts, I use an instance of the first contract to add a "trusted" address to the whitelist. Since both ...
1
vote
1answer
205 views

On the unstructured storage upgrade pattern, why do we have to follow the structure of the previous contract?

ZeppelinOS has adopted the unstructured storage proxy pattern to upgrade contracts. In the blog post that introduces this pattern, they say: "The only thing you will have to care about is that ...
0
votes
1answer
65 views

What happens with the balance of a contract after it is upgraded using ZeppelinOS?

ZeppelinOS implements upgradeability of smart contracts through the use of a proxy and unstructured storage. If the contract holds some ether, what happens with that ether after it is upgraded?
4
votes
2answers
730 views

Solidity Error: Exceeds block gas limit

When I start ganache-cli in one terminal window and run ./node_modules/.bin/solidity-coverage (command from documentation) in another I get Error: Exceeds block gas limit at Object....
0
votes
1answer
212 views

Correct Open Zeppelin contract for external agent contract that handles sales logic on behalf of an ERC721 contract?

I just finished this article on the Open Zeppelin ERC721 token implementation: https://medium.com/blockchannel/walking-through-the-erc721-full-implementation-72ad72735f3c I about to start ...
1
vote
1answer
330 views

Error parsing … ParsedContract.sol:33:18: ParserError: Expected token Semicolon got 'LParen'

When compiling my contract code in truffle I receive this error: Error parsing zeppelin-solidity/contracts/token/ERC20/StandardToken.sol: ParsedContract.sol:33:18: ParserError: Expected token ...
1
vote
2answers
515 views

SafeMath library vs SafeMath contract on the inheritance chain

guys, I am developing ERC-20 token and I am wondering why SafeMath is used as as library in the OpenZeppelin implementation? Will not it be more optimal if we supply it as a base contract on the ...
1
vote
1answer
215 views

Multiple timelocks on wallets in contract

I am developing an ERC20 token which needs to have a timelock on a certain wallet that unlocks a certain amount of tokens every month. I am currently using the openzeppelin function: function ...
0
votes
1answer
79 views

Can't use token variable's method at contract that inherit zeppelin crowdsale?

Calling the method of Crowdsale's "token" on the source that inherited Crowdsale of zeppelin v1.8.0 inevitably causes "out of gas". Error: Error: VM Exception while executing eth_call: out of gas ...
1
vote
1answer
59 views

zeppelin-solidity: WhyHasNoEther contract prevent accidental loss of Ether

I am writing smart contract. I am looking for Zeppelin with many helpful methods. But there is one contract that I don't understand named HasNoEther. pragma solidity ^0.4.18; import "./Ownable.sol"; ...
2
votes
1answer
135 views

How do investors get refund when `RefundableCrowdsale` does not reach its goal?

Question regarding RefundableCrowdsale of OpenZeppelin. When its goal isn't reached, how do investors get refund? By calling the claimRefund() method? How do they call the method??
0
votes
1answer
51 views

Chicken-Egg Problem when I deploy a Crowdsale with Standard Token

I just try to implement a standard token with a basic crowdsale from open zeppelin. I have everything up and running but the transaction always reverts and I tracked it down to this line: token....
2
votes
1answer
291 views

TypeError: Member “mint” not found or not visible after argument-dependent lookup in contract ERC20

token.mint(beneficiary, tokens) prevents code from fully compiling using Zeppelin 1.8. Casting your token as a MintableToken* solves this issue and allows your code to compile: MintableToken token = ...
1
vote
1answer
668 views

OpenZeppelin - how to check the owner's address of an Ownable token

Please excuse this basic question, as I am quite new to this. I created a sample token using OpenZeppelin framework. The token class inherits MintableToken which in turn inherits Ownable. This class ...
0
votes
2answers
279 views

Crowdsale with time based bonus

I'm working with the OpenZeppelin solidity framework to run a crowdsale script, but would like to ask, is there is an existing open source solution for implementing time-based bonus payouts?
0
votes
1answer
111 views

Example IncreasingPriceCrowdsale

Who can give a working example IncreasingPriceCrowdsale or or find error in my code: contract TestCrowdsale is IncreasingPriceCrowdsale, MintedCrowdsale { function TestCrowdsale( uint256 ...
0
votes
1answer
217 views

what is meant by minted crowdsales?

I am new to ethereum smart contracts, I was going through minted crowdsale code for learning but couldn't figured out its use case or what is its purpose, precisely what does it mean? Any answer ...
3
votes
0answers
112 views

Solidity : About function calls between deployed contracts

I want to make a function call between a token (MyToken.sol) that inherits MintableToken.sol of OpenZeppelin and manipulate that token (Buy. Sol). (MyToken.sol) pragma solidity ^0.4.21; import "...
4
votes
2answers
296 views

zeppelin-solidity Crowdsales Contract Not Working

I grab the smart contract example code from Zeppelin-Solidity GitHub https://github.com/OpenZeppelin/zeppelin-solidity I create and deploy the SimpleToken using EXACTLY the same code from the ...
0
votes
1answer
169 views

OpenZeppelin Pausable Concept, Security Concepts

Are items like the OpenZeppelin Pausable contracts any different than just having additional checks inline with standard Solidity? If a coder just placed checks in front of every function call with ...
0
votes
1answer
206 views

Buying tokens with OpenZepplin crowdsale

I am running into a very strange bug while interacting with my OpenZepplin crowdsale. Here is my repo for context https://github.com/GenusDev/crossfit-coin-backend Here is what I have working so far:...
1
vote
1answer
114 views

Error encountered, bailing. Network state unknown. Error: VM Exception while processing transaction: revert

I followed the feedback given from this question, and made a few changes to ganache like ensuring I have more than enough gas in my truffle file: require('babel-register'); require('babel-polyfill');...