Skip to content

Commit

Permalink
Merge tag 'v3.0.0' into eigenda-v3.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
epociask committed Jan 15, 2025
2 parents 074462e + 780366a commit 814783a
Show file tree
Hide file tree
Showing 273 changed files with 27,365 additions and 38,980 deletions.
5 changes: 5 additions & 0 deletions .env-sample
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
L1_RPC_URL="http://127.0.0.1:8545"
L1_PRIV_KEY="0xac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80"
CONFIG_NETWORK_NAME="arb1"
DEPLOYED_CONTRACTS_DIR="./scripts/files/"
DISABLE_VERIFICATION=true
7 changes: 0 additions & 7 deletions .env.sample.goerli

This file was deleted.

5 changes: 5 additions & 0 deletions .env.sample.testnode
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
L1_RPC_URL="http://localhost:8545"
L1_PRIV_KEY="0xdc04c5399f82306ec4b4d654a342f40e2e0620fe39950d967e1e574b32d4dd36"
CONFIG_NETWORK_NAME="local"
DEPLOYED_CONTRACTS_DIR="./scripts/files/"
DISABLE_VERIFICATION=true
24 changes: 5 additions & 19 deletions .github/workflows/audit-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,39 +10,25 @@ on:
- develop

jobs:
install:
name: 'Install'
yarn-audit:
name: Audit
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [18, 20]
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}

- name: Install node_modules
uses: OffchainLabs/actions/node-modules/install@main

yarn-audit:
name: Audit
runs-on: ubuntu-latest
needs: install
steps:
- name: Checkout
uses: actions/checkout@v3

- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}

- name: Restore node_modules
uses: OffchainLabs/actions/node-modules/restore@main
cache-key: ${{ runner.os }}-yarn-${{ hashFiles('yarn.lock') }}-${{ matrix.node-version }}

- name: Run audit
run: yarn audit:ci
39 changes: 37 additions & 2 deletions .github/workflows/contract-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,7 @@ on:
merge_group:
push:
branches:
- master
- develop
- eigenda

jobs:
test-unit:
Expand All @@ -23,6 +22,9 @@ jobs:
with:
version: nightly

- name: Check Contracts Format
run: forge fmt --check

- name: Setup node/yarn
uses: actions/setup-node@v3
with:
Expand Down Expand Up @@ -244,3 +246,36 @@ jobs:

# - name: Run e2e tests
# run: yarn test:e2e

bold-upgrade:
name: BOLD upgrade test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
submodules: recursive

- name: Install Foundry
uses: foundry-rs/foundry-toolchain@v1
with:
version: nightly

- name: Setup node/yarn
uses: actions/setup-node@v3
with:
node-version: 18
cache: 'yarn'
cache-dependency-path: '**/yarn.lock'

- name: Install packages
run: yarn

- name: Compile contracts
run: yarn build:all

