mirror of
https://github.com/XRPLF/rippled.git
synced 2025-12-06 17:27:55 +00:00
Don't load trust lines that can't participate in path finding
* "A path is considered invalid if and only if it enters and exits an address node through trust lines where No Ripple has been enabled for that address." (https://xrpl.org/rippling.html#specifics) * When loading trust lines for an account "Alice" which was reached via a trust line that has the No Ripple flag set on Alice's side, do not use or cache any of Alice's trust lines which have the No Ripple flag set on Alice's side. For typical "end-user" accounts, this will return no trust lines.
This commit is contained in:
@@ -43,6 +43,12 @@ class AmendmentBlocked_test : public beast::unit_test::suite
|
||||
Account const ali{"ali", KeyType::secp256k1};
|
||||
env.fund(XRP(10000), alice, bob, gw);
|
||||
env.memoize(ali);
|
||||
// This close() ensures that all the accounts get created and their
|
||||
// default ripple flag gets set before the trust lines are created.
|
||||
// Without it, the ordering manages to create alice's trust line with
|
||||
// noRipple set on gw's end. The existing tests pass either way, but
|
||||
// better to do it right.
|
||||
env.close();
|
||||
env.trust(USD(600), alice);
|
||||
env.trust(USD(700), bob);
|
||||
env(pay(gw, alice, USD(70)));
|
||||
|
||||
Reference in New Issue
Block a user