Compare commits

..

13 Commits

Author SHA1 Message Date
Ed Hennis
9405f8823d Merge branch 'ximinez/lending-XLS-66' into ximinez/lending-enabled 2025-11-28 15:52:59 -05:00
Ed Hennis
06e79bd3d5 Merge branch 'ximinez/lending-XLS-66' into ximinez/lending-enabled 2025-11-26 00:25:51 -05:00
Ed Hennis
50a523f77a Merge branch 'ximinez/lending-XLS-66' into ximinez/lending-enabled 2025-11-24 21:49:43 -05:00
Ed Hennis
67886de4ab Merge branch 'ximinez/lending-XLS-66' into ximinez/lending-enabled 2025-11-24 21:43:03 -05:00
Ed Hennis
f41b2c11d4 Merge branch 'ximinez/lending-XLS-66' into ximinez/lending-enabled 2025-11-21 14:35:06 -05:00
Ed Hennis
ae00ec7ac5 Merge branch 'ximinez/lending-XLS-66' into ximinez/lending-enabled 2025-11-18 22:51:36 -05:00
Ed Hennis
baa875db19 Merge branch 'ximinez/lending-XLS-66' into ximinez/lending-enabled 2025-11-15 03:09:11 -05:00
Ed Hennis
fc7350c487 Merge branch 'ximinez/lending-XLS-66' into ximinez/lending-enabled 2025-11-13 14:45:53 -05:00
Ed Hennis
ae497c14a0 Merge branch 'ximinez/lending-XLS-66' into ximinez/lending-enabled 2025-11-13 12:20:53 -05:00
Ed Hennis
bf0d8fc399 Merge branch 'ximinez/lending-XLS-66' into ximinez/lending-enabled 2025-11-13 01:53:36 -05:00
Ed Hennis
7ebee40951 Merge branch 'ximinez/lending-XLS-66' into ximinez/lending-enabled 2025-11-12 20:12:30 -05:00
Ed Hennis
cee1e6a6ed Merge branch 'ximinez/lending-XLS-66' into ximinez/lending-enabled 2025-11-12 14:17:18 -05:00
Ed Hennis
b815477ca1 Change LendingProtocol feature and dependencies to supported 2025-11-10 19:54:18 -05:00
5 changed files with 6 additions and 45 deletions

View File

@@ -16,7 +16,7 @@
// Add new amendments to the top of this list.
// Keep it sorted in reverse chronological order.
XRPL_FEATURE(LendingProtocol, Supported::no, VoteBehavior::DefaultNo)
XRPL_FEATURE(LendingProtocol, Supported::yes, VoteBehavior::DefaultNo)
XRPL_FEATURE(PermissionDelegationV1_1, Supported::no, VoteBehavior::DefaultNo)
XRPL_FIX (DirectoryLimit, Supported::yes, VoteBehavior::DefaultNo)
XRPL_FIX (IncludeKeyletFields, Supported::yes, VoteBehavior::DefaultNo)
@@ -30,7 +30,7 @@ XRPL_FIX (EnforceNFTokenTrustlineV2, Supported::yes, VoteBehavior::DefaultNo
XRPL_FIX (AMMv1_3, Supported::yes, VoteBehavior::DefaultNo)
XRPL_FEATURE(PermissionedDEX, Supported::yes, VoteBehavior::DefaultNo)
XRPL_FEATURE(Batch, Supported::yes, VoteBehavior::DefaultNo)
XRPL_FEATURE(SingleAssetVault, Supported::no, VoteBehavior::DefaultNo)
XRPL_FEATURE(SingleAssetVault, Supported::yes, VoteBehavior::DefaultNo)
XRPL_FIX (PayChanCancelAfter, Supported::yes, VoteBehavior::DefaultNo)
// Check flags in Credential transactions
XRPL_FIX (InvalidTxFlags, Supported::yes, VoteBehavior::DefaultNo)

View File

@@ -3176,24 +3176,6 @@ requireAuth(
!isTesSuccess(err))
return err;
}
// requireAuth is also recursive if the _account_ is a vault
auto const sleAccount = view.read(keylet::account(account));
if (!sleAccount)
return tefINTERNAL; // LCOV_EXCL_LINE
if (sleAccount->isFieldPresent(sfVaultID))
{
auto const sleVault =
view.read(keylet::vault(sleAccount->getFieldH256(sfVaultID)));
if (!sleVault)
return tefINTERNAL; // LCOV_EXCL_LINE
auto const ownerAcct = sleVault->getAccountID(sfOwner);
if (auto const err =
requireAuth(view, mptIssue, ownerAcct, authType, depth + 1);
!isTesSuccess(err))
return err;
}
}
auto const mptokenID = keylet::mptoken(mptID.key, account);

View File

@@ -2358,18 +2358,6 @@ class Vault_test : public beast::unit_test::suite
.amount = asset(100)});
env(tx, ter(tecNO_AUTH));
// Withdrawal to other (authorized) accounts doesn't work.
// Issuer would have to VaultClawback
tx[sfDestination] = issuer.human();
env(tx, ter(tecNO_AUTH));
tx[sfDestination] = owner.human();
env(tx, ter(tecNO_AUTH));
env.close();
// Issuer reauthorizes
mptt.authorize({.account = issuer, .holder = depositor});
env.close();
// Withdrawal to other (authorized) accounts works
tx[sfDestination] = issuer.human();
env(tx);
@@ -2380,13 +2368,6 @@ class Vault_test : public beast::unit_test::suite
env.close();
}
// Re-unauthorize
mptt.authorize(
{.account = issuer,
.holder = depositor,
.flags = tfMPTUnauthorize});
env.close();
{
// Cannot deposit some more
auto tx = vault.deposit(

View File

@@ -187,9 +187,9 @@ class Feature_test : public beast::unit_test::suite
BEAST_EXPECTS(jrr[jss::status] == jss::success, "status");
jrr.removeMember(jss::status);
BEAST_EXPECT(jrr.size() == 1);
BEAST_EXPECT(jrr.isMember(
"740352F2412A9909880C23A559FCECEDA3BE2126FED62FC7660D6"
"28A06927F11"));
BEAST_EXPECT(
jrr.isMember("12523DF04B553A0B1AD74F42DDB741DE8DC06A03FC089A0EF197E"
"2A87F1D8107"));
auto feature = *(jrr.begin());
BEAST_EXPECTS(feature[jss::name] == "fixAMMOverflowOffer", "name");

View File

@@ -1,6 +1,4 @@
#include <xrpld/app/tx/detail/VaultWithdraw.h>
//
#include <xrpld/app/tx/detail/Payment.h>
#include <xrpl/ledger/CredentialHelpers.h>
#include <xrpl/ledger/View.h>
@@ -199,7 +197,7 @@ VaultWithdraw::doApply()
assetsAvailable -= assetsWithdrawn;
view().update(vault);
AccountID const& vaultAccount = vault->at(sfAccount);
auto const& vaultAccount = vault->at(sfAccount);
// Transfer shares from depositor to vault.
if (auto const ter = accountSend(
view(),