mirror of
https://github.com/XRPLF/rippled.git
synced 2026-04-29 15:37:57 +00:00
Merge branch 'develop' into ximinez/number-maxint-range
This commit is contained in:
@@ -38,6 +38,8 @@ This section contains changes targeting a future version.
|
||||
### Bugfixes
|
||||
|
||||
- Peer Crawler: The `port` field in `overlay.active[]` now consistently returns an integer instead of a string for outbound peers. [#6318](https://github.com/XRPLF/rippled/pull/6318)
|
||||
- `ping`: The `ip` field is no longer returned as an empty string for proxied connections without a forwarded-for header. It is now omitted, consistent with the behavior for identified connections. [#6730](https://github.com/XRPLF/rippled/pull/6730)
|
||||
- gRPC `GetLedgerDiff`: Fixed error message that incorrectly said "base ledger not validated" when the desired ledger was not validated. [#6730](https://github.com/XRPLF/rippled/pull/6730)
|
||||
|
||||
## XRP Ledger server version 3.1.0
|
||||
|
||||
|
||||
@@ -43,6 +43,7 @@ class Roles_test : public beast::unit_test::suite
|
||||
Env env{*this, envconfig(secure_gateway)};
|
||||
|
||||
BEAST_EXPECT(env.rpc("ping")["result"]["role"] == "proxied");
|
||||
BEAST_EXPECT(!env.rpc("ping")["result"].isMember("ip"));
|
||||
auto wsRes = makeWSClient(env.app().config())->invoke("ping")["result"];
|
||||
BEAST_EXPECT(!wsRes.isMember("unlimited") || !wsRes["unlimited"].asBool());
|
||||
|
||||
|
||||
@@ -36,7 +36,7 @@ doLedgerDiffGrpc(RPC::GRPCContext<org::xrpl::rpc::v1::GetLedgerDiffRequest>& con
|
||||
std::dynamic_pointer_cast<Ledger const>(desiredLedgerRv);
|
||||
if (!desiredLedger)
|
||||
{
|
||||
grpc::Status const errorStatus{grpc::StatusCode::NOT_FOUND, "base ledger not validated"};
|
||||
grpc::Status const errorStatus{grpc::StatusCode::NOT_FOUND, "desired ledger not validated"};
|
||||
return {response, errorStatus};
|
||||
}
|
||||
|
||||
|
||||
@@ -27,7 +27,9 @@ doPing(RPC::JsonContext& context)
|
||||
break;
|
||||
case Role::PROXY:
|
||||
ret[jss::role] = "proxied";
|
||||
ret[jss::ip] = std::string{context.headers.forwardedFor};
|
||||
if (!context.headers.forwardedFor.empty())
|
||||
ret[jss::ip] = std::string{context.headers.forwardedFor};
|
||||
break;
|
||||
default:;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user