- name: Copy .env
run: |
cp ./.env-sample ./.env
- name: Test upgrade
run: L1_RPC=${{ secrets.L1_RPC || 'https://rpc.ankr.com/eth' }} yarn test:upgrade
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,7 @@ deployments/
scripts/config.ts
forge-cache/
out/
.env
.env
.DS_Store
lcov.info
output_directory
2 changes: 2 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,5 @@ src/lib/abi/**
out/**
lib/**
src/mocks/MultiCallTest.sol
slither.db.json
LICENSE.md
12 changes: 0 additions & 12 deletions .prettierrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,4 @@ module.exports = {
tabWidth: 2,
arrowParens: 'avoid',
bracketSpacing: true,
overrides: [
{
files: '*.sol',
options: {
tabWidth: 4,
printWidth: 100,
singleQuote: false,
bracketSpacing: false,
compiler: '0.8.9',
},
},
],
}
9 changes: 6 additions & 3 deletions .solhint.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
{
"extends": ["solhint:recommended"],
"rules": {
"prettier/prettier": "error",
"avoid-throw": "off",
"avoid-suicide": "error",
"avoid-sha3": "warn",
Expand All @@ -12,7 +11,11 @@
"reason-string": ["warn", { "maxLength": 128 }],
"not-rely-on-time": "off",
"max-states-count": ["warn", 40],
"no-inline-assembly": "off"
"no-inline-assembly": "off",
"no-global-import": "off",
"custom-errors": "off",
"immutable-vars-naming": "off",
"var-name-mixedcase": "off"
},
"plugins": ["prettier"]
"plugins": []
}
3 changes: 3 additions & 0 deletions .solhintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
src/mocks
src/precompiles
src/test-helpers
4 changes: 2 additions & 2 deletions LICENSE.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@ Additional Use Grant: You may use the Licensed Work in a production environment
validating the correctness of the posted chain state, or to deploy
and operate (x) a blockchain that settles to a Covered Arbitrum Chain
or (y) a blockchain in accordance with, and subject to, the [Arbitrum
Expansion Program Term of Use](https://docs.arbitrum.foundation/assets/files/Arbitrum%20Expansion%20Program%20Jan182024-4f08b0c2cb476a55dc153380fa3e64b0.pdf). For purposes of this
Expansion Program Term of Use](https://docs.arbitrum.foundation/aep/ArbitrumExpansionProgramTerms.pdf). For purposes of this
Additional Use Grant, the "Covered Arbitrum Chains" are
(a) Arbitrum One (chainid:42161), Arbitrum Nova (chainid:42170),
rbitrum Rinkeby testnet/Rinkarby (chainid:421611),Arbitrum Nitro
Arbitrum Rinkeby testnet/Rinkarby (chainid:421611),Arbitrum Nitro
Goerli testnet (chainid:421613), and Arbitrum Sepolia Testnet
(chainid:421614); (b) any future blockchains authorized to be
designated as Covered Arbitrum Chains by the decentralized autonomous
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ It includes the rollup and fraud proof smart contracts, as well as interfaces fo

For more information see https://developer.arbitrum.io/intro

For the deployed addresses of these contracts for Arbitrum chains see https://developer.arbitrum.io/useful-addresses
For the deployed addresses of these contracts for Arbitrum chains see [https://docs.arbitrum.io/for-devs/dev-tools-and-resources/chain-info#core-contracts](https://docs.arbitrum.io/for-devs/dev-tools-and-resources/chain-info#core-contracts)

For the token bridge contracts see https://github.com/OffchainLabs/token-bridge-contracts
For the token bridge contracts see [https://github.com/OffchainLabs/token-bridge-contracts](https://github.com/OffchainLabs/token-bridge-contracts)

Compile these contracts locally by running

Expand All @@ -24,7 +24,7 @@ Nitro is currently licensed under a [Business Source License](./LICENSE.md), sim

The Additional Use Grant also permits the deployment of the Nitro software, in a permissionless fashion and without cost, as a new blockchain provided that the chain settles to either Arbitrum One or Arbitrum Nova.

For those that prefer to deploy the Nitro software either directly on Ethereum (i.e. an L2) or have it settle to another Layer-2 on top of Ethereum, the [Arbitrum Expansion Program (the "AEP")](https://docs.arbitrum.foundation/assets/files/Arbitrum%20Expansion%20Program%20Jan182024-4f08b0c2cb476a55dc153380fa3e64b0.pdf) was recently established. The AEP allows for the permissionless deployment in the aforementioned fashion provided that 10% of net revenue is contributed back to the Arbitrum community in accordance with the requirements of the AEP.
For those that prefer to deploy the Nitro software either directly on Ethereum (i.e. an L2) or have it settle to another Layer-2 on top of Ethereum, the [Arbitrum Expansion Program (the "AEP")](https://docs.arbitrum.foundation/aep/ArbitrumExpansionProgramTerms.pdf) was recently established. The AEP allows for the permissionless deployment in the aforementioned fashion provided that 10% of net revenue is contributed back to the Arbitrum community in accordance with the requirements of the AEP.

## Contact

Expand Down
22 changes: 21 additions & 1 deletion audit-ci.jsonc
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,26 @@
// Prototype Pollution in async
"GHSA-fwr7-v2mv-hh25",
// ws affected by a DoS when handling a request with many HTTP headers
"GHSA-3h5v-q93c-6h6q"
"GHSA-3h5v-q93c-6h6q",
// Elliptic allows BER-encoded signatures - only used in dev
"GHSA-49q7-c7j4-3p7m",
// Elliptic's EDDSA missing signature length check - only used in dev
"GHSA-f7q4-pwc6-w24p",
// Elliptic's ECDSA missing check for whether leading bit of r and s is zero - only used in dev
"GHSA-977x-g7h5-7qgw",
// Server-Side Request Forgery in axios
"GHSA-8hc4-vh64-cxmj",
// Regular Expression Denial of Service (ReDoS) in micromatch
"GHSA-952p-6rrq-rcjv",
// cookie accepts cookie name, path, and domain with out of bounds characters
"GHSA-pxg6-pf52-xh8x",
// Elliptic's verify function omits uniqueness validation
"GHSA-434g-2637-qmqr",
// Valid ECDSA signatures erroneously rejected in Elliptic
"GHSA-fc9h-whq2-v747",
// secp256k1-node allows private key extraction over ECDH
"GHSA-584q-6j8j-r5pm",
// Regular Expression Denial of Service (ReDoS) in cross-spawn
"GHSA-3xgq-45jj-v275"
]
}
45 changes: 45 additions & 0 deletions deploy/ExpressLaneAuction.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
module.exports = async hre => {
const { deployments, getNamedAccounts } = hre
const { deploy } = deployments
const { deployer } = await getNamedAccounts()

await deploy('ExpressLaneAuction', {
from: deployer,
args: [],
proxy: {
proxyContract: 'TransparentUpgradeableProxy',
execute: {
init: {
methodName: 'initialize',
args: [
{
_auctioneer: '0xeee584DA928A94950E177235EcB9A99bb655c7A0',
_biddingToken: '0x980B62Da83eFf3D4576C647993b0c1D7faf17c73', // WETH
_beneficiary: '0xeee584DA928A94950E177235EcB9A99bb655c7A0',
_roundTimingInfo: {
offsetTimestamp: 1727870000,
roundDurationSeconds: 60,
auctionClosingSeconds: 15,
reserveSubmissionSeconds: 15,
},
_minReservePrice: ethers.utils.parseEther('0.00001'),
_auctioneerAdmin: '0xeee584DA928A94950E177235EcB9A99bb655c7A0',
_minReservePriceSetter:
'0xeee584DA928A94950E177235EcB9A99bb655c7A0',
_reservePriceSetter: '0xeee584DA928A94950E177235EcB9A99bb655c7A0',
_reservePriceSetterAdmin:
'0xeee584DA928A94950E177235EcB9A99bb655c7A0',
_beneficiarySetter: '0xeee584DA928A94950E177235EcB9A99bb655c7A0',
_roundTimingSetter: '0xeee584DA928A94950E177235EcB9A99bb655c7A0',
_masterAdmin: '0xeee584DA928A94950E177235EcB9A99bb655c7A0',
},
],
},
},
owner: deployer,
},
})
}

module.exports.tags = ['ExpressLaneAuction']
module.exports.dependencies = []
30 changes: 21 additions & 9 deletions foundry.toml
Original file line number Diff line number Diff line change
@@ -1,18 +1,17 @@
[profile.default]
src = 'src/'
src = 'src'
out = 'out'
libs = ['node_modules', 'lib']
test = 'test/foundry'
cache_path = 'forge-cache/sol'
optimizer = true
optimizer_runs = 100
optimizer_runs = 2000
via_ir = false
solc_version = '0.8.12'
evm_version = 'cancun'
remappings = ['ds-test/=lib/forge-std/lib/ds-test/src/',
'forge-std/=lib/forge-std/src/',
'@openzeppelin/contracts/=node_modules/@openzeppelin/contracts/',
'@openzeppelin/contracts-upgradeable/=node_modules/@openzeppelin/contracts-upgradeable/']

'@openzeppelin/contracts-upgradeable/=node_modules/@openzeppelin/contracts-upgradeable/',
'@openzeppelin/contracts/=node_modules/@openzeppelin/contracts/',
'@offchainlabs/upgrade-executor/=node_modules/@offchainlabs/upgrade-executor/']
fs_permissions = [{ access = "read", path = "./test/foundry/blob_info"}]

[profile.yul]
Expand All @@ -24,6 +23,19 @@ remappings = []
auto_detect_remappings = false

[fmt]
number_underscore = 'thousands'
line_length = 100
# See more config options https://github.com/foundry-rs/foundry/tree/master/config
tab_width = 4
bracket_spacing = false
int_types = "long"
multiline_func_header = "params_first"
quote_style = "double"
number_underscore = "preserve"
hex_underscore = "remove"
single_line_statement_blocks = "preserve"
override_spacing = false
wrap_comments = false
ignore = []
contract_new_lines = false
sort_imports = false

# See more config options https://github.com/foundry-rs/foundry/tree/master/config
Loading

0 comments on commit 814783a

Please sign in to comment.