【问题标题】:How to implement Burp suite's custom SSL Certificate?如何实现 Burp 套件的自定义 SSL 证书?
【发布时间】:2020-07-03 05:51:25
【问题描述】:

在 Burp Suite 中,我们可以从 Project Options -> SSL 导入带有特定主机名密码的 PKCS#12 文件。

我尝试使用以下命令手动导出块和密钥文件,然后使用 tls.LoadX509KeyPair() 将它们传递给我在 golang 中的 http 客户端。但是在发送任何请求时,我都会收到remote error: tls: handshake failure

这些是我使用的命令:

openssl pkcs12 -in cert.p12 -clcerts -nokeys -out usercert.pem
openssl pkcs12 -in cert.p12 -nocerts -out userkey.pem -nodes

我错过了什么?

【问题讨论】:

    标签: go ssl certificate pkcs#12


    【解决方案1】:

    如果使用自签名证书,请在 tls 配置中指定 InsecureSkipVerify: true。拉自documentation

       // InsecureSkipVerify controls whether a client verifies the
       // server's certificate chain and host name.
       // If InsecureSkipVerify is true, TLS accepts any certificate
       // presented by the server and any host name in that certificate.
       // In this mode, TLS is susceptible to man-in-the-middle attacks.
       // This should be used only for testing.```
    

    否则,请将您的证书添加到 tls 配置中的证书列表中。

    【讨论】:

    • 我确实使用InsecureSkipVerify: true 并将证书添加到 tls 配置中。奇怪的是,当我使用 curl 库时它可以工作,但它不适用于 golang。
    猜你喜欢
    • 2019-07-21
    • 2021-10-11
    • 1970-01-01
    • 2019-03-26
    • 2021-12-20
    • 2020-09-14
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多