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

cryptonote_basic: split transaction into transaction_uncached #47

Draft
wants to merge 314 commits into
base: master
Choose a base branch
from

Conversation

jeffro256
Copy link

This PR will let us make a tx variant that doesn't require that we write new cryptonote tx structs, but also lets us drop internal caches (for the most part, there's still stuff in rct::rctSig.

Leaving this PR here for now since it would mainly just be useful for Seraphis migration.

luigi1111 and others added 30 commits June 27, 2023 11:36
24d56c5 bump lmdb sync threshold for performance (moneromooo-monero)
7206ef8 cryptonote_basic: fix amount overflow detection on 32-bit systems (jeffro256)
6b8dfb8 daemon: remove os-version (tobtoht)
bb83eb1 daemon: remove --fluffy-blocks (tobtoht)
360a145 utils: remove munin_plugins (tobtoht)
f7deb7d tests: remove daemon_tests (tobtoht)
25a803f tests: remove unused perl scripts (tobtoht)
c430ba9 depends: update expat to 2.5.0 (tobtoht)
9f80797 protocol: drop peers sending duplicate txes (moneromooo-monero)
2c98a82 Add byte_stream �alue_type and data() (Lee *!* Clagett)
eb94356 Add to_hex::buffer (Lee *!* Clagett)
ec0cdc4 depends: remove icu4c (tobtoht)
eeda4a8 wallet2: do not lose exception in current thread on refresh (Crypto City
 f868768 wallet2: fix missing exceptions from failing wallet refresh (Crypto City)
Looks like the extra MWARNING was supposed to be guarded by the if statement.
Add help for max-reorg-depth and load-deprecated-formats options
All the files in src/platform are currently unused and unnecessary. See below:

* `mingw/alloca.h`: unused throughout project
* `msc/sys/param.h`:
    1. In `fix_darwin.patch`, `sys/param.h` is well-defined to be used only in OpenBSD environment
    2. `int-util.h` already handles when `sys/param.h` is not present and injects its own values
    3. `db_drivers/liblmdb/mdb.c` is a similar situation: already explicity handles different platforms
    4. `src/crypto/chacha.h` uses `int-util.h` for endianness context
* `msc/alloca.h`: unused
* `msc/inline_c.h`: not needed. the `inline` keyword is supported for C99 I believe, and certainly for C11, C14+
* `msc/stdbool.h`: `stdbool.h` is standard since C99, and MSVC has supported it for a long time (~10 years)
Co-authored-by: j-berman <justinberman@protonmail.com>
a6639df wallet_rpc_server: dedup transfer RPC responses (jeffro256)
Very special PR.
ce86368 Remove src/platform (Jeffrey)
70bbd25 core_rpc_server: new file: rpc_ssl.fingerprint (Jeffrey Ryan)
16d17f6 add crypto/generators for direct access to canonical fixed generators (koe)
a668312 wallet: remove CLI code for non default ring sizes (Jeffro256)
d391ac0 blockchain: ensure base fee cannot reach 0 (Crypto City)
d9c7cd5 common: do not use DNS to determine if address is local (tobtoht)
jeffro256 and others added 29 commits February 24, 2024 11:24
Example usage for Seraphis types (in global or `sp` namespace):

```
BEGIN_SERIALIZE_OBJECT_FN(sp::SpCoinbaseEnoteCore)
    FIELD_F(onetime_address)
    VARINT_FIELD_F(amount)
END_SERIALIZE()

BEGIN_SERIALIZE_OBJECT_FN(sp::SpEnoteCore)
    FIELD_F(onetime_address)
    FIELD_F(amount_commitment)
END_SERIALIZE()
```
Nodes who see different txs in a double spend attack will drop each other, splitting the network.
Issue found by @Boog900.
5f1b5c2 depends: eudev: update to 3.2.14 (tobtoht)
442146a depends: libusb: update to 1.0.27 (tobtoht)
0c9a5c5 depends: remove ccache (tobtoht)
119e341 depends: remove unwind (tobtoht)
1bc09fc depends: add riscv64 to gitignore (tobtoht)
e499e74 actions: update to v4 actions (tobtoht)
7043238 Remove instructions for Void Linux, add NixOS (Siren)
695084e depends: add download commands for freebsd & android sources (tobtoht)
2a2da79 free function serialization DSL (jeffro256)
399b884 unit_tests: fix strtoul unit test (jeffro256)
std::sort is unstable, so it can return random sets of transactions when mempool has many transactions with the same fee/byte. It can result in p2pool mining empty blocks sometimes because it doesn't pick up "new" transactions immediately.
7815023 tx_memory_pool: make double spends a no-drop offense (jeffro256)
66e5081 get_block_template_backlog: better sorting logic (SChernykh)
- Fixed undefined behavior after a call to `remove_tx_from_transient_lists` (it used an invalid iterator)
- Fixed `txCompare` (it wasn't strictly weak ordered)
e6f4875 wallet2: adjust fee during backlog, fix set priority (selsta)
a01d7cc Fixed mempool pruning (SChernykh)
c40d8b2 depends: add riscv64 linux build tag (selsta)
bcb15d3 Revert 'http_client: reduce number of packets sent for small bodies' (jeffro256)
c4e1c5a ringct: fix trunc_amount field name change (jeffro256)
This PR is upstreaming changes in the Seraphis lib here: UkoeHB#39. This header adds a macro `VA_ARGS_COMMAPREFIX`
which, when passed `__VA_ARGS__`, expands to `, __VA_ARGS__` unless the length of `__VA_ARGS__` is 0, in which case it expands to nothing. This
macro is useful for passing/declaring optional function arguments.
This PR is upstreaming changes in the Seraphis lib here: UkoeHB#39. The changes to the serialization header allow clean passing
of extra arguments to field serialization in the DSL. This is used mainly to pass implied sizes of containers during deserialization to make the format more
compact. For example, if my object has two containers A & B which must be the same size, I can serialize only the size of container A. Then, during
deserialization, when I deserialize A, I can then use A's size to deserialize B.

Depends on monero-project#9286.
@jeffro256
Copy link
Author

jeffro256 commented Apr 26, 2024

Don't mind all the commit noise, only the last one is relevant.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.