We're calling on all EU-based Mozillians with iOS or iPadOS devices to help us monitor Apple’s new browser choice screens. Join the effort to hold Big Tech to account!

為了改善您的使用體驗,本網站正在進行維護,部分功能暫時無法使用。若本站的文件無法解決您的問題,想要向社群發問的話,請到 Twitter 上的 @FirefoxSupport 或 Reddit 上的 /r/firefox 發問,我們的社群成員將很快會回覆您的疑問。

搜尋 Mozilla 技術支援網站

防止技術支援詐騙。我們絕對不會要求您撥打電話或發送簡訊,或是提供個人資訊。請用「回報濫用」功能回報可疑的行為。

了解更多

Cannot add HTTPS exception for localhost

  • 5 回覆
  • 1 有這個問題
  • 1 次檢視
  • 最近回覆由 thany

more options

I need to add a HTTPS exception for localhost. I'm developing a website and I don't have (or need) a certificate for localhost. I can't make the site point to HTTP - I have to have it as HTTPS. Hence, I need a security exception.

One attempt:

So then, I go into Options -> Privacy & Security -> section Certificates -> tab Servers -> button Add Exception. Then I type in the address: https://localhost:5001 and click Get Certificate. As expected, it says "No Information". But I also cannot click the Confirm Security Exception button. It's greyed out. Why?

Another attempt:

I just go to the site in question. I then get a page that tells me the certificate is broken or whatever (error code: SSL_ERROR_RX_RECORD_TOO_LONG). I don't give a toss how or why the SSL connection is broken, that's what the exception is for. But there's no way to add an exception from this page.

I need to add this exception. How do I do this?

I need to add a HTTPS exception for localhost. I'm developing a website and I don't have (or need) a certificate for localhost. I can't make the site point to HTTP - I have to have it as HTTPS. Hence, I need a security exception. One attempt: So then, I go into Options -> Privacy & Security -> section Certificates -> tab Servers -> button Add Exception. Then I type in the address: https://localhost:5001 and click Get Certificate. As expected, it says "No Information". But I also cannot click the Confirm Security Exception button. It's greyed out. Why? Another attempt: I just go to the site in question. I then get a page that tells me the certificate is broken or whatever (error code: SSL_ERROR_RX_RECORD_TOO_LONG). I don't give a toss how or why the SSL connection is broken, that's what the exception is for. But there's no way to add an exception from this page. I need to add this exception. How do I do this?
附加的畫面擷圖

所有回覆 (5)

more options

Hello,

Firefox is unable to add an exception because it's unable to read the certificate. I would like to ask for more information.

1. Please check whether you have this problem at other websites, for example https://support.mozilla.org/ .

2. Try Firefox Safe Mode to see if the problem goes away. Firefox Safe Mode is a troubleshooting mode that temporarily turns off hardware acceleration, resets some settings, and disables add-ons (extensions and themes). If Firefox is open, you can restart in Firefox Safe Mode from the Help menu: Click the menu button, click Help and select Restart with Add-ons Disabled. If Firefox is not running, you can start Firefox in Safe Mode as follows: Hold the Shift key when you open the Firefox desktop or Start menu shortcut. When the Firefox Safe Mode window appears, select "Start in Safe Mode".

SafeMode-Fx35

If the issue is not present in Firefox Safe Mode, your problem is probably caused by an extension, theme, or hardware acceleration. Please follow the steps in the Troubleshoot extensions, themes and hardware acceleration issues to solve common Firefox problems article to find the cause. To exit Firefox Safe Mode, just close Firefox and wait a few seconds before opening Firefox for normal use again. When you figure out what's causing your issues, please let us know. It might help others with the same problem.

3. Check your proxy settings by following the guide at Connection settings in Firefox. Check whether the issue happens when you use 'system proxy settings' or 'no proxy'.


Please tell whether the safe mode or altering the proxy settings affects the issue. Thank you.

more options

Hello,

Please check the two questions above. We need this information to know what the issue is.

more options

1) It's a problem for localhost. Did you not get that?

2) The problem persists in safe mode.

3) Proxy settings are fine.

more options

Does using https://127.0.0.1:5001/ give the same problem with checking the certificate?

See also:

more options

I'm not sure what you mean by "checking the certificate". What certificate?

I did do network logging while the bug occurs, and the log is here: https://pastebin.com/PUw1ikq7

由 thany 於 修改