Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
268 commits
Select commit Hold shift + click to select a range
f3adce4
Hold a Bitcoin hash to rskj's target: 2^256 over max(difficulty, 3)
ColbySerpa Nov 6, 2026
e34d889
Check every stored header beside the live node, fork detection included
ColbySerpa Nov 6, 2026
391abb3
Hold fallback-mined blocks to rskj's signature check
ColbySerpa Nov 6, 2026
750cdfd
Read partial merkle trees as bitcoinj-thin does, in one place
ColbySerpa Nov 6, 2026
0ca5e2e
Hold merged mining below orchid to rskj's GenesisMerkleProofValidator
ColbySerpa Nov 6, 2026
6545eab
Hash a versioned header from the network as rskj does
ColbySerpa Nov 8, 2026
4e4c0e1
Hold testnet to RSKIP290's minimum difficulty
ColbySerpa Nov 7, 2026
950a25d
Serve a relay what a light client checks: raw blocks, numbers, state …
ColbySerpa Nov 7, 2026
4c88f86
Take the node rskj's walk stops at, and ask just past where it stopped
ColbySerpa Nov 7, 2026
cffd6a4
Take the extension rskj sends beside a body, so testnet's blocks run
ColbySerpa Nov 7, 2026
15d2b8b
docs: rskj sends a chain's headers to its peers compressed
ColbySerpa Nov 7, 2026
f701763
docs: the node catches no signal; rsk_shutdown is its ordered stop
ColbySerpa Nov 7, 2026
7f81a59
Take a signature whose key is the point at infinity, as rskj does
ColbySerpa Nov 8, 2026
cb04206
rpc: check a contract's storage as a light client does
ColbySerpa Nov 8, 2026
1c62827
Measure a thread's CPU time on macOS and Windows too
ColbySerpa Nov 8, 2026
8046958
flatdb: lock and reserve its files on Windows too
ColbySerpa Nov 8, 2026
8f2273e
alerts: build on Windows, where an env file's mode is not checked
ColbySerpa Nov 8, 2026
4390d73
cli: run the node on a thread with an 8 MiB stack on every OS
ColbySerpa Nov 8, 2026
4f268cf
hardfork: rules activate where rskj's config files put them
ColbySerpa Nov 8, 2026
15367e7
bridge: the union bridge's getters take a STATICCALL, as rskj's do
ColbySerpa Nov 8, 2026
41f9bd3
bridge: RSKIP529's super and base events
ColbySerpa Nov 8, 2026
c93ddb3
bridge: read arguments as rskj's decoder does, and validate peg-ins i…
ColbySerpa Nov 9, 2026
dfe5b02
native contracts run as rskj's NativeContract; a throw in a transacti…
ColbySerpa Nov 9, 2026
20a7446
nothing a stranger sends can panic the node: peers, snapshot sync, bl…
ColbySerpa Nov 9, 2026
ac0c944
execution: DUPN, SWAPN and TXINDEX before RSKIP191, as rskj runs them
ColbySerpa Nov 9, 2026
559b7f1
execution: a precompile that throws before RSKIP197 fails its caller,…
ColbySerpa Nov 9, 2026
779d795
execution: ECRecover answers as rskj's, the point at infinity and v i…
ColbySerpa Nov 9, 2026
b0a643e
execution: a contract's input to a precompile is cut to what it reads…
ColbySerpa Nov 9, 2026
124c83f
execution: before RSKIP552 a transaction's empty call to BLAKE2F fail…
ColbySerpa Nov 9, 2026
5566a2d
core: a transaction as rskj reads, hashes, signs and accepts it
ColbySerpa Nov 9, 2026
69d6621
execution: a transaction's gas as rskj reads and fits it, in every run
ColbySerpa Nov 9, 2026
ab8656a
execution: modexp priced and run as rskj's, lengths read as Java ints
ColbySerpa Nov 9, 2026
42102bc
core: a header's fields as rskj reads, keeps and writes them
ColbySerpa Nov 9, 2026
ea9b13b
execution: a header's gas limit read from its bytes, as rskj reads it
ColbySerpa Nov 9, 2026
8b5cc8c
core: no maximum gas limit, and its bounds read whole, as rskj's
ColbySerpa Nov 9, 2026
09a9451
core: a minimum gas price of any size, as rskj takes it
ColbySerpa Nov 9, 2026
e1f04e4
execution: pay an empty coinbase at rskj's null address
ColbySerpa Nov 9, 2026
dafac67
core, execution, cli: headers laid out by rskj's heights, and a miner…
ColbySerpa Nov 9, 2026
28f0321
core, storage, networking: headers read by rskj's heights, in the for…
ColbySerpa Nov 9, 2026
0300a28
execution: the Bridge writes the lock whitelist back whenever a call …
ColbySerpa Nov 9, 2026
9a9a01a
Bridge: the BTC methods seed the BTC store as RSKj's ensureBtcBlockStore
ColbySerpa Nov 9, 2026
9821143
execution: what precompiles write outside revm's journal goes back wi…
ColbySerpa Nov 10, 2026
809e263
core: a header hashes by the heights it was read with (RSKIP-92)
ColbySerpa Nov 10, 2026
10878aa
execution: releaseBtc reads a pegout's satoshis as RSKj's long
ColbySerpa Nov 10, 2026
78aff7f
core: testnet2's Bitcoin timestamp window is testnet's, as RSKj's
ColbySerpa Nov 10, 2026
7ef69d6
execution: regtest's federation changes are voted by RSKj's three
ColbySerpa Nov 10, 2026
2a577c0
execution: the Bridge adds BTC headers as bitcoinj-thin's add
ColbySerpa Nov 10, 2026
4098f46
execution: the Bridge's block index height and testnet's federation a…
ColbySerpa Nov 10, 2026
eef16e3
execution: RSKj's regtest Bridge, genesis federation and free senders
ColbySerpa Nov 10, 2026
e5cc8c9
execution: getActivePowpegRedeemScript answers the active federation'…
ColbySerpa Nov 10, 2026
e34e14e
execution: rskj's regtest runs on its regtest.conf's schedule
ColbySerpa Nov 10, 2026
a1cdd41
execution: registerBtcTransaction classifies by rskj's pegout index
ColbySerpa Nov 10, 2026
70245e6
execution: below the pegout index, classify as rskj's legacy rules do
ColbySerpa Nov 10, 2026
13229ca
sync: give every block of a forward run its own total difficulty
ColbySerpa Nov 10, 2026
b29eb51
sync: keep the forward ascent going when a peer's skeleton stops short
ColbySerpa Nov 10, 2026
d54ce9e
sync: store a snapshot block's own header beside its body
ColbySerpa Nov 10, 2026
ca2a87b
sync: keep the uncles of every block whose body a sync doesn't fetch
ColbySerpa Nov 10, 2026
489851c
sync: announce, relay and serve new blocks as rskj does
ColbySerpa Nov 10, 2026
bfe1bff
sync: a mined block's committed state becomes the node's in-memory root
ColbySerpa Nov 10, 2026
b22c3db
sync: a reorg while a block executes is a warning, not an error
ColbySerpa Nov 10, 2026
f6db1e2
sync: the pool's quota reads values as rskj's longs
ColbySerpa Nov 10, 2026
2365c62
sync: refuse whole blocks from rskj's peer.bannedMiners
ColbySerpa Nov 10, 2026
85b9df5
execution: traces and estimates run the chain's exec loop
ColbySerpa Nov 10, 2026
357fb6c
rpc: answer a transaction from the main chain only
ColbySerpa Nov 10, 2026
718402b
execution: a local call passes the gates a block's transaction is hel…
ColbySerpa Nov 10, 2026
cba4567
rpc: read block parameters as rskj reads them
ColbySerpa Nov 10, 2026
3f28e46
rpc: a call's and a sent transaction's defaults as rskj's
ColbySerpa Nov 10, 2026
9a3fcbc
rpc: eth_gasPrice in doubles, as rskj computes it
ColbySerpa Nov 10, 2026
f3f58a5
execution: the Bridge's and REMASC's transfers as CALL subtraces
ColbySerpa Nov 10, 2026
2bffcc1
rpc: a block's fields as rskj's BlockResultDTO prints them
ColbySerpa Nov 10, 2026
0a0eaee
rpc: the methods rskj stubs or refuses, answered as rskj answers them
ColbySerpa Nov 10, 2026
88f92e6
style: rustfmt the lines this branch changed
ColbySerpa Nov 10, 2026
73c0f10
execution: a test's switch of the sender emulation stays on its thread
ColbySerpa Nov 10, 2026
b8f3e1d
execution: the notify test builds on a head its clock can't pass
ColbySerpa Nov 10, 2026
a51f6bf
execution: the timed-miner test waits for its blocks
ColbySerpa Nov 10, 2026
2ceb90d
execution: take the upgrade names of RSKj's release
ColbySerpa Nov 10, 2026
b718b45
bridge: before RSKIP88, an illegal argument is a success with no output
ColbySerpa Nov 10, 2026
9dfd6af
bridge: testnet's early ERP redeem scripts
ColbySerpa Nov 10, 2026
80ab5f6
bridge: testnet's block 5,148,285 finds RSKj's hard-coded Bitcoin block
ColbySerpa Nov 10, 2026
9800ddd
Execution: the accounts a block deleted and created, as rskj tracks them
ColbySerpa Nov 10, 2026
6d50705
Execution: a refused CREATE keeps the return data at every height
ColbySerpa Nov 10, 2026
b4e0248
Comments: no private references, and RSKj's release where they cite it
ColbySerpa Nov 10, 2026
91b24c4
sync: the uncles held for a block are the ones its header commits to
ColbySerpa Nov 10, 2026
ca23ab9
bridge: a federation of 16 or more writes its size as RSKj's release …
ColbySerpa Nov 10, 2026
b927592
Merge upstream's main at fccf4c5
ColbySerpa Nov 12, 2026
3189a72
bridge: four more cases where bitcoinj's redeem-script parsers differ…
ColbySerpa Nov 13, 2026
7dc4010
bridge: registerBtcCoinbaseTransaction takes a coinbase bitcoinj veri…
ColbySerpa Nov 13, 2026
8509bba
bridge: addSignature and the old registerBtcTransaction are for feder…
ColbySerpa Nov 13, 2026
2ad501e
bridge: the four peg-in sender parsers, as RSKj runs them
ColbySerpa Nov 13, 2026
477a944
bridge: the union bridge's authorizer-only methods throw for anyone else
ColbySerpa Nov 13, 2026
a19ce96
Execution: the secp256k1 contracts pad a short last word on the right
ColbySerpa Nov 13, 2026
61a4fdd
bridge: governance votes are the caller's, and a short commit hash th…
ColbySerpa Nov 13, 2026
a8d274f
bridge: a merkle tree bitcoinj refuses is an illegal argument
ColbySerpa Nov 13, 2026
fd526eb
validation: a header without sublist edges fails the edges rule
ColbySerpa Nov 13, 2026
2c7420e
precompiles: a CALLCODE or DELEGATECALL creates no account for the pr…
ColbySerpa Nov 13, 2026
b2767fd
bridge: a contract's call ends as rskj ends it in each era
ColbySerpa Nov 13, 2026
7f0f9a7
bridge: a federation Bitcoin could not spend from is not committed
ColbySerpa Nov 13, 2026
4871a0d
bridge: regtest has the union bridge authorizers rskj gives it
ColbySerpa Nov 13, 2026
a55fb14
config: testnet's genesis header is the one rskj builds
ColbySerpa Nov 13, 2026
ab488cb
precompiles: a native contract's null ends a contract's call as rskj …
ColbySerpa Nov 13, 2026
18253c6
hardfork: a rule moves with its own upgrade when a schedule is overri…
ColbySerpa Nov 13, 2026
a35a815
sync: a block sent whole is weighed with the uncles it brings
ColbySerpa Nov 13, 2026
ec10566
bridge: a refund is built and settled as every other release
ColbySerpa Nov 13, 2026
18eea19
bridge: a segwit release is sized before its inputs are filled in
ColbySerpa Nov 13, 2026
0bf20ce
execution: SELFDESTRUCT with no balance leaves the beneficiary alone
ColbySerpa Nov 13, 2026
a82ed18
bridge: a contract's registerBtcTransaction names its refund as rskj's
ColbySerpa Nov 13, 2026
8953895
bridge: a Bitcoin transaction is read as bitcoinj reads it, and verified
ColbySerpa Nov 13, 2026
f7ab2e4
execution: a transaction that runs no program has rskj's trace
ColbySerpa Nov 13, 2026
80c4bfc
rpc: a transaction's own trace carries no output
ColbySerpa Nov 13, 2026
2a86c58
rpc: a block named by an object is read as rskj reads it
ColbySerpa Nov 13, 2026
3b0d096
sync: the pool reckons a transaction's cost in whole numbers
ColbySerpa Nov 13, 2026
c2bd763
rpc: a call's arguments are read as rskj reads them
ColbySerpa Nov 13, 2026
e45e931
rpc: the methods that sign read a request as rskj reads it
ColbySerpa Nov 13, 2026
96e9f53
sync, rpc: a sent transaction is taken or refused as rskj's pool does
ColbySerpa Nov 13, 2026
9ff91d1
rpc, execution: a call and an estimate answer as rskj's release does
ColbySerpa Nov 13, 2026
0bc5b0a
execution: an account below zero acts as rskj's does in a local call
ColbySerpa Nov 13, 2026
010f054
execution: a call to REMASC or the Bridge counts as rskj counts it
ColbySerpa Nov 13, 2026
5b88bd4
execution: the peg events a node records are its blocks' own
ColbySerpa Nov 13, 2026
94a9a43
comments: say what the code and rskj's release do
ColbySerpa Nov 13, 2026
f697fe8
execution: a reverted creation leaves its creator's return data empty
ColbySerpa Nov 13, 2026
094f14a
examples: the replay tools read headers by their network's heights
ColbySerpa Nov 13, 2026
96e621d
bridge: read a Flyover BTC address as rskj does
ColbySerpa Nov 13, 2026
cbfa529
bridge: throw where bitcoinj cannot size a federation input
ColbySerpa Nov 14, 2026
56eda22
execution: a nested constructor's self-destruct keeps its refund
ColbySerpa Nov 14, 2026
6ae00fe
bridge: turn down a peg-in as rskj does when it can't refund it
ColbySerpa Nov 14, 2026
82eba86
bridge: build a one-script slice in a test without a clone
ColbySerpa Nov 14, 2026
efbf930
storage, mining: settle a tie in total difficulty by rskj's selection…
ColbySerpa Nov 14, 2026
d55f6a6
Merge upstream's main at 169ef57
ColbySerpa Nov 14, 2026
aa04535
storage, sync: meet a fork as rskj does, executing every block on arr…
ColbySerpa Nov 14, 2026
ba50bde
CI: run the test suite on macOS and Windows too
ColbySerpa Nov 14, 2026
37483d8
cli: --import, to start from Rootstock's signed state copies as rskj …
ColbySerpa Nov 14, 2026
7d4c4e1
docs: the eleven RSKIPs the audit skipped, read against rskj (#149)
ColbySerpa Nov 15, 2026
9251363
bridge: fail increaseLockingCap where the cap's limit passes a long
ColbySerpa Nov 15, 2026
92e82bb
evm: three call rules as rskj ran them before orchid060, twoToThree a…
ColbySerpa Nov 15, 2026
506343b
execution: a transaction's own call to any precompile, as rskj runs i…
ColbySerpa Nov 15, 2026
729db4d
docs: the 26 rules #149's sort by status left out, read against rskj
ColbySerpa Nov 15, 2026
41a7eed
sync, storage: take up only the switches the store makes, not a batch…
ColbySerpa Nov 15, 2026
dc83713
storage, sync: keep a header completed with its extension, and fetch …
ColbySerpa Nov 15, 2026
f618b84
sync: ask a branch's bodies and headers of another peer when one neve…
ColbySerpa Nov 15, 2026
3842e6e
execution: skip a code header as rskj does (RSKIP-50)
ColbySerpa Nov 15, 2026
5709c71
docs/audit: the status sort read the RSKIPs index of 6 April
ColbySerpa Nov 15, 2026
44e16f5
execution, core, sync: a place for tests ported from rskj's own suite
ColbySerpa Nov 16, 2026
c7e5bf4
execution: rskj's VMExecutionTest, ported
ColbySerpa Nov 16, 2026
a1a52d8
execution: rskj's transient storage tests, ported (RSKIP446)
ColbySerpa Nov 16, 2026
0f8169f
execution: rskj's VMTest, ported
ColbySerpa Nov 16, 2026
2987735
execution: rskj's precompile tests, ported
ColbySerpa Nov 16, 2026
571d3ed
execution: rskj's init code tests, ported (RSKIP438)
ColbySerpa Nov 16, 2026
6a97dfd
execution: rskj's REMASC tests, ported
ColbySerpa Nov 16, 2026
68769d8
execution: the rest of rskj's VM tests, ported
ColbySerpa Nov 16, 2026
2a84914
core: rskj's validator tests, ported
ColbySerpa Nov 16, 2026
b06f023
core: rskj's BlockFactoryTest and header tests, ported
ColbySerpa Nov 16, 2026
4e8bda4
core, execution: rskj's difficulty and init code cost tests, ported
ColbySerpa Nov 16, 2026
c302969
execution, core: rskj's BlockExecutorTest and nonce rule tests, ported
ColbySerpa Nov 16, 2026
3265572
execution: rskj's BridgeTest, ported
ColbySerpa Nov 16, 2026
3fb51fa
execution: rskj's BridgeIT, ported
ColbySerpa Nov 16, 2026
b6833e7
execution: rskj's BridgeSupportFlyoverTest, ported
ColbySerpa Nov 16, 2026
fb70c41
execution: rskj's BridgeUtilsTest, ported
ColbySerpa Nov 16, 2026
43c2d9b
execution: rskj's BridgeUtilsLegacyTest, ported
ColbySerpa Nov 16, 2026
15060b3
execution: rskj's NonStandardErpFederationsTest, ported
ColbySerpa Nov 16, 2026
dd8c275
execution: rskj's PendingFederationTest, ported
ColbySerpa Nov 16, 2026
966a11d
execution: rskj's PegUtilsLegacyTest, ported
ColbySerpa Nov 16, 2026
ca3a8a1
execution, cli: refuse an upgrade schedule the ladder would misread
ColbySerpa Nov 16, 2026
a8b8a1f
evm: tests of STATICCALL on each side of RSKIP91
ColbySerpa Nov 16, 2026
ce0a2bf
evm: tests of CREATE2 at an address in use (RSKIP125)
ColbySerpa Nov 16, 2026
1ea5b78
evm: a word with a bit above its 20 bytes names no precompile
ColbySerpa Nov 16, 2026
85b1516
evm: EXTCODEHASH before RSKIP169 reads the code a creation of the blo…
ColbySerpa Nov 16, 2026
bdf2318
evm: a deployment that fails before RSKIP174 leaves the balance at it…
ColbySerpa Nov 16, 2026
7e927c2
evm: load stored code as its bytes, never as an EIP-7702 designation
ColbySerpa Nov 16, 2026
282457a
evm: take a transaction from an address that holds code, as rskj does
ColbySerpa Nov 16, 2026
0ed040d
evm: rskj's MCOPY tests, ported, and a test of a precompile's output …
ColbySerpa Nov 16, 2026
c6d6f64
execution: derive an HD key from an I_L equal to the curve's order (R…
ColbySerpa Nov 16, 2026
40432fd
execution: tests of the precompile set at each upgrade, and of a poin…
ColbySerpa Nov 16, 2026
9689839
trie: rskj's TrieTreeSizeTest and AccountStateTest, ported
ColbySerpa Nov 16, 2026
e3231ee
core: tests of a receipt's encoding against mainnet's receipts roots
ColbySerpa Nov 16, 2026
9806136
core, execution, sync: tests of RSKIP252's price cap where it starts,…
ColbySerpa Nov 16, 2026
b73e517
core: block 0 keeps its difficulty as its genesis file writes it
ColbySerpa Nov 16, 2026
9d602a5
core: regtest keeps its difficulty divisor under RSKIP156
ColbySerpa Nov 16, 2026
33f5ce5
core: tests of each refusal of the uncle rule
ColbySerpa Nov 16, 2026
185ef08
mining: hold the uncles a block names, and the solved block, to the r…
ColbySerpa Nov 16, 2026
f1136d7
bridge: fail receiveHeaders for a header that counts its transactions…
ColbySerpa Nov 16, 2026
9ff3a20
bridge: a peg-in with an output bitcoinj can't parse has an invalid p…
ColbySerpa Nov 16, 2026
01c2dbf
bridge: a Flyover payment with an output that is no address fails bef…
ColbySerpa Nov 16, 2026
5e44972
bridge: tests of the call a confirmed peg-out is signed under, and of…
ColbySerpa Nov 16, 2026
6a3c561
sync: take and relay a block a peer sends whole only if it is later t…
ColbySerpa Nov 16, 2026
9d719bd
cli: build the miner's block processor as the node's, with fork detec…
ColbySerpa Nov 16, 2026
f6fb6fa
cli: write block 0 again in a store that holds it without its difficu…
ColbySerpa Nov 16, 2026
69d3b1f
sync: hold a snapshot's blocks to the rules rskj's snapshot client ho…
ColbySerpa Nov 16, 2026
4bdb1d0
execution: a folder for rskj's tests of the federation's stored state
ColbySerpa Nov 16, 2026
40603ad
bridge: take a federation change vote as rskj does
ColbySerpa Nov 16, 2026
71dd6d4
bridge: build a funds migration as rskj does
ColbySerpa Nov 16, 2026
941f859
bridge: answer getActiveFederationCreationBlockHeight as rskj does (R…
ColbySerpa Nov 16, 2026
0190bfa
bridge: sort a registration below the pegout index as rskj's PegUtils…
ColbySerpa Nov 16, 2026
e2b2d9d
bridge: answer -4 to a new federation while one is proposed (RSKIP419)
ColbySerpa Nov 16, 2026
34f6e69
bridge: look up a Bitcoin block by hash in the Bridge's storage alone
ColbySerpa Nov 16, 2026
ba78001
bridge: tests of RSKIP293, RSKIP377 and a reed800 federation of 20
ColbySerpa Nov 16, 2026
045eade
remasc: pay from the executing block's own chain
ColbySerpa Nov 16, 2026
60576c0
execution: apply RSKIP174 to local calls, traces and estimates
ColbySerpa Nov 16, 2026
139f4b4
mining: hold the gas limit target to the minimum gas limit
ColbySerpa Nov 16, 2026
0de38cb
mining: a test of REMASC's transaction in a full sequential sublist
ColbySerpa Nov 16, 2026
b1d0beb
core: read a genesis file as rskj's GenesisLoaderImpl does
ColbySerpa Nov 16, 2026
eed75e1
mining: answer a solved block a rule refuses as rskj does
ColbySerpa Nov 16, 2026
7424337
trie: refuse a node message with bytes after its long value's length
ColbySerpa Nov 16, 2026
190d802
sync: a test of the pool's prices by the head's upgrades
ColbySerpa Nov 16, 2026
5d0041d
execution: rskj's tests of five federation state classes, ported
ColbySerpa Nov 16, 2026
07e6484
execution: rskj's tests of eight peg-in classes, ported
ColbySerpa Nov 16, 2026
c6b1382
execution: rskj's tests of the Bridge's peg-out classes, ported
ColbySerpa Nov 16, 2026
6a2287d
execution: answer BLOCKHASH from the run block's own ancestors
ColbySerpa Nov 16, 2026
eda8866
mining: keep a solution on a parent the chain left beside the chain
ColbySerpa Nov 16, 2026
a4d2bc6
mining: record the peg decisions of a block this node mines
ColbySerpa Nov 16, 2026
695b78f
bridge: read a federator's signature as Spongy Castle 1.58 reads it
ColbySerpa Nov 17, 2026
6b11a5b
bridge: walk the confirmed peg-outs as rskj's set grows in the call
ColbySerpa Nov 17, 2026
6354e0d
bridge: write the release request queue back after the methods that r…
ColbySerpa Nov 17, 2026
458de42
bridge: leave out of getStateForDebugging the entries of the other en…
ColbySerpa Nov 17, 2026
5790402
execution: rskj's tests of releaseBtc under RSKIP185, ported
ColbySerpa Nov 17, 2026
865a858
bridge: size a segwit federation's peg-out by its weight (RSKIP271)
ColbySerpa Nov 17, 2026
7c62752
bridge: batch peg-out requests as rskj's processPegoutsInBatch does
ColbySerpa Nov 17, 2026
a957d39
bridge: sign a segwit input only over the value kept for it (RSKIP305)
ColbySerpa Nov 17, 2026
4640480
execution: rskj's PocSighashTest, ported
ColbySerpa Nov 17, 2026
ab42a77
bridge: refuse a confirmed peg-out as RSKIP375 refuses it
ColbySerpa Nov 17, 2026
19b0bf1
execution: rskj's BitcoinUtilsLegacyTest, ported, and a test of the S…
ColbySerpa Nov 17, 2026
45cfe5d
execution: rskj's BridgeSupportGetEstimatedFeesTest, ported, and more…
ColbySerpa Nov 17, 2026
51fa166
bridge: fail the contract that asks releaseBtc for a peg-out before R…
ColbySerpa Nov 17, 2026
f8a62e6
bridge: write back the set waiting for signatures that addSignature read
ColbySerpa Nov 17, 2026
2c74396
bridge: refuse a checkpoint whose chain work is past 12 bytes before …
ColbySerpa Nov 17, 2026
f598023
bridge: read a registered witness root only from RSKIP143
ColbySerpa Nov 17, 2026
6cc4d6d
bridge: log a federator's key as the federation keeps it, and refuse …
ColbySerpa Nov 17, 2026
769b40c
bridge: fail addSignature where an input has no redeem script, as rsk…
ColbySerpa Nov 17, 2026
6b6945e
bridge: read a federator's signature in a module of its own
ColbySerpa Nov 17, 2026
f7dbbc7
bridge: read a federator's signature as Bouncy Castle 1.58 reads it
ColbySerpa Nov 17, 2026
ae7e7bd
sync: remove the empty place for rskj's tests
ColbySerpa Nov 17, 2026
9125262
bridge: take a federation member's key of the one byte 00, as rskj does
ColbySerpa Nov 17, 2026
521961c
bridge: write the new federation back after any call that read it
ColbySerpa Nov 17, 2026
2daf195
bridge: save nothing after a call answered with null before RSKIP88
ColbySerpa Nov 17, 2026
e482b53
bridge: write back the federations' UTXOs where a call read them
ColbySerpa Nov 17, 2026
0b6c84b
bridge: write back what the state getters read, before RSKIP88
ColbySerpa Nov 17, 2026
bdc1dfa
bridge: look a federator up by its key as rskj does when it signs
ColbySerpa Nov 17, 2026
1997690
execution: keep what a free Bridge call logged before it threw
ColbySerpa Nov 17, 2026
26231f7
sync: run block 1 in follow mode on a new database
ColbySerpa Nov 17, 2026
ba403d6
mining: a timed miner started again at once runs one thread
ColbySerpa Nov 17, 2026
0904268
mining: evm_increaseTime ignores a move of no seconds or fewer, as rskj
ColbySerpa Nov 17, 2026
8a00981
docs: rskj's release tests by area, and the 70 RSKIPs read against rskj
ColbySerpa Nov 17, 2026
bc79d24
miner: answer a solved block the store fails to take as rskj does
ColbySerpa Nov 18, 2026
bd757dd
docs: the submit path in rskj's order, and what a pool is answered
ColbySerpa Nov 18, 2026
eb1326b
miner: steer the gas limit as rskj does, with its two settings
ColbySerpa Nov 18, 2026
1c99ce9
miner: a stable minimum gas price, as rskj's miner.stableGasPrice
ColbySerpa Nov 18, 2026
71da132
cli: let a new database start on the default trie backend
ColbySerpa Nov 18, 2026
846edc6
bridge: port rskj's two tests of a Flyover refund from both federations
ColbySerpa Nov 18, 2026
12312ec
Merge upstream's main at 640dfb9
ColbySerpa Nov 18, 2026
59d8cd4
cli: the external-IP lookup's tests on Windows
ColbySerpa Nov 18, 2026
442c987
Merge branch 'main' into parity
SDL-A1 Nov 18, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
21 changes: 21 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,27 @@ jobs:
- name: Test
run: cargo test --locked ${{ matrix.features.crate }} ${{ matrix.features.flags }}

# The node also runs on macOS and Windows, which the job above never
# builds on. The whole suite runs on both, default features: hashing,
# decoding and the consensus rules must give the same answers on every
# platform, and file handling, paths and line endings are where they can
# part. Clippy and the smtp build stay on Linux; neither differs by OS.
test-platforms:
name: Test (${{ matrix.os }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [macos-latest, windows-latest]
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@1.93.1
- uses: Swatinem/rust-cache@v2
- name: Build
run: cargo build --locked --workspace
- name: Test
run: cargo test --locked --workspace

clippy:
name: Clippy
runs-on: ubuntu-latest
Expand Down
3 changes: 3 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,9 @@ ripemd = "0.1"
futures = "0.3.31"
rocksdb = "0.25.0"
libc = "0.2"
# rskj's BigInteger, for what a header holds at any size: the rules that
# bound its gas limit read the whole value.
num-bigint = "0.4.6"

[profile.dev]
# Line tables only: backtraces keep file and line numbers, but the type and
Expand Down
45 changes: 36 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,25 @@ cargo test --workspace

786 tests covering consensus validation, RLP encoding, P2P handshakes, sync state machines, storage, the Unitrie, EVM execution, every RSK precompile (including the full Bridge surface and REMASC), the transaction pool, RPC methods, transaction relay, and chain reorganizations.

### Starting from Rootstock's published state

Rootstock publishes signed copies of the mainnet and testnet state for rskj's
`--import`, and `--import` here does what rskj's does: it reads each trusted
signer's index, takes the newest copy that more than half of them sign, checks
those signatures and the copy's SHA-256, loads its blocks and state, and starts
the node from there.

```bash
rustock --import --data-dir ./data
```

The data directory must not hold a chain: where rskj deletes one, rustock
refuses. Mainnet's copy at #9,405,000 downloaded in about two minutes and
loaded in 18 seconds, and the node then caught up with the network in about one.
`--import-url` and `--import-trusted-key` point it at another network's copies;
[`crates/cli/src/bootstrap_import.rs`](crates/cli/src/bootstrap_import.rs) says
what it checks.

### Importing from rskj

A synced rskj database can be imported instead of syncing from peers — about an
Expand All @@ -150,15 +169,14 @@ independent cross-check.

### A regtest chain rskj runs

rustock's regtest is its own chain: its own genesis, no Bridge federation, and
gas limits of its own. To run the chain an rskj regtest node runs, so that
blocks rskj mined connect here, start from rskj's genesis file and its rules:
rustock's regtest is its own chain: its own genesis and no Bridge federation.
To run the chain an rskj regtest node runs, so that blocks rskj mined connect
here, start from rskj's genesis file and its rules:

```bash
rustock --network-id 33 \
--genesis genesis.json \
--consensus-rule rskip97=0 \
--min-gas-limit 3000000 --max-gas-limit 18446744073709551615 \
--skip-pow-validation
```

Expand All @@ -184,11 +202,10 @@ rustock --network-id 30 --allow-chain-overrides \

The overrides reach everything that reads the schedule: header decoding and
hashing, difficulty, execution, REMASC and the Bridge. Names the node reads at
one fixed height per chain (`bahamas`, `afterBridgeSync`, `hop401`) are
accepted at that height only; `orchid060` and `tbd1000` are accepted and
change nothing, and the node says so (`tbd1000` only turns on RSKIP-559,
pegout sorting in the Bridge, which it does not implement). A node started
this way must not follow the real network.
one fixed height per chain (`bahamas`, `orchid060`, `hop401`) are accepted at
that height only; `tbd1000` is accepted and changes nothing, and the node says
so (it only turns on RSKIP-559, pegout sorting in the Bridge, which the node
does not implement). A node started this way must not follow the real network.

Blocks rskj exported with its `ExportBlocks` tool (`number,hash,td,rlp` per
line, plain or gzipped) can then be imported from an empty data directory:
Expand Down Expand Up @@ -276,6 +293,16 @@ The RPC server is compatible with rskj's JSON-RPC 2.0 interface. Supported metho

- `eth_getBalance`, `eth_getTransactionCount`, `eth_getCode`, `eth_getStorageAt`

**For light clients** (rustock's own, not rskj's: what a relay answers a light client from, which checks every byte itself):

- `rsk_getStorageNodes(address, [slots], block)`: for each slot, whether it's held, its value, and the unitrie nodes from
the slot's key, or from where the key leaves the trie, up to the block's state root
- `rsk_getStateNodes(blockHash, [keys])`: for each raw unitrie key, the nodes from where its walk ends up to the state root
of that block, or null if the node doesn't hold that state
- `rsk_getBlockNumberByHash(hash)`: the block's number on the chain the node follows, or null
- `rsk_getRawBlocks(from, to)`: one run of that chain, at most 1,000 blocks, each its header compressed, as rskj sends a
chain's headers to its peers, and its uncles in full

**Execution:**

- `eth_call`, `eth_estimateGas` (run against a forked state with full precompile and Bridge support)
Expand Down
10 changes: 8 additions & 2 deletions crates/alerts/src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -576,11 +576,13 @@ impl Config {
/// may be quoted, and a `export ` prefix is tolerated so the same file can be
/// sourced by a shell.
fn read_env_file(path: &Path) -> anyhow::Result<std::collections::HashMap<String, String>> {
let meta = std::fs::metadata(path)
.map_err(|e| anyhow::anyhow!("reading {}: {e}", path.display()))?;
// Group and other permissions are Unix mode bits. Windows keeps access in
// ACLs, which this does not read, so there the file is not checked.
#[cfg(unix)]
{
use std::os::unix::fs::PermissionsExt;
let meta = std::fs::metadata(path)
.map_err(|e| anyhow::anyhow!("reading {}: {e}", path.display()))?;
let mode = meta.permissions().mode() & 0o077;
if mode != 0 {
// Refuse rather than warn: a credential readable by other users on
Expand Down Expand Up @@ -801,6 +803,8 @@ mod secret_tests {
use std::os::unix::fs::PermissionsExt;
std::fs::set_permissions(f.path(), std::fs::Permissions::from_mode(mode)).unwrap();
}
#[cfg(not(unix))]
let _ = mode;
f
}

Expand All @@ -825,6 +829,8 @@ mod secret_tests {
assert_eq!(c.email.password.as_deref(), Some("s3cr3t"));
}

/// Unix only: the refusal reads mode bits, which Windows does not have.
#[cfg(unix)]
#[test]
fn a_world_readable_env_file_is_refused() {
let f = env_file("SMTP_PASSWORD=s3cr3t\n", 0o644);
Expand Down
1 change: 1 addition & 0 deletions crates/alerts/tests/contract_value.rs
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ fn header(number: u64) -> Header {
bitcoin_merged_mining_coinbase_transaction: None,
cached_hash: None,
cached_hash_for_merged_mining: None,
kept: None,
}
}

Expand Down
9 changes: 6 additions & 3 deletions crates/cli/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,14 @@ rocksdb = { workspace = true }
libc = { workspace = true }
alloy-rlp = { workspace = true }
flate2 = "1"
# HTTPS client for the external-IP lookup (src/public_ip.rs): rustls with the
# ring provider and Mozilla's root store, not the lettre/smtp stack.
# HTTPS client for the external-IP lookup (src/public_ip.rs) and for --import
# (src/https.rs): rustls with the ring provider and Mozilla's root store, not
# the lettre/smtp stack. --import fetches Rootstock's signed state copies as
# rskj's does, with the signers' index.json and the copy's SHA-256.
tokio-rustls = { version = "0.26", default-features = false, features = ["ring", "tls12"] }
webpki-roots = "1"
serde_json = "1"
sha2 = { workspace = true }

[features]
# Enable outgoing email for peg-out alerts (adds the SMTP transport to the
Expand All @@ -47,7 +51,6 @@ smtp = ["rustock-alerts/smtp"]

[dev-dependencies]
tempfile = { workspace = true }
serde_json = "1"
# For the examples that decode a peg-in's bitcoin transaction straight out of
# the call data, without executing the block. `validation_cost` also reaches
# through it for `secp256k1`, the rust-bitcoin bindings to the C
Expand Down
3 changes: 2 additions & 1 deletion crates/cli/examples/block_writes.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,12 @@ fn main() -> Result<()> {
let number: u64 = args.next().ok_or_else(|| anyhow::anyhow!(USAGE))?.parse()?;
let network_id: u64 = args.next().map(|a| a.parse()).transpose()?.unwrap_or(support::MAINNET);
let trie_dir = args.next();
// Before the stores open: headers are read by the network's heights.
let hardfork_cfg = support::hardfork_for(network_id);

let replay = Replay::open(&data_dir, trie_dir.as_deref())?;
replay.ensure_replayable(number)?;

let hardfork_cfg = support::hardfork_for(network_id);
eprintln!(
"replaying #{}..=#{number} on network-id {network_id} (chain_id {})",
replay.exec_number + 1,
Expand Down
3 changes: 2 additions & 1 deletion crates/cli/examples/diff_state.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,13 @@ fn main() -> Result<()> {
let rskj_dir = args.next().ok_or_else(|| anyhow::anyhow!(USAGE))?;
let network_id: u64 = args.next().map(|a| a.parse()).transpose()?.unwrap_or(support::MAINNET);
let trie_dir = args.next();
// Before the stores open: headers are read by the network's heights.
let hardfork_cfg = support::hardfork_for(network_id);

// --- rustock side: replay to <number>, get the computed post-state trie ---
let replay = Replay::open(&data_dir, trie_dir.as_deref())?;
replay.ensure_replayable(number)?;

let hardfork_cfg = support::hardfork_for(network_id);
eprintln!("replaying on network-id {network_id} (chain_id {})", hardfork_cfg.chain_id);
let processor = BlockProcessor::new(hardfork_cfg, replay.store.clone());

Expand Down
45 changes: 27 additions & 18 deletions crates/cli/examples/loadtest.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,9 @@
//! **Proof of work costs the same at any difficulty**, which is what makes
//! this affordable: verification decodes the Bitcoin header, hashes it and
//! compares against the target, and none of those depend on how hard the
//! target is. The blocks are sealed at difficulty 1, where the target is
//! `U256::MAX` and the first nonce tried always clears it, so sealing
//! costs nothing and verifying costs exactly what it costs on mainnet.
//! Difficulty 0 would be cheaper still and is not allowed -- the rule
//! rejects it with `DifficultyZero` before doing any work, which would
//! measure nothing.
//! target is. The blocks are sealed at difficulty 1, where rskj's target is
//! 2^256 / 3: one hash in three meets it, so sealing takes a few nonces and
//! verifying costs exactly what it costs on mainnet.
//!
//! Sealing is deliberately **outside** the timed region. A node receives
//! blocks already mined; making one is not a cost it pays.
Expand Down Expand Up @@ -221,11 +218,7 @@ fn main() -> Result<()> {
// Regtest's activation heights are all zero, so every rule -- orchid,
// wasabi100, iris300 -- is live from block one. On mainnet's heights a
// 40-block run would skip merged mining entirely and measure nothing.
// Regtest's bounds, with the gas limit raised to the one the
// benchmark's headers have always carried. Changing the header
// instead would move every figure already recorded, and the bound is
// not what is being measured.
let chain = Arc::new(ChainConfig { max_gas_limit: 100_000_000, ..ChainConfig::regtest() });
let chain = Arc::new(ChainConfig::regtest());
let header_verifier = HeaderVerifier::default_rsk(chain.clone());
let block_verifier = BlockVerifier::default_rsk(&chain);

Expand Down Expand Up @@ -774,12 +767,14 @@ fn remasc_tx() -> Transaction {
///
/// Not a cost a node pays -- it receives blocks already mined -- so this
/// runs outside the timed region. It is here because verification has
/// nothing to verify without it, and because at `difficulty: 1` the
/// target is `U256::MAX`, so the first nonce tried clears it and sealing
/// is a handful of hashes rather than a search. Verification does the
/// same work it would against a real mainnet target.
/// nothing to verify without it, and because at `difficulty: 1` rskj's
/// target is 2^256 / 3, which one hash in three meets, so sealing is a few
/// nonces rather than a search. Verification does the same work it would
/// against a real mainnet target.
fn seal_merged_mining(header: &mut Header) -> Result<()> {
use rustock_core::validation::merged_mining::compress_coinbase;
use bitcoin::hashes::Hash as _;
use rustock_core::validation::fork_detection::REQUIRED_BLOCKS;
use rustock_core::validation::merged_mining::{compress_coinbase, difficulty_to_target};
use rustock_execution::mining::{coinbase, fork_detection, merkle};

// The coinbase commits to the header's merged-mining hash, which is
Expand All @@ -788,10 +783,23 @@ fn seal_merged_mining(header: &mut Header) -> Result<()> {
// hash is the one from before the transaction root was set.
header.cached_hash = None;
header.cached_hash_for_merged_mining = None;
let payload = fork_detection::apply_to_hash(header.hash_for_merged_mining(), &[0u8; 12]);
// From block 449 the hash's last twelve bytes are fork-detection data,
// and any twelve do here: this measures proof of work, not fork
// detection. Below 449 rskj wants the whole hash.
let fork_data: &[u8] = if header.number >= REQUIRED_BLOCKS {
&[0u8; 12]
} else {
&[]
};
let payload = fork_detection::apply_to_hash(header.hash_for_merged_mining(), fork_data);

let cb = coinbase::build_coinbase(&payload, 0);
let btc = coinbase::build_bitcoin_block(cb.clone(), 0);
// One hash in three meets rskj's target at difficulty 1, 2^256 / 3.
let target = difficulty_to_target(header.difficulty);
let btc = (0..=u32::MAX)
.map(|nonce| coinbase::build_bitcoin_block(cb.clone(), nonce))
.find(|block| U256::from_le_slice(block.header.block_hash().as_byte_array()) <= target)
.context("no nonce meets the target")?;
let compressed = compress_coinbase(&coinbase::encode_transaction(&cb), true)
.map_err(|e| anyhow::anyhow!("compressing the coinbase: {e}"))?;
let proof = merkle::proof_from_txids(&coinbase::txids_display_order(&btc))
Expand Down Expand Up @@ -877,6 +885,7 @@ fn bench_header(number: u64, parent_hash: B256, state_root: B256, edges: Vec<i16
bitcoin_merged_mining_coinbase_transaction: None,
cached_hash: None,
cached_hash_for_merged_mining: None,
kept: None,
}
}

Expand Down
3 changes: 2 additions & 1 deletion crates/cli/examples/replay_block.rs
Original file line number Diff line number Diff line change
Expand Up @@ -42,11 +42,12 @@ fn main() -> Result<()> {
// Default mainnet so existing invocations are unchanged.
let network_id: u64 = args.next().map(|a| a.parse()).transpose()?.unwrap_or(support::MAINNET);
let trie_dir = args.next();
// Before the stores open: headers are read by the network's heights.
let hardfork_cfg = support::hardfork_for(network_id);

let replay = Replay::open(&data_dir, trie_dir.as_deref())?;
replay.ensure_replayable(number)?;

let hardfork_cfg = support::hardfork_for(network_id);
eprintln!("replaying on network-id {network_id} (chain_id {})", hardfork_cfg.chain_id);
let processor = BlockProcessor::new(hardfork_cfg, replay.store.clone());

Expand Down
Loading
Loading