summaryrefslogtreecommitdiff
path: root/patches/monero/0006-add-dummy-device-for-ledger.patch
diff options
context:
space:
mode:
authorCzarek Nakamoto <cyjan@mrcyjanek.net>2026-07-23 09:51:20 +0200
committerCzarek Nakamoto <cyjan@mrcyjanek.net>2026-08-03 14:53:50 +0200
commitc765eca1fbbfde6165d5ed5e56276878b3496c77 (patch)
tree5b9ef6e90361595b70fb6076d92bc41b7c6b7abc /patches/monero/0006-add-dummy-device-for-ledger.patch
parent5952bef2ec01b0b7e57c11613cbdc081dcd727c5 (diff)
use FCMP branch, bump simplybs, rebase patchescyjan-fcmp-v2
Diffstat (limited to 'patches/monero/0006-add-dummy-device-for-ledger.patch')
-rw-r--r--patches/monero/0006-add-dummy-device-for-ledger.patch60
1 files changed, 30 insertions, 30 deletions
diff --git a/patches/monero/0006-add-dummy-device-for-ledger.patch b/patches/monero/0006-add-dummy-device-for-ledger.patch
index 816ad5d..5a8870a 100644
--- a/patches/monero/0006-add-dummy-device-for-ledger.patch
+++ b/patches/monero/0006-add-dummy-device-for-ledger.patch
@@ -1,7 +1,7 @@
-From eb9ffa912fb31dd2bddf96d7d55d5e5f9d8219b4 Mon Sep 17 00:00:00 2001
+From 8651523017eae94b5527ba599f6391077a6a6dd2 Mon Sep 17 00:00:00 2001
From: Czarek Nakamoto <cyjan@mrcyjanek.net>
Date: Thu, 8 May 2025 13:14:23 +0200
-Subject: [PATCH 06/20] add dummy device for ledger
+Subject: [PATCH 06/22] add dummy device for ledger
---
CMakeLists.txt | 19 ++--
@@ -21,10 +21,10 @@ Subject: [PATCH 06/20] add dummy device for ledger
create mode 100644 src/device/device_io_dummy.hpp
diff --git a/CMakeLists.txt b/CMakeLists.txt
-index 268339201..eb0d12225 100644
+index 4ba3b7557..8451e7959 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
-@@ -692,16 +692,21 @@ include_directories(${LMDB_INCLUDE})
+@@ -663,16 +663,21 @@ include_directories(${LMDB_INCLUDE})
include_directories(${LIBUNWIND_INCLUDE})
link_directories(${LIBUNWIND_LIBRARY_DIRS})
@@ -54,7 +54,7 @@ index 268339201..eb0d12225 100644
include(CheckTrezor)
diff --git a/src/device/CMakeLists.txt b/src/device/CMakeLists.txt
-index e4f1159b5..14d398f87 100644
+index e8901cd4c..a0cdcdd1d 100644
--- a/src/device/CMakeLists.txt
+++ b/src/device/CMakeLists.txt
@@ -29,10 +29,11 @@
@@ -84,7 +84,7 @@ index e4f1159b5..14d398f87 100644
${device_headers}
device_ledger.hpp
diff --git a/src/device/device.cpp b/src/device/device.cpp
-index e6cd358b6..dd0701e0c 100644
+index e6c39c0b4..8a5d14c41 100644
--- a/src/device/device.cpp
+++ b/src/device/device.cpp
@@ -29,7 +29,7 @@
@@ -122,7 +122,7 @@ index e6cd358b6..dd0701e0c 100644
return *device->second;
}
diff --git a/src/device/device.hpp b/src/device/device.hpp
-index 392703a24..ffd419779 100644
+index 81caec91b..2e67401d6 100644
--- a/src/device/device.hpp
+++ b/src/device/device.hpp
@@ -34,17 +34,7 @@
@@ -401,19 +401,19 @@ index 000000000..87a5f109f
+
+#endif // HAVE_HIDAPI
diff --git a/src/device/device_ledger.cpp b/src/device/device_ledger.cpp
-index 7e4be6347..ee330ba59 100644
+index aa6e037a1..728b06c41 100644
--- a/src/device/device_ledger.cpp
+++ b/src/device/device_ledger.cpp
-@@ -41,7 +41,7 @@ namespace hw {
+@@ -38,7 +38,7 @@ namespace hw {
namespace ledger {
- #ifdef WITH_DEVICE_LEDGER
+ #if defined(WITH_DEVICE_LEDGER) || defined(HIDAPI_DUMMY)
- #undef MONERO_DEFAULT_LOG_CATEGORY
- #define MONERO_DEFAULT_LOG_CATEGORY "device.ledger"
-@@ -299,7 +299,7 @@ namespace hw {
+ namespace {
+ bool apdu_verbose =true;
+@@ -300,7 +300,7 @@ namespace hw {
device_ledger::device_ledger(): hw_device(0x0101, 0x05, 64, 2000) {
this->id = device_id++;
@@ -422,7 +422,7 @@ index 7e4be6347..ee330ba59 100644
this->mode = NONE;
this->has_view_key = false;
this->tx_in_progress = false;
-@@ -534,7 +534,9 @@ namespace hw {
+@@ -535,7 +535,9 @@ namespace hw {
bool device_ledger::connect(void) {
this->disconnect();
@@ -433,7 +433,7 @@ index 7e4be6347..ee330ba59 100644
#ifdef DEBUG_HWDEVICE
cryptonote::account_public_address pubkey;
diff --git a/src/device/device_ledger.hpp b/src/device/device_ledger.hpp
-index 61ac6f9c8..44a1af6c8 100644
+index 2634454a7..da81a399f 100644
--- a/src/device/device_ledger.hpp
+++ b/src/device/device_ledger.hpp
@@ -35,6 +35,7 @@
@@ -441,10 +441,10 @@ index 61ac6f9c8..44a1af6c8 100644
#include "log.hpp"
#include "device_io_hid.hpp"
+#include "device_io_dummy.hpp"
- #include <boost/thread/mutex.hpp>
- #include <boost/thread/recursive_mutex.hpp>
+ #include <mutex>
-@@ -56,7 +57,7 @@ namespace hw {
+ namespace hw {
+@@ -55,7 +56,7 @@ namespace hw {
void register_all(std::map<std::string, std::unique_ptr<device>> &registry);
@@ -453,8 +453,8 @@ index 61ac6f9c8..44a1af6c8 100644
// Origin: https://github.com/LedgerHQ/ledger-app-monero/blob/master/src/monero_types.h
#define SW_OK 0x9000
-@@ -148,7 +149,11 @@ namespace hw {
- mutable boost::mutex command_locker;
+@@ -143,7 +144,11 @@ namespace hw {
+ mutable std::mutex command_locker;
//IO
+#if defined(HIDAPI_DUMMY) && !defined(HAVE_HIDAPI)
@@ -466,11 +466,11 @@ index 61ac6f9c8..44a1af6c8 100644
unsigned char buffer_send[BUFFER_SEND_SIZE];
unsigned int length_recv;
diff --git a/src/wallet/api/wallet.cpp b/src/wallet/api/wallet.cpp
-index d179e502b..fb71a0521 100644
+index 52bc7647a..98f36bdb6 100644
--- a/src/wallet/api/wallet.cpp
+++ b/src/wallet/api/wallet.cpp
-@@ -48,6 +48,9 @@
- #include <boost/locale.hpp>
+@@ -52,6 +52,9 @@
+
#include <boost/filesystem.hpp>
#include "bc-ur/src/bc-ur.hpp"
+#if defined(HIDAPI_DUMMY) && !defined(HAVE_HIDAPI)
@@ -479,7 +479,7 @@ index d179e502b..fb71a0521 100644
using namespace std;
using namespace cryptonote;
-@@ -3177,4 +3180,101 @@ uint64_t WalletImpl::getBytesSent()
+@@ -3136,4 +3139,101 @@ uint64_t WalletImpl::getBytesSent()
return m_wallet->get_bytes_sent();
}
@@ -582,10 +582,10 @@ index d179e502b..fb71a0521 100644
+
} // namespace
diff --git a/src/wallet/api/wallet.h b/src/wallet/api/wallet.h
-index edf8bb8ce..6bfb61cb8 100644
+index a50983a69..194f21ebe 100644
--- a/src/wallet/api/wallet.h
+++ b/src/wallet/api/wallet.h
-@@ -301,6 +301,20 @@ private:
+@@ -302,6 +302,20 @@ private:
// cache connection status to avoid unnecessary RPC calls
mutable std::atomic<bool> m_is_connected;
boost::optional<epee::net_utils::http::login> m_daemon_login{};
@@ -607,10 +607,10 @@ index edf8bb8ce..6bfb61cb8 100644
diff --git a/src/wallet/api/wallet2_api.h b/src/wallet/api/wallet2_api.h
-index 764adbfbf..f433b064f 100644
+index a5164260f..7d250bf8b 100644
--- a/src/wallet/api/wallet2_api.h
+++ b/src/wallet/api/wallet2_api.h
-@@ -1150,6 +1150,19 @@ struct Wallet
+@@ -1146,6 +1146,19 @@ struct Wallet
//! get bytes sent
virtual uint64_t getBytesSent() = 0;
@@ -631,10 +631,10 @@ index 764adbfbf..f433b064f 100644
/**
diff --git a/src/wallet/api/wallet_manager.cpp b/src/wallet/api/wallet_manager.cpp
-index e81b8f83a..277be6ac9 100644
+index b18333e8f..bd92f7829 100644
--- a/src/wallet/api/wallet_manager.cpp
+++ b/src/wallet/api/wallet_manager.cpp
-@@ -188,10 +188,14 @@ bool WalletManagerImpl::verifyWalletPassword(const std::string &keys_file_name,
+@@ -184,10 +184,14 @@ bool WalletManagerImpl::verifyWalletPassword(const std::string &keys_file_name,
bool WalletManagerImpl::queryWalletDevice(Wallet::Device& device_type, const std::string &keys_file_name, const std::string &password, uint64_t kdf_rounds) const
{
@@ -654,5 +654,5 @@ index e81b8f83a..277be6ac9 100644
std::vector<std::string> WalletManagerImpl::findWallets(const std::string &path)
--
-2.50.1 (Apple Git-155)
+2.54.0 (Apple Git-157)