From a53d8baeda5e84b3e8ff13beb040d7df9252f439 Mon Sep 17 00:00:00 2001 From: Duke Date: Fri, 20 Sep 2024 13:35:38 -0400 Subject: [PATCH 01/18] Do not lock cs_main in mining code Technically we should take this lock but it has never been there before and it leads to potentially large slow downs when mining with multiple cores. We see basically the same hashrate for a single core if we have the lock or not and that makes sense, since there is only one core, there are no other mining threads that have to wait. But on one particular CPU I saw a 6% slower hashing when mining with 2 threads and 35% slower with 3 threads. This change also means debug builds will coredump if mining is enabled. --- src/miner.cpp | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/miner.cpp b/src/miner.cpp index 1bc0e984d..2b5c7c033 100644 --- a/src/miner.cpp +++ b/src/miner.cpp @@ -1320,8 +1320,7 @@ void static RandomXMiner() } CValidationState state; - { LOCK(cs_main); - + //{ LOCK(cs_main); if ( !TestBlockValidity(state,B, chainActive.LastTip(), true, false)) { h = UintToArith256(B.GetHash()); @@ -1332,8 +1331,7 @@ void static RandomXMiner() fprintf(stderr,"\n"); return(false); } - - } + //} SetThreadPriority(THREAD_PRIORITY_NORMAL); LogPrintf("HushRandomXMiner:\n"); LogPrintf("proof-of-work found \n hash: %s \ntarget: %s\n", B.GetHash().GetHex(), HASHTarget.GetHex()); @@ -1692,8 +1690,8 @@ void static BitcoinMiner() fprintf(stderr," mined %s block %d!\n",SMART_CHAIN_SYMBOL,Mining_height); } CValidationState state; - { LOCK(cs_main); + //{ LOCK(cs_main); if ( !TestBlockValidity(state,B, chainActive.LastTip(), true, false)) { h = UintToArith256(B.GetHash()); @@ -1704,7 +1702,7 @@ void static BitcoinMiner() return(false); } - } + //} HUSH_CHOSEN_ONE = 1; // Found a solution SetThreadPriority(THREAD_PRIORITY_NORMAL); From 183cd81cf67559978e3e460e7169e214062c9ef9 Mon Sep 17 00:00:00 2001 From: onryo Date: Fri, 20 Sep 2024 20:50:51 +0200 Subject: [PATCH 02/18] Small fix in README OLD_WALLETS.md will be in the correct path once dev is merged into master, changing it to master now to prevent users reading docs from the dev branch --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index ddfff9388..98b885bc0 100644 --- a/README.md +++ b/README.md @@ -8,7 +8,7 @@ | :---: | :---: | :---: | :---: | :---: | | [What is Hush?](#what-is-hush) | [Windows 10 - Video Tutorial](#install-on-windows-10) | [Build on Debian or Ubuntu](#build-on-debian-or-ubuntu) | [Where can I buy Hush?](#where-can-i-buy-hush) | [Cross compiling Windows binaries](#windows-cross-compiled-on-linux) | [Why not GitHub?](#banned-by-github) | [Build on Mac](#build-on-mac) | [Build on Arch](#build-on-arch) | [Can I mine with CPU or GPU?](#can-i-mine-with-cpu-or-gpu) | [Hush DevOps for pools and CEXs](https://git.hush.is/hush/docs/src/branch/master/advanced/devops.md) -| [What is HushChat?](#what-is-hushchat) | [Debian and Ubuntu](#installing-hush-binaries) | [Build on Fedora](#build-on-fedora) | [Claiming funds from old Hush wallets](https://git.hush.is/hush/hush3/src/branch/dev/doc/OLD_WALLETS.md) | [Earn Hush bounty](#earn-hush-bounty) +| [What is HushChat?](#what-is-hushchat) | [Debian and Ubuntu](#installing-hush-binaries) | [Build on Fedora](#build-on-fedora) | [Claiming funds from old Hush wallets](https://git.hush.is/hush/hush3/src/branch/master/doc/OLD_WALLETS.md) | [Earn Hush bounty](#earn-hush-bounty) | [What is SilentDagon?](#what-is-silentdagon) | [Raspberry Pi](#install-on-arm-architecture) | [Build on Ubuntu 16.04 or older](#building-on-ubuntu-16-04-and-older-systems) | [Where can I spend Hush?](#where-can-i-spend-hush) | [Cross compiling from amd64 to arm64](https://git.hush.is/hush/docs/src/branch/master/advanced/cross-compile-hush-full-node-to-aarch64-with-docker.md) From 4538bf9e1e8359bbd8fc5c1167fc4074e76b88d3 Mon Sep 17 00:00:00 2001 From: onryo Date: Fri, 20 Sep 2024 21:13:54 +0200 Subject: [PATCH 03/18] Add agorax.is --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 98b885bc0..9adb48142 100644 --- a/README.md +++ b/README.md @@ -172,7 +172,7 @@ Hush cannot be efficiently mined with CPU or GPU, only ASIC mining is recommende # Where can I spend Hush? -AgoraX market (in progress) +AgoraX market: https://agorax.is # Earn Hush bounty From f144f8a0b907e5573230fd23c4c11c931f94276b Mon Sep 17 00:00:00 2001 From: onryo Date: Thu, 26 Sep 2024 05:04:55 +0200 Subject: [PATCH 04/18] Fix fatal error and the version flag option when compiling for windows --- depends/hosts/mingw32.mk | 2 +- src/sync.cpp | 8 +++++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/depends/hosts/mingw32.mk b/depends/hosts/mingw32.mk index c80d14184..1a65bd346 100644 --- a/depends/hosts/mingw32.mk +++ b/depends/hosts/mingw32.mk @@ -1,6 +1,6 @@ mingw32_CC=x86_64-w64-mingw32-gcc-posix mingw32_CXX=x86_64-w64-mingw32-g++-posix -mingw32_CFLAGS=-pipe -std=c11 +mingw32_CFLAGS=-pipe -std=c++11 mingw32_CXXFLAGS=$(mingw32_CFLAGS) -std=c++11 mingw32_release_CFLAGS=-O3 diff --git a/src/sync.cpp b/src/sync.cpp index 632c5562e..6f9ae5768 100644 --- a/src/sync.cpp +++ b/src/sync.cpp @@ -25,7 +25,13 @@ #include #include -#include /* backtrace, backtrace_symbols_fd */ +#ifdef _WIN32 +#include +#include +#else +#include +#endif + #include /* STDOUT_FILENO */ From c245242e0f1508d5540cc0fa279b1af9b1b40d83 Mon Sep 17 00:00:00 2001 From: jahway603 Date: Thu, 26 Sep 2024 10:21:20 -0400 Subject: [PATCH 05/18] updated Debian package copyright to resolve Issue #134 --- contrib/debian/copyright | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/debian/copyright b/contrib/debian/copyright index 6231c2023..905f248bb 100644 --- a/contrib/debian/copyright +++ b/contrib/debian/copyright @@ -1,5 +1,5 @@ Files: * -Copyright: 2016-2020, The Hush developers +Copyright: 2016-2024, The Hush developers 2009-2016, Bitcoin Core developers License: GPLv3 Comment: https://hush.is From 8333810f0f3176d0df4c6c489128b7477ae67819 Mon Sep 17 00:00:00 2001 From: jahway603 Date: Thu, 26 Sep 2024 10:39:28 -0400 Subject: [PATCH 06/18] Added build.sh checks for as and ld to be installed --- util/build.sh | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/util/build.sh b/util/build.sh index cbcd9a416..6bf7a6d69 100755 --- a/util/build.sh +++ b/util/build.sh @@ -17,6 +17,18 @@ if ! [ -x "$(command -v autoreconf)" ]; then exit 1 fi +if ! [ -x "$(command -v as)" ]; then + echo 'Error: as is not installed. Install as and try again.' >&2 + echo 'On Debian-like systems: apt install binutils' >&2 + exit 1 +fi + +if ! [ -x "$(command -v ld)" ]; then + echo 'Error: ld is not installed. Install ld and try again.' >&2 + echo 'On Debian-like systems: apt install binutils' >&2 + exit 1 +fi + function cmd_pref() { if type -p "$2" > /dev/null; then eval "$1=$2" From 7cb86b8aa6b4e45502350af43bd838f685a7a463 Mon Sep 17 00:00:00 2001 From: jahway603 Date: Thu, 26 Sep 2024 11:06:29 -0400 Subject: [PATCH 07/18] Updated doc/release-process.md to resolve Issue #407 --- doc/release-process.md | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/doc/release-process.md b/doc/release-process.md index 566de1b1f..f60b26632 100644 --- a/doc/release-process.md +++ b/doc/release-process.md @@ -111,20 +111,24 @@ Install deps on Linux: - Make sure git tag starts with a `v` such as `v3.9.2` - Use util/gen-linux-binary-release.sh to make a Linux release binary - Upload Linux binary to Gitea release and add SHA256 sum - - Use util/build-debian-package.sh to make an x86 Debian package for the release + - Create an x86 Debian package for the release: + - Edit contrib/debian/changelog to add information about the new release + - Use `util/build-debian-package.sh` to make an x86 Debian package for the release - Debian packages should be done after you make manpages, because those are included in Debian packages - `lintian` is an optional dependency, it's not needed to build the .deb - Upload .deb to Gitea release - Add SHA256 checksum of .deb to release - Use util/build-debian-package-ARM.sh (does this still work?) to make an ARM Debian package for the release - Upload the debian packages to the Gitea release page, with SHA256 sums - - Figure out how to update https://faq.hush.is/rpc/ for new release + - Update the rpc.hush.is repo for new release by [following these instructions](https://git.hush.is/hush/rpc.hush.is/src/branch/master/README.md) + - Update https://faq.hush.is/rpc/ for new release after updating the rpc.hush.is repo ## Platform-specific notes -Use `./util/build-mac.sh` to compile on Apple/Mac systems, use `./util/build-win.sh` to build on Windows and `./util/build-arm.sh` to build on ARMv8 systems. - -Use `./util/build-debian-package.sh aarch64` to build a Debian package for aarch64 . +- Use `./util/build-mac.sh` to compile on Apple/Mac systems +- Use `./util/build-win.sh` to build on Windows +- Use [these cross compile instructions](https://git.hush.is/jahway603/hush-docs/src/branch/master/advanced/cross-compile-hush-full-node-to-aarch64-with-docker.md) to build the release for ARMv8 (aarch64) systems, as the current build system does not permit us to natively build this on the SBC device + - Then use `./util/build-debian-package.sh aarch64` to build a Debian package for ARMv8 (aarch64) ## Optional things From 93f6514d8672f2eec78532c3b54bb3f40122586b Mon Sep 17 00:00:00 2001 From: Duke Date: Thu, 26 Sep 2024 11:13:07 -0400 Subject: [PATCH 08/18] Disable absurd fee checks when adding to the mempool To protect users who are not using opreturn we prevent any use of z_sendmany with absurd fees if opreturn is not being used, so this change only affects users who are adding opreturn data. Since there is no way to currently send opreturn data via a GUI this still protects all GUI users from absurd fees while allowing CLI users to decide to use higher fees. --- src/main.cpp | 14 ++++++++++++-- src/wallet/rpcwallet.cpp | 17 ++++++++++++++--- 2 files changed, 26 insertions(+), 5 deletions(-) diff --git a/src/main.cpp b/src/main.cpp index 3ddf5bb54..f2f3bf831 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -1960,7 +1960,17 @@ bool AcceptToMemoryPool(CTxMemPool& pool, CValidationState &state, const CTransa dFreeCount += nSize; } - if (!tx.IsCoinImport() && fRejectAbsurdFee && nFees > ::minRelayTxFee.GetFee(nSize) * 10000 && nFees > nValueOut/19) + // Disable checks for absurd fees when adding to the mempool. Instead, this check is done + // when a user attempts to make a transaction with an absurd fee and only rejects absurd + // fees when OP_RETURN data is NOT being used. This means users making normal financial + // transactions (z2z) are protected from absurd fees, it is only users who are storing + // arbitrary data via a z2t transaction are allowed to (or potentially required) to pay high fees + // It would be nice to detect the use of OP_RETURN right here but it seems to only be known + // inside of IsStandard() inside of IsStandardTx() and we want to avoid doing expensive checks + // multiple times. + fRejectAbsurdFee = false; + + if (fRejectAbsurdFee && !tx.IsCoinImport() && nFees > ::minRelayTxFee.GetFee(nSize) * 10000 && nFees > nValueOut/19) { string errmsg = strprintf("absurdly high fees %s, %d > %d", hash.ToString(), @@ -1968,7 +1978,7 @@ bool AcceptToMemoryPool(CTxMemPool& pool, CValidationState &state, const CTransa LogPrint("mempool", errmsg.c_str()); return state.Error("AcceptToMemoryPool: " + errmsg); } -//fprintf(stderr,"addmempool 6\n"); + //fprintf(stderr,"addmempool 6\n"); // Check against previous transactions // This is done last to help prevent CPU exhaustion denial-of-service attacks. diff --git a/src/wallet/rpcwallet.cpp b/src/wallet/rpcwallet.cpp index 46a059892..1b6110ec5 100644 --- a/src/wallet/rpcwallet.cpp +++ b/src/wallet/rpcwallet.cpp @@ -5155,6 +5155,8 @@ UniValue z_sendmany(const UniValue& params, bool fHelp, const CPubKey& mypk) CAmount nTotalOut = 0; // Optional OP_RETURN data CScript opret; + // TODO: enforce that only a single opreturn exists + UniValue opretValue; bool containsSaplingOutput = false; @@ -5189,7 +5191,10 @@ UniValue z_sendmany(const UniValue& params, bool fHelp, const CPubKey& mypk) // throw JSONRPCError(RPC_INVALID_PARAMETER, string("Invalid parameter, duplicated address: ")+address); setAddress.insert(address); - UniValue opretValue = find_value(o, "opreturn"); + UniValue this_opret = find_value(o, "opreturn"); + if (!this_opret.isNull()) { + opretValue = this_opret; + } // Create the CScript representation of the OP_RETURN if (!opretValue.isNull()) { @@ -5342,12 +5347,18 @@ UniValue z_sendmany(const UniValue& params, bool fHelp, const CPubKey& mypk) // or anything less than nDefaultFee instead of being forced to use a custom fee and leak metadata if (nTotalOut < nDefaultFee) { if (nFee > nDefaultFee) { - throw JSONRPCError(RPC_INVALID_PARAMETER, strprintf("Small transaction amount %s has fee %s that is greater than the default fee %s", FormatMoney(nTotalOut), FormatMoney(nFee), FormatMoney(nDefaultFee))); + // Allow large fees if OP_RETURN is being used + if( opretValue.isNull() ) { + throw JSONRPCError(RPC_INVALID_PARAMETER, strprintf("Small transaction amount %s has fee %s that is greater than the default fee %s", FormatMoney(nTotalOut), FormatMoney(nFee), FormatMoney(nDefaultFee))); + } } } else { // Check that the user specified fee is not absurd. if (nFee > nTotalOut) { - throw JSONRPCError(RPC_INVALID_PARAMETER, strprintf("Fee %s is greater than the sum of outputs %s and also greater than the default fee", FormatMoney(nFee), FormatMoney(nTotalOut))); + // Allow large fees if OP_RETURN is being used + if( opretValue.isNull() ) { + throw JSONRPCError(RPC_INVALID_PARAMETER, strprintf("Fee %s is greater than the sum of outputs %s and also greater than the default fee", FormatMoney(nFee), FormatMoney(nTotalOut))); + } } } } From 47cc49bcc580dfe1b772f42046e0aad19b976477 Mon Sep 17 00:00:00 2001 From: Duke Date: Fri, 27 Sep 2024 08:44:14 -0400 Subject: [PATCH 09/18] Change OP_RETURN fee requirements This commit removes the CLI option -opretmintxfee, makes it always enabled, changes the required fee rate and changes which OP_RETURNS get "amnesty" and do not need to pay this fee rate. --- src/init.cpp | 1 - src/miner.cpp | 20 ++++++++++---------- 2 files changed, 10 insertions(+), 11 deletions(-) diff --git a/src/init.cpp b/src/init.cpp index 7458d4847..c034826d6 100644 --- a/src/init.cpp +++ b/src/init.cpp @@ -479,7 +479,6 @@ std::string HelpMessage(HelpMessageMode mode) if (showDebug) strUsage += HelpMessageOpt("-mintxfee=", strprintf("Fees (in %s/kB) smaller than this are considered zero fee for transaction creation (default: %s)", CURRENCY_UNIT, FormatMoney(CWallet::minTxFee.GetFeePerK()))); - strUsage += HelpMessageOpt("-opretmintxfee=", strprintf(_("Minimum fee (in %s/kB) to allow for OP_RETURN transactions (default: %s)"), CURRENCY_UNIT, 400000 )); strUsage += HelpMessageOpt("-paytxfee=", strprintf(_("Fee (in %s/kB) to add to transactions you send (default: %s)"), CURRENCY_UNIT, FormatMoney(payTxFee.GetFeePerK()))); // If this is used incorrectly (-rescanheight too large), then the local wallet may attempt to spend funds which it does not have witness data about // which will cause a "missing inputs" error when added to the mempool. Rescanning from correct height will fix this. diff --git a/src/miner.cpp b/src/miner.cpp index 2b5c7c033..bb7582d7b 100644 --- a/src/miner.cpp +++ b/src/miner.cpp @@ -475,14 +475,10 @@ CBlockTemplate* CreateNewBlock(CPubKey _pk,const CScript& _scriptPubKeyIn, int32 // fprintf(stderr,"%s: nTxSize = %u\n", __func__, nTxSize); // Opret spam limits - if (mapArgs.count("-opretmintxfee")) + const bool opretminfee = true; + if (opretminfee) { - CAmount n = 0; - CFeeRate opretMinFeeRate; - if (ParseMoney(mapArgs["-opretmintxfee"], n) && n > 0) - opretMinFeeRate = CFeeRate(n); - else - opretMinFeeRate = CFeeRate(400000); // default opretMinFeeRate (1 HUSH per 250 Kb = 0.004 per 1 Kb = 400000 puposhis per 1 Kb) + CFeeRate opretMinFeeRate = CFeeRate(10000000); // default opretMinFeeRate 0.1 HUSH bool fSpamTx = false; unsigned int nTxSize = ::GetSerializeSize(tx, SER_NETWORK, PROTOCOL_VERSION); @@ -501,9 +497,13 @@ CBlockTemplate* CreateNewBlock(CPubKey _pk,const CScript& _scriptPubKeyIn, int32 } } - if ((nTxOpretSize > 256) && (feeRate < opretMinFeeRate)) fSpamTx = true; - // std::cerr << tx.GetHash().ToString() << " nTxSize." << nTxSize << " nTxOpretSize." << nTxOpretSize << " feeRate." << feeRate.ToString() << " opretMinFeeRate." << opretMinFeeRate.ToString() << " fSpamTx." << fSpamTx << std::endl; - if (fSpamTx) continue; + // opreturns of this size or smaller get amnesty and do not have to pay increased fees + int amnestySize = 128; + if ((nTxOpretSize > amnestySize) && (feeRate < opretMinFeeRate)) { + fSpamTx = true; + std::cerr << __func__ << ": " << tx.GetHash().ToString() << " nTxSize=" << nTxSize << " nTxOpretSize=" << nTxOpretSize << " feeRate=" << feeRate.ToString() << " opretMinFeeRate=" << opretMinFeeRate.ToString() << " fSpamTx=" << fSpamTx << std::endl; + continue; + } // std::cerr << tx.GetHash().ToString() << " vecPriority.size() = " << vecPriority.size() << std::endl; } From e68795f4f97d637cc2ba9c35ab43b198541cdd91 Mon Sep 17 00:00:00 2001 From: onryo Date: Fri, 27 Sep 2024 22:39:32 +0200 Subject: [PATCH 10/18] Revert "Fix fatal error and the version flag option when compiling for windows" This reverts commit f144f8a0b907e5573230fd23c4c11c931f94276b. --- depends/hosts/mingw32.mk | 2 +- src/sync.cpp | 8 +------- 2 files changed, 2 insertions(+), 8 deletions(-) diff --git a/depends/hosts/mingw32.mk b/depends/hosts/mingw32.mk index 1a65bd346..c80d14184 100644 --- a/depends/hosts/mingw32.mk +++ b/depends/hosts/mingw32.mk @@ -1,6 +1,6 @@ mingw32_CC=x86_64-w64-mingw32-gcc-posix mingw32_CXX=x86_64-w64-mingw32-g++-posix -mingw32_CFLAGS=-pipe -std=c++11 +mingw32_CFLAGS=-pipe -std=c11 mingw32_CXXFLAGS=$(mingw32_CFLAGS) -std=c++11 mingw32_release_CFLAGS=-O3 diff --git a/src/sync.cpp b/src/sync.cpp index 6f9ae5768..632c5562e 100644 --- a/src/sync.cpp +++ b/src/sync.cpp @@ -25,13 +25,7 @@ #include #include -#ifdef _WIN32 -#include -#include -#else -#include -#endif - +#include /* backtrace, backtrace_symbols_fd */ #include /* STDOUT_FILENO */ From be5a78931bd12f12b0f8e7fc4730728df71aa240 Mon Sep 17 00:00:00 2001 From: onryo Date: Fri, 27 Sep 2024 22:40:46 +0200 Subject: [PATCH 11/18] Fix fatal error when compiling for windows on dev --- src/sync.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/sync.cpp b/src/sync.cpp index 632c5562e..16c4c86a2 100644 --- a/src/sync.cpp +++ b/src/sync.cpp @@ -25,9 +25,14 @@ #include #include +#ifdef _WIN32 +#include +#include +#else #include /* backtrace, backtrace_symbols_fd */ -#include /* STDOUT_FILENO */ +#endif +#include /* STDOUT_FILENO */ #ifdef DEBUG_LOCKCONTENTION void PrintLockContention(const char* pszName, const char* pszFile, int nLine) From 9f31214812634efc19bdd5736d89ca2bce8df3cb Mon Sep 17 00:00:00 2001 From: onryo Date: Sun, 29 Sep 2024 02:44:50 +0200 Subject: [PATCH 12/18] Add notes to 3.10.3 --- doc/relnotes/README.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/doc/relnotes/README.md b/doc/relnotes/README.md index 91c8c6489..c7b4a9747 100644 --- a/doc/relnotes/README.md +++ b/doc/relnotes/README.md @@ -10,8 +10,10 @@ and no longer on Github, since they banned Duke Leto and also because they censor many people around the world and work with evil organizations. -# Hush 3.10.3 "" +# Hush 3.10.3 "Persistent Pezoporus" + * Set minimum fee to 0.1 HUSH per 1 KB of data if `OP_RETURN` is used. + * A feature in absurd fee that allows sending amount < fee, can be used only in a full node by advanced users. * Fixed various bugs relating to lock ordering and missing locks * Fixed RPC docs for addnode and disconnectnode having the incorrect port for HACs * Value of DEBUG_LOCKORDER is now logged to debug.log on node startup @@ -20,6 +22,7 @@ evil organizations. * Hush nodes now have their own protocol version which is independent from HACs * Fixed off-by-one bug in `newSietchRecipient` * Performance improvement to `ActivateBestChainStep` https://git.hush.is/hush/hush3/commit/ed86f2dd1da370fe2dbf7db475afc41b218cbc5f + * Improved navigation in README for new users. # Hush 3.10.2 "Fiendish Fenrir" From 67fe1110506e5d7226c2fb2e03b36fe54b7b28f1 Mon Sep 17 00:00:00 2001 From: Duke Date: Mon, 30 Sep 2024 04:36:21 -0700 Subject: [PATCH 13/18] Mention wolfssl change in relnotes --- doc/relnotes/README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/doc/relnotes/README.md b/doc/relnotes/README.md index c7b4a9747..823d6edbb 100644 --- a/doc/relnotes/README.md +++ b/doc/relnotes/README.md @@ -12,6 +12,7 @@ evil organizations. # Hush 3.10.3 "Persistent Pezoporus" + * Use WolfSSL 4.8.1 which prevents nodes from getting stuck in general and when shutting down * Set minimum fee to 0.1 HUSH per 1 KB of data if `OP_RETURN` is used. * A feature in absurd fee that allows sending amount < fee, can be used only in a full node by advanced users. * Fixed various bugs relating to lock ordering and missing locks From 6133c1669cc47f222af55a9261f562a93b7d66eb Mon Sep 17 00:00:00 2001 From: jahway603 Date: Mon, 30 Sep 2024 09:24:34 -0400 Subject: [PATCH 14/18] Updated Debian package changelog --- contrib/debian/changelog | 19 +++++++++++++++++++ doc/relnotes/README.md | 2 ++ 2 files changed, 21 insertions(+) diff --git a/contrib/debian/changelog b/contrib/debian/changelog index 98a9e8946..535e69401 100644 --- a/contrib/debian/changelog +++ b/contrib/debian/changelog @@ -1,3 +1,22 @@ +hush (3.10.3) stable; urgency=high + + * Use WolfSSL 4.8.1 which prevents nodes from getting stuck in general and when shutting down + * Set minimum fee to 0.1 HUSH per 1 KB of data if `OP_RETURN` is used. + * A feature in absurd fee that allows sending amount < fee, can be used only in a full node by advanced users. + * Fixed various bugs relating to lock ordering and missing locks + * Fixed RPC docs for addnode and disconnectnode having the incorrect port for HACs + * Value of DEBUG_LOCKORDER is now logged to debug.log on node startup + * New script ./debug-build.sh to make it easier to make debug builds + * DragonX nodes now have their own list of seed nodes + * Hush nodes now have their own protocol version which is independent from HACs + * Fixed off-by-one bug in `newSietchRecipient` + * Performance improvement to `ActivateBestChainStep` ed86f2dd1d + * Improved navigation in README for new users. + * Updated doc/release-process.md to resolve Issue #407 + * Added build.sh checks for as and ld to be installed to resolve Issue #73 + + -- Hush Core Mon, 30 Sep 2024 11:22:33 -0700 + hush (3.10.2) stable; urgency=medium * Upgraded WolfSSL to 5.2.0 on Linux and Mac: #380. diff --git a/doc/relnotes/README.md b/doc/relnotes/README.md index 823d6edbb..41f6a786b 100644 --- a/doc/relnotes/README.md +++ b/doc/relnotes/README.md @@ -24,6 +24,8 @@ evil organizations. * Fixed off-by-one bug in `newSietchRecipient` * Performance improvement to `ActivateBestChainStep` https://git.hush.is/hush/hush3/commit/ed86f2dd1da370fe2dbf7db475afc41b218cbc5f * Improved navigation in README for new users. + * Updated doc/release-process.md to resolve Issue #407 + * Added build.sh checks for as and ld to be installed to resolve Issue #73 # Hush 3.10.2 "Fiendish Fenrir" From bfff0e87423c3f58d7077ac1a33aeed7304c0cfe Mon Sep 17 00:00:00 2001 From: jahway603 Date: Mon, 30 Sep 2024 12:41:16 -0400 Subject: [PATCH 15/18] Added link to README.md for the ARM cross compilation documentation --- README.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 9adb48142..9ca34619a 100644 --- a/README.md +++ b/README.md @@ -90,6 +90,8 @@ Use this if you have a Raspberry Pi or similar computer. Currently, any ARMv7 ma 1. Install the Debian package, substituting "VERSION-NUMBER" for the version you have downloaded: `sudo dpkg -i hush-VERSION-NUMBER-aarch64.deb`. 1. Run with: `hushd`. +If you would like to compile this for ARM yourself, then please refer to the [Cross compiling a Hush full node daemon from AMD64 to ARM64(aarch64) CPU architecture with Docker](https://git.hush.is/jahway603/hush-docs/src/branch/master/advanced/cross-compile-hush-full-node-to-aarch64-with-docker.md) documentation to do that. + # Building On Ubuntu 16.04 and older systems Some older compilers may not be able to compile modern code, such as gcc 5.4 which comes with Ubuntu 16.04 by default. Here is how to install gcc 7 on Ubuntu 16.04. Run these commands as root: @@ -192,4 +194,4 @@ Developers can earn bounty by fixing bugs or solving feature requests listed in # License -For license information see the file [COPYING](COPYING). \ No newline at end of file +For license information see the file [COPYING](COPYING). From 7729e58c4957ec7e0a1b19fc92e93011eeec8aae Mon Sep 17 00:00:00 2001 From: onryo Date: Mon, 30 Sep 2024 20:06:30 +0200 Subject: [PATCH 16/18] Correct URLs to video tutorials We no longer use PeerTube, so the path has changed --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 9ca34619a..4a7cfd389 100644 --- a/README.md +++ b/README.md @@ -50,7 +50,7 @@ cd hush3 # This uses 3 build processes, you need 2GB of RAM for each. ./build.sh -j3 ``` -Video Tutorial: https://videos.hush.is/w/3kKQt81r7UUPWLHVuwK2BZ +Video Tutorial: https://videos.hush.is/videos/how-to-install-on-linux # Build on Arch @@ -80,7 +80,7 @@ cd hush3 # Install on Windows 10 -Video Tutorial: https://videos.hush.is/w/oGXff7of3EjmGENtDtYTUX +Video Tutorial: https://videos.hush.is/videos/how-to-install-on-windows # Install on ARM Architecture From 54b2f216ad2cb6b0def7c2396c61dfd6ceabe61c Mon Sep 17 00:00:00 2001 From: onryo Date: Mon, 30 Sep 2024 23:37:08 +0200 Subject: [PATCH 17/18] make seeds --- contrib/seeds/nodes_main.txt | 15 +++++++++------ src/chainparamsseeds.h | 15 +++++++++------ 2 files changed, 18 insertions(+), 12 deletions(-) diff --git a/contrib/seeds/nodes_main.txt b/contrib/seeds/nodes_main.txt index 2fc59ec5e..1ad72eeec 100644 --- a/contrib/seeds/nodes_main.txt +++ b/contrib/seeds/nodes_main.txt @@ -1,14 +1,14 @@ # node1.hush.land -91.208.127.81 +103.69.128.148 # node2.hush.land -87.251.76.166 +194.29.100.208 # node3.hush.land -45.82.68.233 +45.132.75.69 # node4.hush.land -87.251.76.33 +170.205.39.39 # node5.hush.land 178.250.189.141 @@ -28,8 +28,11 @@ hushv3h6mbxd2pptj42reko3jcexcgnz5zvp3mqcu6myto3jhhn4yzyd.onion hushv3xvheqh42ms3ld2nh555muscietkib7gycb7s4psbrjsysfywqd.onion # ipv6 -2a0c:b641:6f1:34::2 -2a0c:b641:6f1:c::2 +2a0c:b641:6f1:18e::2 +2406:ef80:3:1269::1 +2406:ef80:2:3b59::1 +2406:ef80:1:146e::1 +2406:ef80:4:2132::1 # i2p 7oumuppuzgbzlkahavx7qrtjnvbhkixjqdmeg7f6fhndgfhz7mlq.b32.i2p diff --git a/src/chainparamsseeds.h b/src/chainparamsseeds.h index dc2b4948c..4f8bdd06b 100644 --- a/src/chainparamsseeds.h +++ b/src/chainparamsseeds.h @@ -11,10 +11,10 @@ // Each line contains a BIP155 serialized address. // static const uint8_t chainparams_seed_main[] = { - 0x01,0x04,0x5b,0xd0,0x7f,0x51,0x00,0x00, // 91.208.127.81 - 0x01,0x04,0x57,0xfb,0x4c,0xa6,0x00,0x00, // 87.251.76.166 - 0x01,0x04,0x2d,0x52,0x44,0xe9,0x00,0x00, // 45.82.68.233 - 0x01,0x04,0x57,0xfb,0x4c,0x21,0x00,0x00, // 87.251.76.33 + 0x01,0x04,0x67,0x45,0x80,0x94,0x00,0x00, // 103.69.128.148 + 0x01,0x04,0xc2,0x1d,0x64,0xd0,0x00,0x00, // 194.29.100.208 + 0x01,0x04,0x2d,0x84,0x4b,0x45,0x00,0x00, // 45.132.75.69 + 0x01,0x04,0xaa,0xcd,0x27,0x27,0x00,0x00, // 170.205.39.39 0x01,0x04,0xb2,0xfa,0xbd,0x8d,0x00,0x00, // 178.250.189.141 0x01,0x04,0x95,0x1c,0x66,0xdb,0x00,0x00, // 149.28.102.219 0x01,0x04,0x9b,0x8a,0xe4,0x44,0x00,0x00, // 155.138.228.68 @@ -22,8 +22,11 @@ static const uint8_t chainparams_seed_main[] = { 0x04,0x20,0xef,0xad,0x0c,0x95,0x3e,0x61,0xee,0x69,0x57,0x67,0xdb,0x4f,0xb7,0x8d,0xc2,0x35,0x1c,0x6b,0x96,0xf4,0x1f,0x7a,0xb4,0x06,0x09,0x3a,0x64,0x33,0xf4,0x0b,0x2c,0x94,0x00,0x00, // 56wqzfj6mhxgsv3h3nh3pdocguogxfxud55libqjhjsdh5alfsko2iqd.onion 0x04,0x20,0x3d,0x24,0x7a,0xec,0xfe,0x60,0x6e,0x3d,0x3d,0xf3,0x4f,0x35,0x12,0x29,0xdb,0x48,0x89,0x71,0x19,0xb9,0xee,0x6a,0xfd,0xb2,0x02,0xa7,0x99,0x89,0xbb,0x69,0x39,0xdb,0x00,0x00, // hushv3h6mbxd2pptj42reko3jcexcgnz5zvp3mqcu6myto3jhhn4yzyd.onion 0x04,0x20,0x3d,0x24,0x7a,0xee,0xf5,0x39,0x20,0x7e,0x69,0x92,0xda,0xc7,0xa6,0x9f,0xbd,0xeb,0x29,0x21,0x20,0x93,0x52,0x03,0xf3,0x60,0x41,0xfc,0xb8,0xf9,0x06,0x29,0x96,0x24,0x00,0x00, // hushv3xvheqh42ms3ld2nh555muscietkib7gycb7s4psbrjsysfywqd.onion - 0x02,0x10,0x2a,0x0c,0xb6,0x41,0x06,0xf1,0x00,0x34,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00, // 2a0c:b641:6f1:34::2 - 0x02,0x10,0x2a,0x0c,0xb6,0x41,0x06,0xf1,0x00,0x0c,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00, // 2a0c:b641:6f1:c::2 + 0x02,0x10,0x2a,0x0c,0xb6,0x41,0x06,0xf1,0x01,0x8e,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00, // 2a0c:b641:6f1:18e::2 + 0x02,0x10,0x24,0x06,0xef,0x80,0x00,0x03,0x12,0x69,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00, // 2406:ef80:3:1269::1 + 0x02,0x10,0x24,0x06,0xef,0x80,0x00,0x02,0x3b,0x59,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00, // 2406:ef80:2:3b59::1 + 0x02,0x10,0x24,0x06,0xef,0x80,0x00,0x01,0x14,0x6e,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00, // 2406:ef80:1:146e::1 + 0x02,0x10,0x24,0x06,0xef,0x80,0x00,0x04,0x21,0x32,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00, // 2406:ef80:4:2132::1 0x05,0x20,0xfb,0xa8,0xca,0x3d,0xf4,0xc9,0x83,0x95,0xa8,0x07,0x05,0x6f,0xf8,0x46,0x69,0x6d,0x42,0x75,0x22,0xe9,0x80,0xd8,0x43,0x7c,0xbe,0x29,0xda,0x33,0x14,0xf9,0xfb,0x17,0x00,0x00, // 7oumuppuzgbzlkahavx7qrtjnvbhkixjqdmeg7f6fhndgfhz7mlq.b32.i2p }; From 598b96998783e2dc77f719a229eb698d45186c72 Mon Sep 17 00:00:00 2001 From: Duke Date: Tue, 1 Oct 2024 08:46:46 -0400 Subject: [PATCH 18/18] Use our own hosted version of libgmp --- depends/packages/libgmp.mk | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/depends/packages/libgmp.mk b/depends/packages/libgmp.mk index 92cd95fbc..4ec7cde16 100644 --- a/depends/packages/libgmp.mk +++ b/depends/packages/libgmp.mk @@ -8,22 +8,25 @@ $(package)_sha256_hash=67df06ed50f288bd7b1ec6907973684fb7cf1196f2cb368b59d423e42 $(package)_git_commit=42ba95387cdfd67399f7aac52fddb8d6e1258ee6 $(package)_dependencies= $(package)_config_opts=--enable-cxx --disable-shared -else ifeq ($(build_os),darwin) +else +#else ifeq ($(build_os),darwin) $(package)_version=6.1.1 $(package)_download_path=https://git.hush.is/attachments $(package)_file_name=d613c855-cd92-4efb-b893-658496852019 $(package)_download_file=d613c855-cd92-4efb-b893-658496852019 $(package)_sha256_hash=a8109865f2893f1373b0a8ed5ff7429de8db696fc451b1036bd7bdf95bbeffd6 $(package)_config_opts=--enable-cxx --disable-shared -else -$(package)_version=6.1.1 -$(package)_download_path=https://ftp.gnu.org/gnu/gmp -$(package)_file_name=gmp-$($(package)_version).tar.bz2 -$(package)_sha256_hash=a8109865f2893f1373b0a8ed5ff7429de8db696fc451b1036bd7bdf95bbeffd6 -$(package)_dependencies= -$(package)_config_opts=--enable-cxx --disable-shared endif +#else +#$(package)_version=6.1.1 +#$(package)_download_path=https://ftp.gnu.org/gnu/gmp +#$(package)_file_name=gmp-$($(package)_version).tar.bz2 +#$(package)_sha256_hash=a8109865f2893f1373b0a8ed5ff7429de8db696fc451b1036bd7bdf95bbeffd6 +#$(package)_dependencies= +#$(package)_config_opts=--enable-cxx --disable-shared +#endif + define $(package)_config_cmds $($(package)_autoconf) --host=$(host) --build=$(build) endef