gpt4 book ai didi

ssl - Redshift JDBC 连接 : Using SSL certificate file without putting it into truststore?

转载 作者:太空宇宙 更新时间:2023-11-03 13:02:43 24 4
gpt4 key购买 nike

我想在使用 JDBC 连接到 Redshift 时设置 SSL,并使用 Redshift 证书来验证连接。

Redshift 文档位于 http://docs.aws.amazon.com/redshift/latest/mgmt/connecting-ssl-support.html描述我需要从 https://s3.amazonaws.com/redshift-downloads/redshift-ssl-ca-cert.pem 添加 Redshift 键到信任库。

但是,我不想将证书添加到信任库中,而是直接使用证书文件。如 docs.aws.amazon.com/redshift/latest/mgmt/configure-jdbc-options.html 中所述,JDBC 具有选项 sslCert 以直接指定证书文件的路径。但是当指定sslCert时,它要求我也指定sslKey选项,据我了解这是证书的私钥。这是为什么?为什么在使用来自文件而不是来自信任库的证书时还需要拥有 key ?有没有其他方法可以设置它而不将其添加到信任库(并执行验证,所以不是 NonValidatingFactory)?

最佳答案

最后使用 sslrootcert=/path/to/certificate.pem 成功了。我的 redshift JDBC 库版本太旧,不支持该选项...

关于ssl - Redshift JDBC 连接 : Using SSL certificate file without putting it into truststore?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/41826486/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com