Skip to content
This repository has been archived by the owner on May 22, 2023. It is now read-only.

Call gas limit #220

Merged
merged 9 commits into from Feb 19, 2020
Merged

Call gas limit #220

merged 9 commits into from Feb 19, 2020

Conversation

dimpar
Copy link
Contributor

@dimpar dimpar commented Feb 17, 2020

We are limiting forwarded gas to request relay entry function to prevent malicious behavior in case the beacon service contract gets compromised. Relay request should not consume more than 360k of gas. We set the limit to 400k to have a safety margin for future updates.

@dimpar
Copy link
Contributor Author

dimpar commented Feb 17, 2020

30k was used in newGroupSelectionSeed() by running tests. Around 27k was the lowest gas value when the tests passed.

solidity/contracts/ECDSAKeep.sol Outdated Show resolved Hide resolved
solidity/contracts/ECDSAKeepFactory.sol Outdated Show resolved Hide resolved
solidity/contracts/ECDSAKeep.sol Outdated Show resolved Hide resolved
solidity/contracts/KeepBonding.sol Outdated Show resolved Hide resolved
solidity/contracts/KeepBonding.sol Outdated Show resolved Hide resolved
dimpar and others added 4 commits February 18, 2020 23:01
We do not limit the gas in calls when the interested party withdraws
ether. It does not make sense - the interested party knows best how much
calls should cost and can set the gas limit appropriately.
Relay request should not cost more than 360k but we include a safety
margin for future upgrades.
@pdyraga
Copy link
Member

pdyraga commented Feb 19, 2020

Tested and works as expected. Since I was committing here can you please double-check @nkuba?

@nkuba nkuba merged commit f20ba73 into master Feb 19, 2020
@nkuba nkuba deleted the call-gas-limit branch February 19, 2020 00:09
@pdyraga pdyraga added this to the v0.8.0 milestone Feb 19, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants