Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clean the Monero lib for auditing #577

Merged
merged 67 commits into from
Jul 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
67 commits
Select commit Hold shift + click to select a range
98b08ea
Remove unsafe creation of dalek_ff_group::EdwardsPoint in BP+
kayabaNerve Apr 22, 2024
f5d9d03
Rename Bulletproofs to Bulletproof, since they are a single Bulletproof
kayabaNerve Apr 22, 2024
cd8b054
Make CLSAG signing private
kayabaNerve Apr 22, 2024
f1ad768
Remove the distribution cache
kayabaNerve Apr 22, 2024
c165c36
Tidy Borromean/MLSAG a tad
kayabaNerve Apr 22, 2024
d2a27dc
Remove experimental feature from monero-serai
kayabaNerve Apr 22, 2024
a1d1de0
Move amount_decryption into EncryptedAmount::decrypt
kayabaNerve Apr 22, 2024
5cdae6e
Various RingCT doc comments
kayabaNerve Apr 23, 2024
784a273
Begin crate smashing
kayabaNerve Jun 13, 2024
9c21791
Further documentation, start shoring up API boundaries of existing cr…
kayabaNerve Jun 14, 2024
865dee8
Document and clean clsag
kayabaNerve Jun 14, 2024
798ffc9
Add a dedicated send/recv CLSAG mask struct
kayabaNerve Jun 14, 2024
f7c13fd
Smash out monero-bulletproofs
kayabaNerve Jun 15, 2024
d9107b5
Correct no-std builds for monero-clsag and monero-bulletproofs
kayabaNerve Jun 15, 2024
77a2496
Tidy and document monero-bulletproofs
kayabaNerve Jun 16, 2024
60d5c06
Error if missing documentation
kayabaNerve Jun 16, 2024
303e72c
Smash out MLSAG
kayabaNerve Jun 16, 2024
3e82ee6
Smash out Borromean
kayabaNerve Jun 16, 2024
3a1c6c7
Tidy up monero-serai as a meta crate
kayabaNerve Jun 16, 2024
d740bd2
Smash out RPC, wallet
kayabaNerve Jun 16, 2024
08b95ab
Document the RPC
kayabaNerve Jun 16, 2024
6f61861
Improve docs a bit
kayabaNerve Jun 19, 2024
b5b9d4a
Move Protocol to monero-wallet
kayabaNerve Jun 21, 2024
1db4091
Incomplete work on using Option to remove panic cases
kayabaNerve Jun 22, 2024
74aaac4
Finish documenting monero-serai
kayabaNerve Jun 22, 2024
6fc8b30
Remove TODO on reading pseudo_outs for AggregateMlsagBorromean
kayabaNerve Jun 22, 2024
df095f0
Only read transactions with one Input::Gen or all Input::ToKey
kayabaNerve Jun 22, 2024
1e2e3bd
Smash out polyseed
kayabaNerve Jun 23, 2024
11dba91
Smash out seed
kayabaNerve Jun 23, 2024
0b20004
Get the repo to compile again
kayabaNerve Jun 23, 2024
eb0c19b
Smash out Monero addresses
kayabaNerve Jun 23, 2024
0f47753
Document cargo features
kayabaNerve Jun 24, 2024
b3b0edb
Fix deserializing v2 miner transactions
kayabaNerve Jun 25, 2024
70c36ed
Rewrite monero-wallet's send code
kayabaNerve Jun 27, 2024
abd48e9
Add SignableTransaction Read/Write
kayabaNerve Jun 28, 2024
08d604f
Restore Monero multisig TX code
kayabaNerve Jun 28, 2024
891362a
Correct invalid RPC type def in monero-rpc
kayabaNerve Jun 28, 2024
8319d21
Update monero-wallet tests to compile
kayabaNerve Jun 28, 2024
69e077b
Clean and document monero-address
kayabaNerve Jul 1, 2024
0624661
Sync rest of repo with monero-serai changes
kayabaNerve Jul 1, 2024
64e74c5
Represent height/block number as a u32
kayabaNerve Jul 2, 2024
daa0f8f
Diversify ViewPair/Scanner into ViewPair/GuaranteedViewPair and Scann…
kayabaNerve Jul 3, 2024
b56c6fb
Remove non-small-order view key bound
kayabaNerve Jul 3, 2024
08169e2
Finish documenting monero-serai
kayabaNerve Jul 4, 2024
3de89c7
Correct imports for no-std
kayabaNerve Jul 4, 2024
0f9a5af
Remove possible panic in monero-serai on systems < 32 bits
kayabaNerve Jul 4, 2024
e94a04d
Restore the reserialize chain binary
kayabaNerve Jul 4, 2024
90880cc
fmt, machete, GH CI
kayabaNerve Jul 5, 2024
1f5e5fc
Correct misc TODOs in monero-serai
kayabaNerve Jul 6, 2024
04df229
Have Monero test runner evaluate an Eventuality for all signed TXs
kayabaNerve Jul 6, 2024
788c4fc
Fix a pair of bugs in the decoy tests
kayabaNerve Jul 6, 2024
b2c962c
Fix remaining bugs in monero-wallet tests
kayabaNerve Jul 6, 2024
d847ec5
Reject torsioned spend keys to ensure we can spend the outputs we scan
kayabaNerve Jul 6, 2024
0631607
Tidy inlined epee code in the RPC
kayabaNerve Jul 6, 2024
2334725
Correct the accidental swap of stagenet/testnet address bytes
kayabaNerve Jul 6, 2024
6357bc0
Remove unused dep from processor
kayabaNerve Jul 6, 2024
9f7dbf2
Handle Monero fee logic properly in the processor
kayabaNerve Jul 6, 2024
c138950
Document v2 TX/RCT output relation assumed when scanning
kayabaNerve Jul 6, 2024
3cf0b84
Adjust how we mine the initial blocks due to some CI test failures
kayabaNerve Jul 7, 2024
4743ea7
Fix weight estimation for RctType::ClsagBulletproof TXs
kayabaNerve Jul 7, 2024
d99ed96
Again increase the amount of blocks we mine prior to running tests
kayabaNerve Jul 7, 2024
86facae
Correct the if check about when to mine blocks on start
kayabaNerve Jul 7, 2024
c521bbb
Run Monero on Debian, even for internal testnets
kayabaNerve Jul 7, 2024
1bfd7d9
Don't attempt running tests on the verify-chain binary
kayabaNerve Jul 7, 2024
9e4d83b
Increase minimum Monero fee in processor
kayabaNerve Jul 7, 2024
d88bd70
Distinguish fee from necessary_fee in monero-wallet
kayabaNerve Jul 7, 2024
6994d93
Restore minimum Monero fee from develop
kayabaNerve Jul 7, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 16 additions & 1 deletion .github/workflows/coins-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,5 +32,20 @@ jobs:
-p bitcoin-serai \
-p alloy-simple-request-transport \
-p ethereum-serai \
-p serai-ethereum-relayer \
-p monero-io \
-p monero-generators \
-p monero-serai
-p monero-primitives \
-p monero-mlsag \
-p monero-clsag \
-p monero-borromean \
-p monero-bulletproofs \
-p monero-serai \
-p monero-rpc \
-p monero-simple-request-rpc \
-p monero-address \
-p monero-wallet \
-p monero-seed \
-p polyseed \
-p monero-wallet-util \
-p monero-serai-verify-chain
2 changes: 1 addition & 1 deletion .github/workflows/coordinator-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,4 +37,4 @@ jobs:
uses: ./.github/actions/build-dependencies

- name: Run coordinator Docker tests
run: cd tests/coordinator && GITHUB_CI=true RUST_BACKTRACE=1 cargo test --all-features
run: GITHUB_CI=true RUST_BACKTRACE=1 cargo test --all-features -p serai-coordinator-tests
2 changes: 1 addition & 1 deletion .github/workflows/full-stack-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,4 @@ jobs:
uses: ./.github/actions/build-dependencies

- name: Run Full Stack Docker tests
run: cd tests/full-stack && GITHUB_CI=true RUST_BACKTRACE=1 cargo test --all-features
run: GITHUB_CI=true RUST_BACKTRACE=1 cargo test --all-features -p serai-full-stack-tests
2 changes: 1 addition & 1 deletion .github/workflows/message-queue-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,4 +33,4 @@ jobs:
uses: ./.github/actions/build-dependencies

- name: Run message-queue Docker tests
run: cd tests/message-queue && GITHUB_CI=true RUST_BACKTRACE=1 cargo test --all-features
run: GITHUB_CI=true RUST_BACKTRACE=1 cargo test --all-features -p serai-message-queue-tests
31 changes: 26 additions & 5 deletions .github/workflows/monero-tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,22 @@ jobs:
uses: ./.github/actions/test-dependencies

- name: Run Unit Tests Without Features
run: GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-serai --lib
run: |
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-io --lib
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-generators --lib
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-primitives --lib
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-mlsag --lib
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-clsag --lib
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-borromean --lib
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-bulletproofs --lib
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-serai --lib
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-rpc --lib
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-simple-request-rpc --lib
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-address --lib
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-wallet --lib
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-seed --lib
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package polyseed --lib
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-wallet-util --lib

