博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
如何在macOS中安装本地SSL证书
阅读量:2508 次
发布时间:2019-05-11

本文共 1711 字,大约阅读时间需要 5 分钟。

You’ve written an app that should use HTTPS, but it’s not working: you’re getting a warning when you try to access it using HTTPS, even though you created a local certificate.

您编写了应使用HTTPS的应用程序,但该应用程序无法正常工作:即使您创建了本地证书,当您尝试使用HTTPS访问该应用程序时也会收到警告。

That’s because by default the browser does not trust local certificates.

这是因为默认情况下,浏览器不信任本地证书。

We need to install it!

我们需要安装它!

I assume you use Chrome in this section

我假设您在本节中使用Chrome

Click the “Not Secure” box near the address bar, and a little panel should show up:

单击地址栏附近的“不安全”框,然后会出现一个小面板:

Click the Certificate item in the box, and you should see another panel show up, with the certificate details:

单击框中的“ Certificate项,您将看到另一个面板显示证书详细信息:

Now drag the certificate icon from there to the desktop, or any other folder you want. Literally drag and drop using the mouse.

现在,将证书图标从那里拖到桌面或您想要的任何其他文件夹。 使用鼠标从字面上拖放。

Once you do so, find the file in the Finder, and double-click it.

完成后,在Finder中找到文件,然后双击它。

You should see a prompt to install it:

您应该看到安装提示:

Where you see the Keychain: option, instead of login, choose System:

在看到Keychain:选项的地方,而不是login ,选择System

Press Add, now you should see the certificate in the System keychain, listed as localhost:

按添加,现在您应该在系统钥匙串中看到证书,列为localhost

Now double-click that, and this window should show up:

现在,双击它,然后将显示此窗口:

Click the arrow near Trust, and you should see this window, make sure you change “When using this certificate” to “Always Trust”.

单击“ 信任”附近的箭头,您应该会看到此窗口,请确保将“使用此证书时”更改为“始终信任”。

That’s it! Now close the Keychain app (cmd-Q) and try reloading your Chrome tab, it should work!

而已! 现在关闭“钥匙串”应用程序( cmd-Q ),然后尝试重新加载您的Chrome标签,它应该可以工作!

And it should now work across any browser you use.

现在,它应该可以在您使用的任何浏览器上运行。

翻译自:

转载地址:http://eamgb.baihongyu.com/

你可能感兴趣的文章
springboot + shiro学习(配置SecurityManager,Realm)
查看>>
http://desk.zol.com.cn/1600x900/
查看>>
Linux基础之命令练习Day3-文件管理:cat,tar,gzip,vim,ln
查看>>
iOS中使用nil NULL NSNULL的区别
查看>>
Hdu1754-线段树-单点更新
查看>>
在python中使用正则表达式(一)
查看>>
asp.net mvc 4.0的部署
查看>>
WordPress资源站点推荐
查看>>
Python性能鸡汤
查看>>
android Manifest.xml选项
查看>>
Cookie/Session机制具体解释
查看>>
ATMEGA16 IOport相关汇总
查看>>
有意思的cmd命令
查看>>
js正則表達式语法
查看>>
JVM-垃圾回收
查看>>
python中的多继承
查看>>
ubuntu-14.04.1-desktop上安装配置JDK1.8的环境变量
查看>>
VS2013 添加已有文件夹
查看>>
摄影扫盲
查看>>
POJ 2388 - Who's in the Middle
查看>>