$matches[1]
diff --git a/psalm.xml b/psalm.xml
index 4b3a1cadd4..83a7d3d1ab 100644
--- a/psalm.xml
+++ b/psalm.xml
@@ -18,7 +18,6 @@
';
@@ -282,14 +282,15 @@ class GeneratorTest extends AbstractTestCase
],
[
[
- 'url.php?url=http://phpmyadmin.net/',
+ 'index.php?route=/url&url=http://phpmyadmin.net/',
null,
'text',
[],
'_blank',
],
1000,
- 'text',
+ 'text',
],
[
[
@@ -355,12 +356,12 @@ class GeneratorTest extends AbstractTestCase
public function testGetServerSSL(): void
{
$sslNotUsed = 'SSL is not being used'
- . '
';
$sslNotUsedCaution = 'SSL is not being used'
- . '
';
@@ -414,7 +415,7 @@ class GeneratorTest extends AbstractTestCase
$this->assertEquals(
'SSL is used with disabled verification'
- . '
',
Generator::getServerSSL()
@@ -428,7 +429,7 @@ class GeneratorTest extends AbstractTestCase
$this->assertEquals(
'SSL is used without certification authority'
- . '
',
Generator::getServerSSL()
@@ -443,7 +444,7 @@ class GeneratorTest extends AbstractTestCase
$this->assertEquals(
'SSL is used'
- . '
',
Generator::getServerSSL()
diff --git a/test/classes/Html/MySQLDocumentationTest.php b/test/classes/Html/MySQLDocumentationTest.php
index 9057667c5c..7e84e66501 100644
--- a/test/classes/Html/MySQLDocumentationTest.php
+++ b/test/classes/Html/MySQLDocumentationTest.php
@@ -18,7 +18,7 @@ class MySQLDocumentationTest extends AbstractTestCase
$GLOBALS['cfg']['ServerDefault'] = 1;
$this->assertEquals(
- '
',
MySQLDocumentation::showDocumentation('page', 'anchor')
diff --git a/test/classes/MessageTest.php b/test/classes/MessageTest.php
index d9b9b9f7ed..d3073e6278 100644
--- a/test/classes/MessageTest.php
+++ b/test/classes/MessageTest.php
@@ -352,7 +352,7 @@ class MessageTest extends AbstractTestCase
],
[
'[a@https://example.com/@Documentation]link[/a]',
- 'link',
+ 'link',
],
[
'[a@./non-existing@Documentation]link[/a]',
@@ -360,19 +360,19 @@ class MessageTest extends AbstractTestCase
],
[
'[doc@foo]link[/doc]',
- 'link',
],
[
'[doc@page@anchor]link[/doc]',
- 'link',
],
[
'[doc@faqmysql]link[/doc]',
- 'link',
],
@@ -463,7 +463,7 @@ class MessageTest extends AbstractTestCase
{
$this->object->setMessage('[kbd]test[/kbd] [doc@cfg_Example]test[/doc]');
$this->assertEquals(
- 'test test',
$this->object->getMessage()
diff --git a/test/classes/Plugins/Auth/AuthenticationConfigTest.php b/test/classes/Plugins/Auth/AuthenticationConfigTest.php
index 833351b9ea..6187b54850 100644
--- a/test/classes/Plugins/Auth/AuthenticationConfigTest.php
+++ b/test/classes/Plugins/Auth/AuthenticationConfigTest.php
@@ -97,7 +97,7 @@ class AuthenticationConfigTest extends AbstractTestCase
);
$this->assertStringContainsString(
- 'MySQL said: ' .
'
assertEquals(
- 'link',
+ 'link',
Sanitize::sanitizeMessage('[a@https://www.phpmyadmin.net/@target]link[/a]')
);
@@ -60,7 +60,7 @@ class SanitizeTest extends AbstractTestCase
public function testDoc(string $link, string $expected): void
{
$this->assertEquals(
- 'doclink',
Sanitize::sanitizeMessage('[doc@' . $link . ']doclink[/doc]')
);
@@ -121,7 +121,7 @@ class SanitizeTest extends AbstractTestCase
public function testLinkAndXssInHref(): void
{
$this->assertEquals(
- 'doc'
+ 'doc'
. '[a@javascript:alert(\'XSS\');@target]link',
Sanitize::sanitizeMessage(
'[a@https://docs.phpmyadmin.net/]doc[/a][a@javascript:alert(\'XSS\');@target]link[/a]'
@@ -402,13 +402,13 @@ class SanitizeTest extends AbstractTestCase
],
[
false,
- './url.php?url=https://example.com',
+ 'index.php?route=/url&url=https://example.com',
false,
false,
],
[
true,
- './url.php?url=https%3a%2f%2fexample.com',
+ 'index.php?route=/url&url=https%3a%2f%2fexample.com',
false,
false,
],
diff --git a/url.php b/url.php
deleted file mode 100644
index 44fb191800..0000000000
--- a/url.php
+++ /dev/null
@@ -1,42 +0,0 @@
-PHP 7.2.5+ is required.Currently installed version is: ' . PHP_VERSION . '
'); -} - -// phpcs:disable PSR1.Files.SideEffects -define('PHPMYADMIN', true); -// phpcs:enable - -require_once ROOT_PATH . 'libraries/constants.php'; - -/** - * Activate autoloader - */ -if (! @is_readable(AUTOLOAD_FILE)) { - die( - 'File ' . AUTOLOAD_FILE . ' missing or not readable.
' - . 'Most likely you did not run Composer to ' - . '' - . 'install library files.
' - ); -} - -require AUTOLOAD_FILE; - -$GLOBALS['isMinimumCommon'] = true; - -Common::run(); - -UrlRedirector::redirect();