cooking good
cooking good

Reputation: 1426

Console errors. Failed to load resource: net::ERR_INSECURE_RESPONSE

I'm getting them on my links in my head.

GET https://fr.s.us/js/jquery-ui.css net::ERR_INSECURE_RESPONSE

GET https://fr.s.us/js/jquery-1.9.1.min.js net::ERR_INSECURE_RESPONSE

GET https://fr.s.us/js/jquery-ui.js net::ERR_INSECURE_RESPONSE

Someone please enlighten me on these jquery console errors..

Failed to load resource: net::ERR_INSECURE_RESPONSE 

Upvotes: 89

Views: 297780

Answers (13)

eb80
eb80

Reputation: 4738

I am assuming you're using Chrome.

If so, the root problem is a certificate mismatch / expired certificate.

You can see this for yourself in the code here.

Note in particular the use of the very constant you reference in the code on line 48 of the C++ file I sent you:

 case net::ERR_INSECURE_RESPONSE:

The current version of this file is here. The error status ERR_INSECURE_RESPONSE may not any longer be on line 48 but the error code still exists in the SSL certificate portion of the code.

Note: Make sure to use the hostname which is listed in the SSL certificate, chrome automatically switches to the right hostname if you are browsing but not when using javascript.

Upvotes: 116

Sven Junior
Sven Junior

Reputation: 1

Encode and make it like this: $_GET[].

Upvotes: 0

L.Johnny
L.Johnny

Reputation: 44

If you use chrome, you can make a shortcut,right click and edit the shortcut's target, append this after target's string:

--ignore-certificate-errors

The complete string looks like this:

"C:\Program Files (x86)\Google\Chrome\Application\chrome.exe" --ignore-certificate-errors

Upvotes: 0

Promise Akpan
Promise Akpan

Reputation: 11

It was on Chrome for Android in my case. All the static files served from a CDN with a CNAME that's SSL encrypted were not showing up. On Chrome desktop, it all showed fine.

Broken SSL cert

When I properly added the certs in ca_bundle the files displayed correctly.

Chrome for Android takes encryption seriously unlike Desktop. I hope this saves you time and stress

Upvotes: 1

Ramin Bateni
Ramin Bateni

Reputation: 17415

In my case, sometimes when i tests my MVC project by a localhost https url (E.g. https://localhost:44373/), the Chrome raise this error: net::ERR_INSECURE_RESPONSE for the website resources (such as JS files).

So i resolve it by Clear Cache. Then i refresh the page and Chrome show me a special page about insecure url and i just allow it by click on Proceed to localhost (unsafe).

enter image description here

Upvotes: 2

Naina Shukla
Naina Shukla

Reputation: 21

Try to open it in an incognito window. I hope this will help. Alternatively, you could modify application/.htaccess like so:

RewriteEngine on
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?/$1 [L]

Upvotes: 2

Marco Rey
Marco Rey

Reputation: 69

You are trying to get data from an https that does not have certificate. Change "https://" to "http://". Worked for me.

Upvotes: 1

KoalaBear
KoalaBear

Reputation: 2948

For me the problem was the <base href="https://domain.ext/"> tag.

After removing, it was OK. Cannot really understand why it was a problem.

Upvotes: 1

Gabriel Petrovay
Gabriel Petrovay

Reputation: 21884

This can also happen if you have Chrome update automatically. Open Check chrome://help. The status should be:

Google Chrome is up to date.

Sometimes the status is requesting for a Chrome restart. In this case I had similar issues with several resources failing to load due to net::ERR_INSECURE_RESPONSE. After restarting Chrome, everything worked normally.

Upvotes: 6

Andy Simpson
Andy Simpson

Reputation: 99

I had this problem with chrome when I was working on a WordPress site. I added this code

$_SERVER['HTTPS'] = false;

into the theme's functions.php file - it asks you to log in again when you save the file but once it's logged in it works straight away.

Upvotes: 8

KingRider
KingRider

Reputation: 2257

Learn about CORS, try crossorigin.me is work fine

Example: https://crossorigin.me/https://fr.s.us/js/jquery-ui.css

Not show a message error and continue page white, u need see error is try

http://cors.io/?u=https://fr.s.us/js/jquery-ui.css

enjoin us ;-)

Upvotes: 1

Mike Cheel
Mike Cheel

Reputation: 13116

When I had the problem recently it was a cross site issue where our dev server hosts our analytics software as well as the application. In the other environments the chrome console would show this error and the javascript file (tracker) on the dev server as the source. This was causing issues for QA personnel who were trying to view the analytics data for their environment (nothing was being captured because of this issue).

The solution to fix this in-house was to add the SSL certificate the DEV site was using to the Trusted People store on the QA people's machine.

If this was a problem in production I would most likely move the javascript into the actual web apps.

Upvotes: 5

user2915403
user2915403

Reputation:

The supplied host is not resolving for me (custom DNS or self configured host?) so I can only hazard to guess.

But as you are requesting the resources over SSL it is likely the certificate is invalid. Either it is self-signed and has not been added to your browser/OS exceptions or it is otherwise invalid.

Try the URI directly in the same browser and inspect the certificate.

Edit: this is in no way related to jQuery, JavaScript or CSS directly.

Upvotes: 29

Related Questions