Project

General

Profile

Actions

Bug #58145

closed

Linkvalidator - HEAD response codes

Added by Stefan Weißwange about 10 years ago. Updated over 5 years ago.

Status:
Closed
Priority:
Must have
Assignee:
-
Category:
Linkvalidator
Target version:
Start date:
2014-04-24
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
6.1
PHP Version:
5.4
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

The linkvalidator checks the response on a HEAD-request for HTTP-Status-Code 405, which does not work in some cases.

Those servers respond with a HTTP 500, so no other checks are made. We have changed this check, now all error codes (4xx, 5xx) force a second try with a GET-request. See applied diff.

BTW: There is no way to choose "Linkvalidator" in the Project-Select-Box, the issue-form disappears after choosing "Linkvalidator".


Files

ExternalLinktype.diff (648 Bytes) ExternalLinktype.diff Stefan Weißwange, 2014-04-24 09:54

Related issues 1 (0 open1 closed)

Related to TYPO3 Core - Feature #54513: linkvalidator: improve tolerance for forbidden HEAD requestsClosed2013-12-19

Actions
Actions #1

Updated by Markus Klein about 10 years ago

Don't think it is a good idea to retry it for all errors. Do you know if the 500 error is produced by some specific server software?

Btw. for 6.2 we added a check for 403 already.

Actions #2

Updated by Stefan Weißwange about 10 years ago

Markus Klein wrote:

Don't think it is a good idea to retry it for all errors. Do you know if the 500 error is produced by some specific server software?

You're right, but at the moment we have not better idea. ;-)

As an example, try this Link http://eur-lex.europa.eu/LexUriServ/LexUriServ.do?uri=OJ:L:2009:140:0063:0087:de:PDF. Here is a curl output, which shows the 500 error on a HEAD-request. With a GET the document is retrieved.

curl -vI http://eur-lex.europa.eu/LexUriServ/LexUriServ.do?uri=OJ:L:2009:140:0063:0087:de:PDF
* About to connect() to eur-lex.europa.eu port 80 (#0)
*   Trying 147.67.136.102...
* connected
* Connected to eur-lex.europa.eu (147.67.136.102) port 80 (#0)
> HEAD /LexUriServ/LexUriServ.do?uri=OJ:L:2009:140:0063:0087:de:PDF HTTP/1.1
> User-Agent: curl/7.26.0
> Host: eur-lex.europa.eu
> Accept: */*
> 
* additional stuff not fine transfer.c:1037: 0 0
* HTTP 1.1 or later with persistent connection, pipelining supported
< HTTP/1.1 500 Internal Server Error
HTTP/1.1 500 Internal Server Error
< Date: Thu, 24 Apr 2014 08:43:54 GMT
Date: Thu, 24 Apr 2014 08:43:54 GMT
< Content-Type: text/html; charset=UTF-8
Content-Type: text/html; charset=UTF-8
< Content-Language: en
Content-Language: en
< Server: Europa
Server: Europa
< Set-Cookie: JSESSIONID=jJt6TYTKTCMvL0xt9XPGgDlpRPzh9T8w2FXwnyZ7tVQM5GvqfhQ1!-1614442047; path=/; HttpOnly
Set-Cookie: JSESSIONID=jJt6TYTKTCMvL0xt9XPGgDlpRPzh9T8w2FXwnyZ7tVQM5GvqfhQ1!-1614442047; path=/; HttpOnly
< Proxy-Connection: Keep-Alive
Proxy-Connection: Keep-Alive
< Connection: Keep-Alive
Connection: Keep-Alive
* no chunk, no close, no size. Assume close to signal end

< 
* Closing connection #0
Actions #3

Updated by Markus Klein about 10 years ago

Hm, ok.
Maybe the server does not like the user-agent.

Can you prepare a patch?
http://wiki.typo3.org/CWT

Actions #4

Updated by Stefan Weißwange about 10 years ago

Markus Klein wrote:

Hm, ok.
Maybe the server does not like the user-agent.

No, I tried some "standard" agents with curl with the same result.

Can you prepare a patch?
http://wiki.typo3.org/CWT

Ok, I'll give it a try. ;-)

Actions #5

Updated by Gerrit Code Review about 10 years ago

  • Status changed from New to Under Review

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

Actions #6

Updated by Gerrit Code Review over 9 years ago

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/33909

Actions #7

Updated by Gerrit Code Review over 9 years ago

Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/33909

Actions #8

Updated by Stefan Weißwange over 9 years ago

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

Updated by Gerrit Code Review over 9 years ago

  • Status changed from Resolved to Under Review

Patch set 1 for branch TYPO3_6-2 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/35025

Actions #10

Updated by Stefan Weißwange over 9 years ago

  • Status changed from Under Review to Resolved
Actions #11

Updated by Benni Mack over 5 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF