Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F35993285
0001-api-Only-add-actor-table-to-table-list-when-querying.patch
Zabe
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Authored By
Zabe
Jan 5 2023, 11:42 AM
2023-01-05 11:42:01 (UTC+0)
Size
1 KB
Referenced Files
None
Subscribers
None
0001-api-Only-add-actor-table-to-table-list-when-querying.patch
View Options
From 2e8aa8a5d6ce22173cda51f3e67f0f9539e1c36a Mon Sep 17 00:00:00 2001
From: Alexander Vorwerk <zabe@avorwerk.net>
Date: Thu, 5 Jan 2023 12:41:09 +0100
Subject: [PATCH] api: Only add actor table to table list when querying from it
Bug: T233004
Bug: T326293
Change-Id: I88bf55a672c91f50e5945221b52226ec7cf4cd0d
---
src/Api/ApiQueryCheckUserLog.php | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/Api/ApiQueryCheckUserLog.php b/src/Api/ApiQueryCheckUserLog.php
index 8379771a..c0f00b80 100644
--- a/src/Api/ApiQueryCheckUserLog.php
+++ b/src/Api/ApiQueryCheckUserLog.php
@@ -31,7 +31,7 @@ class ApiQueryCheckUserLog extends ApiQueryBase {
$continue = $params['continue'];
$dir = $params['dir'];
- $this->addTables( [ 'cu_log', 'actor' ] );
+ $this->addTables( [ 'cu_log' ] );
$this->addOption( 'LIMIT', $limit + 1 );
$this->addTimestampWhereRange( 'cul_timestamp', $dir, $params['from'], $params['to'] );
$fields = [
@@ -39,6 +39,7 @@ class ApiQueryCheckUserLog extends ApiQueryBase {
];
if ( $this->getConfig()->get( 'CheckUserLogActorMigrationStage' ) & SCHEMA_COMPAT_READ_NEW ) {
+ $this->addTables( [ 'actor' ] );
$this->addJoinConds( [ 'actor' => [ 'JOIN', 'actor_id=cul_actor' ] ] );
$fields[] = 'actor_name';
} else {
--
2.17.1
File Metadata
Details
Attached
Mime Type
text/x-diff
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
10051353
Default Alt Text
0001-api-Only-add-actor-table-to-table-list-when-querying.patch (1 KB)
Attached To
Mode
T326293: CVE-2023-29139: API request timeout - CheckUserLog
Attached
Detach File
Event Timeline
Log In to Comment