# Doesn't run unit tests with features as the tests workflow will

Expand All @@ -46,11 +61,17 @@ jobs:
monero-version: ${{ matrix.version }}

- name: Run Integration Tests Without Features
# Runs with the binaries feature so the binaries build
# https://github.com/rust-lang/cargo/issues/8396
run: GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-serai --features binaries --test '*'
run: |
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-serai --test '*'
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-simple-request-rpc --test '*'
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-wallet --test '*'
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-wallet-util --test '*'

- name: Run Integration Tests
# Don't run if the the tests workflow also will
if: ${{ matrix.version != 'v0.18.2.0' }}
run: GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-serai --all-features --test '*'
run: |
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-serai --all-features --test '*'
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-simple-request-rpc --test '*'
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-wallet --all-features --test '*'
GITHUB_CI=true RUST_BACKTRACE=1 cargo test --package monero-wallet-util --all-features --test '*'
2 changes: 1 addition & 1 deletion .github/workflows/no-std.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,4 @@ jobs:
run: sudo apt update && sudo apt install -y gcc-riscv64-unknown-elf gcc-multilib && rustup target add riscv32imac-unknown-none-elf

- name: Verify no-std builds
run: cd tests/no-std && CFLAGS=-I/usr/include cargo build --target riscv32imac-unknown-none-elf
run: CFLAGS=-I/usr/include cargo build --target riscv32imac-unknown-none-elf -p serai-no-std-tests
2 changes: 1 addition & 1 deletion .github/workflows/processor-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,4 +37,4 @@ jobs:
uses: ./.github/actions/build-dependencies

- name: Run processor Docker tests
run: cd tests/processor && GITHUB_CI=true RUST_BACKTRACE=1 cargo test --all-features
run: GITHUB_CI=true RUST_BACKTRACE=1 cargo test --all-features -p serai-processor-tests
2 changes: 1 addition & 1 deletion .github/workflows/reproducible-runtime.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,4 +33,4 @@ jobs:
uses: ./.github/actions/build-dependencies

- name: Run Reproducible Runtime tests
run: cd tests/reproducible-runtime && GITHUB_CI=true RUST_BACKTRACE=1 cargo test --all-features
run: GITHUB_CI=true RUST_BACKTRACE=1 cargo test --all-features -p serai-reproducible-runtime-tests
Loading
Loading