Rediff patches

Drop 0004-use-0.patch: <REASON>
Drop 0002-add-missing-oxenmq-headers.patch: <REASON>
Drop 0003-Change-default-DNS-to-127.0.0.1-953.patch: <REASON>
ubuntu/jammy
Jason Rhinelander 2 years ago
parent 96d89fbfc6
commit 5f8a31db81
No known key found for this signature in database
GPG Key ID: C4992CE7A88D4262

@ -1,98 +0,0 @@
From: Jason Rhinelander <jason@imaginary.ca>
Date: Wed, 30 Mar 2022 17:40:50 -0300
Subject: add missing oxenmq headers
The old headers were using implicit indirect includes that don't work
properly with oxenmq 1.2.11's compatibility headers.
(Temporary fix; this will be reverted in the next lokinet release, which
uses oxenc directly).
---
llarp/dht/messages/findname.cpp | 1 +
llarp/dht/messages/gotname.cpp | 1 +
llarp/handlers/tun.cpp | 2 ++
llarp/peerstats/types.cpp | 1 +
llarp/quic/connection.cpp | 1 +
llarp/router_contact.hpp | 6 +-----
6 files changed, 7 insertions(+), 5 deletions(-)
diff --git a/llarp/dht/messages/findname.cpp b/llarp/dht/messages/findname.cpp
index 929db0e..49753fb 100644
--- a/llarp/dht/messages/findname.cpp
+++ b/llarp/dht/messages/findname.cpp
@@ -1,5 +1,6 @@
#include "findname.hpp"
#include <oxenmq/bt_serialize.h>
+#include <oxenmq/bt_value.h>
#include <llarp/dht/context.hpp>
#include "gotname.hpp"
#include <llarp/router/abstractrouter.hpp>
diff --git a/llarp/dht/messages/gotname.cpp b/llarp/dht/messages/gotname.cpp
index 47efe58..a3231f1 100644
--- a/llarp/dht/messages/gotname.cpp
+++ b/llarp/dht/messages/gotname.cpp
@@ -1,5 +1,6 @@
#include "gotname.hpp"
#include <oxenmq/bt_serialize.h>
+#include <oxenmq/bt_value.h>
#include <llarp/dht/context.hpp>
#include <llarp/router/abstractrouter.hpp>
#include <llarp/path/path_context.hpp>
diff --git a/llarp/handlers/tun.cpp b/llarp/handlers/tun.cpp
index 5677fc1..5cc3042 100644
--- a/llarp/handlers/tun.cpp
+++ b/llarp/handlers/tun.cpp
@@ -30,6 +30,8 @@
#include <llarp/dns/srv_data.hpp>
+#include <oxenmq/bt_value.h>
+
namespace llarp
{
namespace handlers
diff --git a/llarp/peerstats/types.cpp b/llarp/peerstats/types.cpp
index e66918b..7390801 100644
--- a/llarp/peerstats/types.cpp
+++ b/llarp/peerstats/types.cpp
@@ -2,6 +2,7 @@
#include <llarp/util/str.hpp>
#include <oxenmq/bt_serialize.h>
+#include <oxenmq/bt_value.h>
#include <stdexcept>
namespace llarp
diff --git a/llarp/quic/connection.cpp b/llarp/quic/connection.cpp
index 7789083..045832b 100644
--- a/llarp/quic/connection.cpp
+++ b/llarp/quic/connection.cpp
@@ -17,6 +17,7 @@
#include <iterator>
#include <oxenmq/hex.h>
#include <oxenmq/bt_serialize.h>
+#include <oxenmq/bt_value.h>
extern "C"
{
diff --git a/llarp/router_contact.hpp b/llarp/router_contact.hpp
index bb500df..89eee2b 100644
--- a/llarp/router_contact.hpp
+++ b/llarp/router_contact.hpp
@@ -14,15 +14,11 @@
#include <functional>
#include <nlohmann/json.hpp>
#include <vector>
+#include <oxenmq/bt_serialize.h>
#define MAX_RC_SIZE (1024)
#define NICKLEN (32)
-namespace oxenmq
-{
- class bt_list_consumer;
-} // namespace oxenmq
-
namespace llarp
{
/// NetID

@ -1,26 +0,0 @@
From: Jason Rhinelander <jason@imaginary.ca>
Date: Wed, 18 May 2022 12:47:59 -0300
Subject: Change default DNS to 127.0.0.1:953
This is a needed workaround for a systemd resolved bug 23010, until
0.9.9 comes out (which will have a better fix to listen on both
127.3.2.1 + 127.0.0.1:random-high-port).
---
llarp/config/config.cpp | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/llarp/config/config.cpp b/llarp/config/config.cpp
index 3a27193..235e071 100644
--- a/llarp/config/config.cpp
+++ b/llarp/config/config.cpp
@@ -708,7 +708,9 @@ namespace llarp
// can bind to other 127.* IPs to avoid conflicting with something else that may be listening on
// 127.0.0.1:53.
#ifdef __linux__
- constexpr Default DefaultDNSBind{"127.3.2.1:53"};
+ // Workaround for systemd bug #23010 that breaks 127.0.0.0/8 resolvers on anything other than
+ // 127.0.0.1. (This is temporary, until lokinet PR #1888 is merged, most likely in 0.9.9).
+ constexpr Default DefaultDNSBind{"127.0.0.1:953"};
#else
constexpr Default DefaultDNSBind{"127.0.0.1:53"};
#endif

@ -1,22 +0,0 @@
From: majestrate <jeff@oxen.io>
Date: Wed, 18 May 2022 12:16:46 -0400
Subject: use ::/0
makes us map all ranges not just ipv4 when exit mode is on by default.
---
llarp/rpc/rpc_server.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/llarp/rpc/rpc_server.cpp b/llarp/rpc/rpc_server.cpp
index 5bb14e8..5545358 100644
--- a/llarp/rpc/rpc_server.cpp
+++ b/llarp/rpc/rpc_server.cpp
@@ -432,7 +432,7 @@ namespace llarp::rpc
const auto range_itr = obj.find("range");
if (range_itr == obj.end())
{
- range.FromString("0.0.0.0/0");
+ range.FromString("::/0");
}
else if (not range.FromString(range_itr->get<std::string>()))
{

@ -3,26 +3,30 @@ Date: Fri, 13 Dec 2019 17:23:41 -0400
Subject: Pass debian version as GIT_VERSION
---
cmake/Version.cmake | 5 +++++
1 file changed, 5 insertions(+)
cmake/Version.cmake | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/cmake/Version.cmake b/cmake/Version.cmake
index 45037a0..d9fdaef 100644
index a017995..068e271 100644
--- a/cmake/Version.cmake
+++ b/cmake/Version.cmake
@@ -1,4 +1,8 @@
@@ -1,6 +1,10 @@
# We do this via a custom command that re-invokes a cmake script because we need the DEPENDS on .git/index so that we will re-run it (to regenerate the commit tag in the version) whenever the current commit changes. If we used a configure_file directly here, it would only re-run when something else causes cmake to re-run.
-set(VERSIONTAG "${GIT_VERSION}")
+if(GIT_VERSION)
+ set(VERSIONTAG "${GIT_VERSION}")
+ configure_file("${CMAKE_CURRENT_SOURCE_DIR}/constants/version.cpp.in" "${CMAKE_CURRENT_BINARY_DIR}/constants/version.cpp")
+else()
find_package(Git QUIET)
+find_package(Git QUIET)
set(GIT_INDEX_FILE "${PROJECT_SOURCE_DIR}/.git/index")
if(EXISTS ${GIT_INDEX_FILE} AND ( GIT_FOUND OR Git_FOUND) )
@@ -18,5 +22,6 @@ else()
set(VERSIONTAG "nogit")
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/constants/version.cpp.in" "${CMAKE_CURRENT_BINARY_DIR}/constants/version.cpp")
find_package(Git)
if(EXISTS "${GIT_INDEX_FILE}" AND ( GIT_FOUND OR Git_FOUND) )
@@ -22,6 +26,7 @@ if(EXISTS "${GIT_INDEX_FILE}" AND ( GIT_FOUND OR Git_FOUND) )
else()
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/constants/version.cpp.in" "${CMAKE_CURRENT_BINARY_DIR}/constants/version.cpp" @ONLY)
endif()
+endif()
add_custom_target(genversion DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/constants/version.cpp")
if(WIN32)

@ -1,4 +1 @@
0007-Pass-debian-version-as-GIT_VERSION.patch
0002-add-missing-oxenmq-headers.patch
0003-Change-default-DNS-to-127.0.0.1-953.patch
0004-use-0.patch

Loading…
Cancel
Save