Questions tagged [security]

Questions relating to application security, safety, trust, and attacks against the Ethereum software stack and blockchain system.

Filter by
Sorted by
Tagged with
1
vote
1answer
27 views

adaptive vs. non-adaptive adversaries? Is there a precise, unique and general definition? (Updated)

In this Ethereum github page (Link to the page: https://github.com/ethereum/wiki/wiki/Sharding-FAQ#what-are-the-security-models-that-we-are-operating-under) there is a very brief definition of the ...
0
votes
0answers
20 views

Smart Contracts for Cyber? [closed]

While the applicability of smart contracts is well documented in finance, trade, and insurance, I'm trying to wrap my head around potential use case for smart contracts in cybersecurity domains. Does ...
1
vote
1answer
26 views

Strict Balance Equality (Security Issue)

Research Paper, Page-5(Strict Balance Equality)I have read that attacker can use Selfdestruct() and forcibly send ethers to the contracts. My questions are: If Selfdestruct is meant for owner of ...
0
votes
1answer
42 views

Proxy function clashing - what kind of danger comes exactly with it?

I read that if I am using proxy, there is a chance of function clashing. Let's say in my contract there is a function with a signature: proxyOwner() ...
0
votes
3answers
39 views

How do I attack the `Vuln` contract?

How can I steal from Vuln contract? I have made another contract to try to steal from Vuln but it always gives me an error. And I'm not sure how to send the money to my adrress. contract Vuln { ...
0
votes
1answer
42 views

User anonymity while submitting data in smart contract

I've written a smart contract, that is a crowd sensing system. Where post posting a task user view that task and if they have what I'm asking for/and meet the task requirements they submit certain ...
0
votes
1answer
7 views

How to restrict call to inherited public function

I'm using OpenZeppelin library for my project and I need to override some functions for business logic. But my concern is with given example, // contract from library contract A { function ...
1
vote
1answer
29 views

How to access a smart contract function protected by access rights using Web3?

I have a smart contract address for security tokens, and certain functions of it are protected by access rights, for which I have an address to access those functions, however I am not able to figure ...
0
votes
1answer
24 views

Is this implementation of multisig2of3.sol secure? [closed]

I implemented multisig 2 of 3 contract. Please give me feedback on codestyle, security and usability. On codereview there is only two solidity questions, so I posted here. see on github pragma ...
0
votes
0answers
22 views

Understand the `call` opcode in this contract

Hello, I am posting a quick question regarding the functionality this contract: https://etherscan.io/address/6b63ea3612dde97082aab468157950f927618d31#code From the source code, I am not even able to ...
0
votes
1answer
16 views

Understand the potential issue of miner controlled gaslimit

I am aware that smart contracts running on top of EVM can access certain system properties such as timestamp, block number, and gas limit. I am also aware that such properties can be controlled by ...
2
votes
2answers
686 views

Issue with New version of Metamask: Remix cannot detect the Metamask address

I have just installed Metamask version: 6.3.1 Now in Remix, the address of my account in metamask is not detected. The account box in remix remains always blank now (see picture below). Note that I ...
2
votes
1answer
52 views

function input conditional check

I have a function which is accepting a string argument as input parameter. This string is an IPFS hash and I would like to check that the input is actually just that and not a malicious link or the ...
0
votes
1answer
40 views

msg.sender 'spoofing' when function is public or external

I have a Smart contract where I want only the onwer to call a specific function, for example: function getInfo() view public onlyOwner() returns (address) { return msg.sender; } ..... modifier ...
1
vote
0answers
14 views

Understanding a simple online contract which seems not functional

I am writing to understand the functionality of this contract (https://etherscan.io/address/0x1f14b77e9f4844889fa63bc1e5180c8b90ec18db), this does not look even "functional" to me. Here is the ...
1
vote
0answers
27 views

What are the drawbacks of layer 2?

The scalability trilemma states that a blockchain can only have two out the following three properties: decentralization, scalability, and security. Layer 2 protocols aim to make Ethereum more ...
2
votes
0answers
48 views

Is there any dynamic symbolic execution tool for smart contract [duplicate]

There is a question (Security analysis tool for Ethereum smart contracts) similar to me, but it presents mostly static analysis tools. I'd like to know if there is any better dynamical analysis tool ...
1
vote
1answer
20 views

Is there any concern for the significant number of nodes being hosted on AWS/ cloud providers?

Just curious if there is any downside that many nodes are being hosted on cloud providers? For example Infura, which supports many nodes and provides a large portion of connections to Ethereum nodes, ...
0
votes
1answer
28 views

Is a function prone to re-entrancy attack even if I set balance to zero within the same function (example included)

Such as in this scenario, is the hackable via re-entrancy? thanks... function withdraw(uint256 money) public { if(money <= balance[msg.sender]) { (bool success, ) = msg.sender.call....
1
vote
1answer
83 views

What is the Withdrawal Pattern?

I am reading this article : https://medium.com/@jgm.orinoco/why-use-the-withdrawal-pattern-d5255921ca2a It seems interesting. Could anyone explain the idea of the Withdrawal pattern in a simple way ?
0
votes
1answer
15 views

How to prevent someone running a transaction before me?

Let's say I have the following in my smart contract: string passwordHash; uint money; function checkPassword(string cleanPassword, string newPasswordHash)[...] When running the function ...
1
vote
1answer
114 views

How to start auditing smart contract?

I want to become a smart contract auditor. I will report all the vulnerabilities which I have explored while auditing smart contracts. Is there any platform available to learn how to audit smart ...
0
votes
1answer
13 views

What is the authorization for any technical central action in Ethereum system?

When, after fully reviewing, pull requests management and a detailed discussions on github and so on, it arrives the moment in which someone must take into his hands the technical intervention on the ...
5
votes
1answer
75 views

How to jump to any arbitrary location in already deployed contracts

I’d like to know what is preventing me to write an assembly code who knows the contract address and call some arbitrary functions, even if declared “internal” via a simple JUMP. In theory I can: 1) ...
1
vote
1answer
111 views

Is signatures from web3.eth/personal.sign deterministic and a safe to be used as seeds for private keys?

The first part of the question: if I give the same inputs (content and signing address) to the web3.eth/personal.sign, am I correct to expect the signature generated to be the same no matter how many ...
1
vote
1answer
160 views

Does this function send ether from the contract or from the message sender?

Solidity newbie here...: function transfer(address payable to, address sender) public onlyadmin { to.transfer(msg.value); } what I want to achieve is sending from the contract's ...
0
votes
0answers
73 views

How to prevent DDOS in ethereum using PoA?

Using clique, how to prevent DDOS attack? Is there a way to set a whitelist of nodes which can send transactions, and blacklist all the others?
1
vote
3answers
324 views

How to store private data on blockchain to be readable from a contract?

I'm writting DApp on Ethereum (Solidity) and I need to find a solution how to store a private data on blockchain, when I also need to proceed them somehow. If it is only about storing, I can use some ...
3
votes
1answer
164 views

How secured are private data stored on blockchain?

I'm quite new in Ethereum world and I'm still little bit confused about this: If I store any data on blockchain, is it readable from anyone? Let's say I have this is Solidity: ... string private ...
0
votes
1answer
41 views

What is the beginning nonce on the Rinkeby Testnet?

I know that the nonce is representative of how many transfers an account has made and is 0 at the start on the mainnet. However, on testnets, such as the now decommissioned Morden where it was 2^20 I ...
1
vote
0answers
63 views

The blockchain trilemma

I understand that the generic blockchain faces a problem where it can choose to optimize between scalability, security and decentralization. I can see easily why scalability and decentralization are ...
2
votes
2answers
379 views

Getting ParserError: Expected ',' but got 'payable' and also one important security issue with contract

I have write a small smart contract for lottery system. however there is problem. please see below full code. pragma solidity >=0.4.22 <0.6.0; contract Lottery{ address[] public players; //...
1
vote
2answers
73 views

DappHub Multiply Function

Could someone explain the use of performing a multiplication such as this? I mean the logic is fine, but what is the importance from a security point of view? function mul(uint x, uint y) internal ...
6
votes
1answer
531 views

What does griefing mean?

Not referring to the definition in the dictionary. In the context of blockchains and Ethereum in particular, the term "grief" has been used repeatedly in a host of scenarios: ethresear.ch, Plasma ...
-1
votes
1answer
152 views

Trying to figure out this 2 ETH smart contract quiz

Does anyone know whether this smart contract can be broken? Is there some trick behind this? https://etherscan.io/address/0xfc62a32da21052fb3086e8f68ad10a7118a98606
1
vote
0answers
55 views

What possibly could go wrong if I leave my private blockchain node 30303 port open to public? [duplicate]

I have the following setup: All the nodes inside my cluster are talking to each other via 30303 port. When I want to talk to them, I'm using a Geth light client via HTTP JSON RPC port 8545. Only the ...
2
votes
1answer
299 views

How privacy can be ensured in smart-contracts?

When a smart-contract is created following an agreement between two entities, how the state of that contract (data) can be kept secret to only the two contractors? I heard about Quorum, but how ...
1
vote
0answers
42 views

Is there a more elegant way to do an aggressive multi-send?

I understand there are many approaches to do multisend but for me timing is a priority and I do not want to stop the transaction if a address.send fails. function multiSend() internal isAdmin { ...
1
vote
0answers
50 views

secure open source Payment Gateway [closed]

I'm working on an open source multi coin payment gateway. ETH, EOS, BTC and BCH will be supported. My plan so far: The nodejs API runs on DigitalOcean. You send a GET request with your preferred ...
1
vote
0answers
39 views

GETH accounts imported without my knowledge

I expose only port 30303, not 8545. But when I issue commands eth.accounts. I found these accounts were imported without my knowledge: "0xe4fe1fb7e693c529f5a95dd8b1714d1acfdbd058", "...
1
vote
1answer
43 views

Cannot send transactions

I have a online shop where users can recieve ETH and do shopping. So to have a secure wallet, I have created an offline service which generates xpub and xpriv which I use to generate addresses in my ...
1
vote
1answer
36 views

Provide security wallet

I have a service where users can buy my product. Besides paying by card, I want to be able to allow users to pay in ETH. I think that it will correctly generate addresses for each user so that it is ...
0
votes
1answer
53 views

Invoking smart contracts

how can i restrict my smart contract getting invoked by any account in the network.can i tell the EVM itself to check(validate the account) is allowed to invoke the smart contract even before entering ...
0
votes
1answer
61 views

The DAO: Stalker Attack - Attacker split from childDAO?

I had a question about the argument in this article Why The Stalker Attack is a Non Issue. In the scenario the article describes, there is a "Victim" and an "Attacker". The Victim tries to split from ...
0
votes
1answer
33 views

Is this function good enough to refund ether or this security flaw?

I mean: function refund() { if (msg.value < 1 ether) { msg.sender.send(msg.value); return; } I'm probably wrong but this looks as if .send will drain the money in the contract if ...
0
votes
1answer
39 views

Is my function prone to under/overflow?

I don't like using safemath as this is my first conntract and this is getting a bit complicated for me so: function withdraw(uint xyz) public { require(balanceOf[msg.sender] >= xyz); ...
1
vote
1answer
81 views

account nonce - what if it did not exist? [duplicate]

I can't understand how account nonce actually avoids double spending. Every answer about this on the internet follow the pattern "If you only have 50 Eth and try to send 50 to A and 50 to B with ...
1
vote
1answer
23 views

Is attaching a name to an Ethereum address a “faux pas?”

I'm currently working on a DApp right now, and I was curious if it's considered poor design to include a string with the user's name that is mapped to a particular address. A user who has access to ...
0
votes
4answers
1k views

Generating lots of private key means I can hack someone's ether?

If I generates lots of private keys, I can get someone's address and its digital signature, right? I know that there's 2^256 possible private keys, but what if I use brute-force attack? Is it ...
4
votes
2answers
374 views

How is the keccak256(a, b) function implemented?

I need to understand how keccak256(a, b) is implemented and how it differs from keccak256(a || b). Is the content padded? I need this because I do not want to allow for vulnerabilities where a user ...