Project

General

Profile

Actions

Bug #86921

closed

Linkvalidator reports exception on links with tilde (~)

Added by Sybille Peters about 6 years ago. Updated almost 5 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Linkvalidator
Target version:
-
Start date:
2018-11-13
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
9
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

Error message: Exception: NAMEPREP: Prohibited input U+0000007E

Use a link with tilde

TYPO3 version: 9-dev (master)


Related issues 2 (0 open2 closed)

Related to TYPO3 Core - Bug #85069: Linkvalidator reports links to pages with certain cookie-alerts as brokenClosed2018-05-23

Actions
Related to TYPO3 Core - Bug #80139: Tilde in base URL causes exceptionClosed2017-03-04

Actions
Actions #1

Updated by Sybille Peters about 6 years ago

  • Related to Bug #85069: Linkvalidator reports links to pages with certain cookie-alerts as broken added
Actions #2

Updated by Sybille Peters about 6 years ago

  • Related to Bug #80139: Tilde in base URL causes exception added
Actions #3

Updated by Dmitry Dulepov over 5 years ago

Following the discussion with idna_convert guys, it is linkvalidator, who calls a wrong method. Here is a patch:

--- a/typo3/sysext/linkvalidator/Classes/Linktype/ExternalLinktype.php
+++ b/typo3/sysext/linkvalidator/Classes/Linktype/ExternalLinktype.php
@@ -209,7 +209,7 @@
     protected function preprocessUrl(string $url): string
     {
         try {
-            return (new IdnaConvert())->encode($url);
+            return (new IdnaConvert())->encodeUri($url);
         } catch (\Exception $e) {
             // in case of any error, return empty url.
             $this->errorParams['errorType'] = 'exception';
Actions #4

Updated by Gerrit Code Review over 5 years ago

  • Status changed from New to Under Review

Patch set 1 for branch 9.5 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/61495

Actions #5

Updated by Dmitry Dulepov over 5 years ago

The fix is contributed by the University of Basel.

Actions #6

Updated by Gerrit Code Review about 5 years ago

Patch set 2 for branch 9.5 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/61495

Actions #7

Updated by Gerrit Code Review about 5 years ago

Patch set 3 for branch 9.5 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/61495

Actions #8

Updated by Gerrit Code Review about 5 years ago

Patch set 1 for branch TYPO3_8-7 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/61592

Actions #9

Updated by Dmitry Dulepov about 5 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100
Actions #10

Updated by Benni Mack almost 5 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF