From 666200eeb863ee24cdd9c3d744e2f0fd24021487 Mon Sep 17 00:00:00 2001 From: "J. Eric Ivancich" Date: Fri, 12 Dec 2025 12:54:12 -0500 Subject: [PATCH] rgw: enforce max max for reshard logs listings Previously a list of reshard logs could be unlimited. We need to enforce time limits on CLS ops. Signed-off-by: J. Eric Ivancich --- src/cls/rgw/cls_rgw.cc | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/cls/rgw/cls_rgw.cc b/src/cls/rgw/cls_rgw.cc index 1d69ce68a586..fbe5525a40cb 100644 --- a/src/cls/rgw/cls_rgw.cc +++ b/src/cls/rgw/cls_rgw.cc @@ -3580,12 +3580,10 @@ static int rgw_bi_list_op(cls_method_context_t hctx, op.max, max, op.reshardlog); int ret; - uint32_t count = 0; - bool more = false; rgw_cls_bi_list_ret op_ret; if (op.reshardlog) { - ret = reshard_log_list_entries(hctx, op.marker, op.max, + ret = reshard_log_list_entries(hctx, op.marker, max, op_ret.entries, &op_ret.is_truncated); if (ret < 0) { @@ -3597,6 +3595,9 @@ static int rgw_bi_list_op(cls_method_context_t hctx, return 0; } + uint32_t count = 0; + bool more = false; + ret = list_plain_entries(hctx, op.name_filter, op.marker, max, &op_ret.entries, &more, PlainEntriesRegion::Low); if (ret < 0) { -- 2.47.3