简体   繁体   English

如何在 PostgreSQL 9.4 中配置 SSL 证书?

[英]How to configure SSL certificate into PostgreSQL 9.4?

I'm using Adempiere 360 ERP solution with Java language, Database PostgreSQL 9.4 and iReport (For reporting) and using CentOS 7 Server.我正在使用带有 Java 语言、数据库 PostgreSQL 9.4 和 iReport(用于报告)并使用 CentOS 7 服务器的 Adempiere 360​​ ERP 解决方案。 Recently Vendor provide me 4 files about ssl configuration.最近供应商为我提供了 4 个关于 ssl 配置的文件。 But i fail to configure ssl into PostgreSQL 9.4.但是我无法将 ssl 配置到 PostgreSQL 9.4 中。 I follow some instruction from google but finally fail.我遵循了谷歌的一些指示,但最终失败了。 Need proper direction.需要正确的方向。

What steps are you following?您正在遵循哪些步骤?

You have to copy your signed certificate and private key to the required locations on the database server.您必须将签名证书和私钥复制到数据库服务器上的所需位置。

Then you just have to edit postgresql.conf然后你只需要编辑postgresql.conf

ssl=on

In the pg_hba.conf change the host option to hostsslpg_hba.conf 中,将主机选项更改为 hostssl

hostssl mydb mydbuser 192.168.122.0/24 md5

Then restart your server.然后重启你的服务器。

Read this tutorial 阅读本教程

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM