aboutsummaryrefslogtreecommitdiffstats
path: root/lib/base.php
diff options
context:
space:
mode:
authorSimon L <szaimen@e.mail.de>2023-05-16 11:39:39 +0200
committerSimon L <szaimen@e.mail.de>2023-05-16 11:39:39 +0200
commitd293293cdaf10745459e98cce70412882241fdec (patch)
tree44a86d733bdc25b0faa75854ded1a2331978509a /lib/base.php
parent25dd264965905316672631db95707e9051d57d69 (diff)
downloadnextcloud-server-d293293cdaf10745459e98cce70412882241fdec.tar.gz
nextcloud-server-d293293cdaf10745459e98cce70412882241fdec.zip
Fixed bug which 'overwritewebroot' does not work with 'overwritecondaddr'.
Signed-off-by: Takahiro Nagai <78393959+takahiro-blab@users.noreply.github.com> Signed-off-by: Simon L <szaimen@e.mail.de>
Diffstat (limited to 'lib/base.php')
-rw-r--r--lib/base.php3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/base.php b/lib/base.php
index c7fde4136fe..83f97963c4d 100644
--- a/lib/base.php
+++ b/lib/base.php
@@ -161,6 +161,9 @@ class OC {
'SCRIPT_FILENAME' => $_SERVER['SCRIPT_FILENAME'] ?? null,
],
];
+ if (isset($_SERVER['REMOTE_ADDR'])) {
+ $params['server']['REMOTE_ADDR'] = $_SERVER['REMOTE_ADDR'];
+ }
$fakeRequest = new \OC\AppFramework\Http\Request(
$params,
new \OC\AppFramework\Http\RequestId($_SERVER['UNIQUE_ID'] ?? '', new \OC\Security\SecureRandom()),