We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 051ba32 commit 51f7668Copy full SHA for 51f7668
src/addrman_impl.h
@@ -32,8 +32,12 @@ static constexpr int ADDRMAN_NEW_BUCKET_COUNT{1 << ADDRMAN_NEW_BUCKET_COUNT_LOG2
32
static constexpr int32_t ADDRMAN_BUCKET_SIZE_LOG2{6};
33
static constexpr int ADDRMAN_BUCKET_SIZE{1 << ADDRMAN_BUCKET_SIZE_LOG2};
34
35
-/** User-defined type for the internally used nIds */
36
-using nid_type = int;
+/**
+ * User-defined type for the internally used nIds
37
+ * This used to be int, making it feasible for attackers to cause an overflow,
38
+ * see https://bitcoincore.org/en/2024/07/31/disclose-addrman-int-overflow/
39
+ */
40
+using nid_type = int64_t;
41
42
/**
43
* Extended statistics about a CAddress
0 commit comments