• Welcome to Sitemap Generator Forum.
 

Error when crawling HTTP headers: x_csize: 0

Started by karen9, May 26, 2016, 10:42:13 AM

Previous topic - Next topic

karen9

Hello I keep getting this error when trying to crawl my site for a sitemap. I have tried turning on Curl and also using the website IP address and still keep getting the same error.

Below is the error code I keep getting:

There was an error while retrieving the URL specified: [ External links are visible to forum administrators only ]
HTTP Code:

HTTP headers:
x_csize: 0

HTTP output:


Thanks Karen

XML-Sitemaps Support

Hello,

Probably there is a configuration problem - it looks like your server doesn't allow local network connections via port 80 (http) - as a result sitemap generator is not able to crawl the site. This is usually related to firewall installed at the host - could you please contact your hosting support regarding this?

edge4marketing

I am having the same issue as in the subject. Please advise.


robert23

Our websites on this server have had no problems until i tried it on https:// and I got
HTTP Code:

HTTP headers:
x_csize: 0

HTTP output:

do i have to adjust for https:

XML-Sitemaps Support

Hello,

you need to make sure that PHP script is allowed to access your website. You can check this by using a test script like this:
<?php

$initurl = '[ External links are visible to logged in users only ]';

$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $initurl);
curl_setopt($ch, CURLOPT_HEADER, 1);
curl_setopt($ch, CURLOPT_VERBOSE, 1);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);

$fdata = curl_exec($ch);
curl_close($ch);
print_r($fdata);

Save it as PHP file and open in browser.

robert23

I added script and this was the response

HTTP/1.1 200 OK Content-Type: text/html; charset=UTF-8 Transfer-Encoding: chunked Connection: keep-alive Keep-Alive: timeout=15 Date: Fri, 17 Feb 2017 15:50:13 GMT Server: Apache X-Powered-By: PHP/7.0.14 Link: ; rel="[ External links are visible to forum administrators only ]", ; rel=shortlink


michaelstuartkelly

Hi,

PHP cURL is not using an updated set of root certificates to verify server certs.

Around early September 2014, Mozilla removed the trust bits from the certs in their CA bundle that were still using RSA 1024 bit keys. This may lead to TLS libraries having a hard time to verify some sites if the library in question doesn't properly support "path discovery" as per RFC 4158. (That includes OpenSSL and GnuTLS.)

Resolution

Download the cacert.pem file from the main curl website [external links are visible to admins only] .

Add the following into php.ini or add into 'Additional directives' under Websites & Domains > PHP settings :

curl.cainfo = /var/www/vhosts/WebSite.com/httpdocs/cacert.pem