Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
N
nebula
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
exchain
nebula
Commits
ae1ac05d
Commit
ae1ac05d
authored
May 04, 2021
by
Maurelian
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix(contracts): restrict visibilities to external
parent
47e40a2d
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
33 additions
and
33 deletions
+33
-33
OVM_ExecutionManager.sol
...ptimistic-ethereum/OVM/execution/OVM_ExecutionManager.sol
+16
-16
OVM_DeployerWhitelist.sol
...imistic-ethereum/OVM/predeploys/OVM_DeployerWhitelist.sol
+4
-4
OVM_StateTransitioner.sol
...istic-ethereum/OVM/verification/OVM_StateTransitioner.sol
+9
-9
Lib_AddressManager.sol
...mistic-ethereum/libraries/resolver/Lib_AddressManager.sol
+2
-2
Lib_MerkleTrie.sol
...cts/optimistic-ethereum/libraries/trie/Lib_MerkleTrie.sol
+2
-2
No files found.
packages/contracts/contracts/optimistic-ethereum/OVM/execution/OVM_ExecutionManager.sol
View file @
ae1ac05d
...
@@ -161,7 +161,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
...
@@ -161,7 +161,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
address _ovmStateManager
address _ovmStateManager
)
)
override
override
public
external
{
{
// Make sure that run() is not re-enterable. This condition should always be satisfied
// Make sure that run() is not re-enterable. This condition should always be satisfied
// Once run has been called once, due to the behavior of _isValidInput().
// Once run has been called once, due to the behavior of _isValidInput().
...
@@ -228,7 +228,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
...
@@ -228,7 +228,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
*/
*/
function ovmCALLER()
function ovmCALLER()
override
override
public
external
view
view
returns (
returns (
address _CALLER
address _CALLER
...
@@ -258,7 +258,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
...
@@ -258,7 +258,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
*/
*/
function ovmTIMESTAMP()
function ovmTIMESTAMP()
override
override
public
external
view
view
returns (
returns (
uint256 _TIMESTAMP
uint256 _TIMESTAMP
...
@@ -273,7 +273,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
...
@@ -273,7 +273,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
*/
*/
function ovmNUMBER()
function ovmNUMBER()
override
override
public
external
view
view
returns (
returns (
uint256 _NUMBER
uint256 _NUMBER
...
@@ -288,7 +288,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
...
@@ -288,7 +288,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
*/
*/
function ovmGASLIMIT()
function ovmGASLIMIT()
override
override
public
external
view
view
returns (
returns (
uint256 _GASLIMIT
uint256 _GASLIMIT
...
@@ -303,7 +303,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
...
@@ -303,7 +303,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
*/
*/
function ovmCHAINID()
function ovmCHAINID()
override
override
public
external
view
view
returns (
returns (
uint256 _CHAINID
uint256 _CHAINID
...
@@ -322,7 +322,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
...
@@ -322,7 +322,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
*/
*/
function ovmL1QUEUEORIGIN()
function ovmL1QUEUEORIGIN()
override
override
public
external
view
view
returns (
returns (
Lib_OVMCodec.QueueOrigin _queueOrigin
Lib_OVMCodec.QueueOrigin _queueOrigin
...
@@ -337,7 +337,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
...
@@ -337,7 +337,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
*/
*/
function ovmL1TXORIGIN()
function ovmL1TXORIGIN()
override
override
public
external
view
view
returns (
returns (
address _l1TxOrigin
address _l1TxOrigin
...
@@ -417,7 +417,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
...
@@ -417,7 +417,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
bytes32 _salt
bytes32 _salt
)
)
override
override
public
external
notStatic
notStatic
fixedGasDiscount(40000)
fixedGasDiscount(40000)
returns (
returns (
...
@@ -456,7 +456,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
...
@@ -456,7 +456,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
*/
*/
function ovmGETNONCE()
function ovmGETNONCE()
override
override
public
external
returns (
returns (
uint256 _nonce
uint256 _nonce
)
)
...
@@ -469,7 +469,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
...
@@ -469,7 +469,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
*/
*/
function ovmINCREMENTNONCE()
function ovmINCREMENTNONCE()
override
override
public
external
notStatic
notStatic
{
{
address account = ovmADDRESS();
address account = ovmADDRESS();
...
@@ -618,7 +618,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
...
@@ -618,7 +618,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
bytes memory _calldata
bytes memory _calldata
)
)
override
override
public
external
fixedGasDiscount(80000)
fixedGasDiscount(80000)
returns (
returns (
bool _success,
bool _success,
...
@@ -653,7 +653,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
...
@@ -653,7 +653,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
bytes memory _calldata
bytes memory _calldata
)
)
override
override
public
external
fixedGasDiscount(40000)
fixedGasDiscount(40000)
returns (
returns (
bool _success,
bool _success,
...
@@ -685,7 +685,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
...
@@ -685,7 +685,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
bytes32 _key
bytes32 _key
)
)
override
override
public
external
netGasCost(40000)
netGasCost(40000)
returns (
returns (
bytes32 _value
bytes32 _value
...
@@ -710,7 +710,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
...
@@ -710,7 +710,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
bytes32 _value
bytes32 _value
)
)
override
override
public
external
notStatic
notStatic
netGasCost(60000)
netGasCost(60000)
{
{
...
@@ -782,7 +782,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
...
@@ -782,7 +782,7 @@ contract OVM_ExecutionManager is iOVM_ExecutionManager, Lib_AddressResolver {
address _contract
address _contract
)
)
override
override
public
external
returns (
returns (
bytes32 _EXTCODEHASH
bytes32 _EXTCODEHASH
)
)
...
...
packages/contracts/contracts/optimistic-ethereum/OVM/predeploys/OVM_DeployerWhitelist.sol
View file @
ae1ac05d
...
@@ -56,7 +56,7 @@ contract OVM_DeployerWhitelist is iOVM_DeployerWhitelist {
...
@@ -56,7 +56,7 @@ contract OVM_DeployerWhitelist is iOVM_DeployerWhitelist {
bool _allowArbitraryDeployment
bool _allowArbitraryDeployment
)
)
override
override
public
external
{
{
if (initialized == true) {
if (initialized == true) {
return;
return;
...
@@ -77,7 +77,7 @@ contract OVM_DeployerWhitelist is iOVM_DeployerWhitelist {
...
@@ -77,7 +77,7 @@ contract OVM_DeployerWhitelist is iOVM_DeployerWhitelist {
bool _isWhitelisted
bool _isWhitelisted
)
)
override
override
public
external
onlyOwner
onlyOwner
{
{
whitelist[_deployer] = _isWhitelisted;
whitelist[_deployer] = _isWhitelisted;
...
@@ -116,7 +116,7 @@ contract OVM_DeployerWhitelist is iOVM_DeployerWhitelist {
...
@@ -116,7 +116,7 @@ contract OVM_DeployerWhitelist is iOVM_DeployerWhitelist {
*/
*/
function enableArbitraryContractDeployment()
function enableArbitraryContractDeployment()
override
override
public
external
onlyOwner
onlyOwner
{
{
setAllowArbitraryDeployment(true);
setAllowArbitraryDeployment(true);
...
@@ -132,7 +132,7 @@ contract OVM_DeployerWhitelist is iOVM_DeployerWhitelist {
...
@@ -132,7 +132,7 @@ contract OVM_DeployerWhitelist is iOVM_DeployerWhitelist {
address _deployer
address _deployer
)
)
override
override
public
external
returns (
returns (
bool
bool
)
)
...
...
packages/contracts/contracts/optimistic-ethereum/OVM/verification/OVM_StateTransitioner.sol
View file @
ae1ac05d
...
@@ -132,7 +132,7 @@ contract OVM_StateTransitioner is Lib_AddressResolver, Abs_FraudContributor, iOV
...
@@ -132,7 +132,7 @@ contract OVM_StateTransitioner is Lib_AddressResolver, Abs_FraudContributor, iOV
*/
*/
function getPreStateRoot()
function getPreStateRoot()
override
override
public
external
view
view
returns (
returns (
bytes32 _preStateRoot
bytes32 _preStateRoot
...
@@ -147,7 +147,7 @@ contract OVM_StateTransitioner is Lib_AddressResolver, Abs_FraudContributor, iOV
...
@@ -147,7 +147,7 @@ contract OVM_StateTransitioner is Lib_AddressResolver, Abs_FraudContributor, iOV
*/
*/
function getPostStateRoot()
function getPostStateRoot()
override
override
public
external
view
view
returns (
returns (
bytes32 _postStateRoot
bytes32 _postStateRoot
...
@@ -162,7 +162,7 @@ contract OVM_StateTransitioner is Lib_AddressResolver, Abs_FraudContributor, iOV
...
@@ -162,7 +162,7 @@ contract OVM_StateTransitioner is Lib_AddressResolver, Abs_FraudContributor, iOV
*/
*/
function isComplete()
function isComplete()
override
override
public
external
view
view
returns (
returns (
bool _complete
bool _complete
...
@@ -188,7 +188,7 @@ contract OVM_StateTransitioner is Lib_AddressResolver, Abs_FraudContributor, iOV
...
@@ -188,7 +188,7 @@ contract OVM_StateTransitioner is Lib_AddressResolver, Abs_FraudContributor, iOV
bytes memory _stateTrieWitness
bytes memory _stateTrieWitness
)
)
override
override
public
external
onlyDuringPhase(TransitionPhase.PRE_EXECUTION)
onlyDuringPhase(TransitionPhase.PRE_EXECUTION)
contributesToFraudProof(preStateRoot, transactionHash)
contributesToFraudProof(preStateRoot, transactionHash)
{
{
...
@@ -260,7 +260,7 @@ contract OVM_StateTransitioner is Lib_AddressResolver, Abs_FraudContributor, iOV
...
@@ -260,7 +260,7 @@ contract OVM_StateTransitioner is Lib_AddressResolver, Abs_FraudContributor, iOV
bytes memory _storageTrieWitness
bytes memory _storageTrieWitness
)
)
override
override
public
external
onlyDuringPhase(TransitionPhase.PRE_EXECUTION)
onlyDuringPhase(TransitionPhase.PRE_EXECUTION)
contributesToFraudProof(preStateRoot, transactionHash)
contributesToFraudProof(preStateRoot, transactionHash)
{
{
...
@@ -324,7 +324,7 @@ contract OVM_StateTransitioner is Lib_AddressResolver, Abs_FraudContributor, iOV
...
@@ -324,7 +324,7 @@ contract OVM_StateTransitioner is Lib_AddressResolver, Abs_FraudContributor, iOV
Lib_OVMCodec.Transaction memory _transaction
Lib_OVMCodec.Transaction memory _transaction
)
)
override
override
public
external
onlyDuringPhase(TransitionPhase.PRE_EXECUTION)
onlyDuringPhase(TransitionPhase.PRE_EXECUTION)
contributesToFraudProof(preStateRoot, transactionHash)
contributesToFraudProof(preStateRoot, transactionHash)
{
{
...
@@ -374,7 +374,7 @@ contract OVM_StateTransitioner is Lib_AddressResolver, Abs_FraudContributor, iOV
...
@@ -374,7 +374,7 @@ contract OVM_StateTransitioner is Lib_AddressResolver, Abs_FraudContributor, iOV
bytes memory _stateTrieWitness
bytes memory _stateTrieWitness
)
)
override
override
public
external
onlyDuringPhase(TransitionPhase.POST_EXECUTION)
onlyDuringPhase(TransitionPhase.POST_EXECUTION)
contributesToFraudProof(preStateRoot, transactionHash)
contributesToFraudProof(preStateRoot, transactionHash)
{
{
...
@@ -417,7 +417,7 @@ contract OVM_StateTransitioner is Lib_AddressResolver, Abs_FraudContributor, iOV
...
@@ -417,7 +417,7 @@ contract OVM_StateTransitioner is Lib_AddressResolver, Abs_FraudContributor, iOV
bytes memory _storageTrieWitness
bytes memory _storageTrieWitness
)
)
override
override
public
external
onlyDuringPhase(TransitionPhase.POST_EXECUTION)
onlyDuringPhase(TransitionPhase.POST_EXECUTION)
contributesToFraudProof(preStateRoot, transactionHash)
contributesToFraudProof(preStateRoot, transactionHash)
{
{
...
@@ -457,7 +457,7 @@ contract OVM_StateTransitioner is Lib_AddressResolver, Abs_FraudContributor, iOV
...
@@ -457,7 +457,7 @@ contract OVM_StateTransitioner is Lib_AddressResolver, Abs_FraudContributor, iOV
*/
*/
function completeTransition()
function completeTransition()
override
override
public
external
onlyDuringPhase(TransitionPhase.POST_EXECUTION)
onlyDuringPhase(TransitionPhase.POST_EXECUTION)
{
{
require(
require(
...
...
packages/contracts/contracts/optimistic-ethereum/libraries/resolver/Lib_AddressManager.sol
View file @
ae1ac05d
...
@@ -39,7 +39,7 @@ contract Lib_AddressManager is Ownable {
...
@@ -39,7 +39,7 @@ contract Lib_AddressManager is Ownable {
string memory _name,
string memory _name,
address _address
address _address
)
)
public
external
onlyOwner
onlyOwner
{
{
addresses[_getNameHash(_name)] = _address;
addresses[_getNameHash(_name)] = _address;
...
@@ -58,7 +58,7 @@ contract Lib_AddressManager is Ownable {
...
@@ -58,7 +58,7 @@ contract Lib_AddressManager is Ownable {
function getAddress(
function getAddress(
string memory _name
string memory _name
)
)
public
external
view
view
returns (
returns (
address
address
...
...
packages/contracts/contracts/optimistic-ethereum/libraries/trie/Lib_MerkleTrie.sol
View file @
ae1ac05d
...
@@ -314,8 +314,8 @@ library Lib_MerkleTrie {
...
@@ -314,8 +314,8 @@ library Lib_MerkleTrie {
currentNodeID = bytes32(RLP_NULL);
currentNodeID = bytes32(RLP_NULL);
break;
break;
} else if (prefix == PREFIX_EXTENSION_EVEN || prefix == PREFIX_EXTENSION_ODD) {
} else if (prefix == PREFIX_EXTENSION_EVEN || prefix == PREFIX_EXTENSION_ODD) {
if (sharedNibbleLength
== 0
) {
if (sharedNibbleLength
!= pathRemainder.length
) {
// Our extension node
doesn't share any part of our key
.
// Our extension node
is not identical to the remainder
.
// We've hit the end of this path, updates will need to modify this extension.
// We've hit the end of this path, updates will need to modify this extension.
currentNodeID = bytes32(RLP_NULL);
currentNodeID = bytes32(RLP_NULL);
break;
break;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment