# 配置与 Talend Dictionary Service 的 HTTPS 连接

保护 Talend Data Preparation 和 Talend Dictionary Service 之间的连接需要编辑它们的对应配置文件。

您首先需要将 Talend Dictionary Service 配置为 HTTPS 中的服务。然后，您将在运行于 HTTPS 中的 Talend Data Preparation 和 Talend Dictionary Service 之间启用 SSL 通信。

## 开始之前

* Talend Data Preparation 已配置为 HTTPS 中的服务。有关更多信息，请参阅[为 Talend Data Preparation 配置 HTTPS 连接](https://help.qlik.com/talend/en-US/installation-guide-linux/7.3/configuring-https-connection-for-talend-data-preparation)。
* Talend Dictionary Service 已配置为 HTTPS 中的服务。有关更多信息，请参阅[保护 Talend Dictionary Service 的连接](https://help.qlik.com/talend/en-US/installation-guide-linux/7.3/securing-connections-for-talend-dictionary-service)。
* 您已为 Talend Data Preparation 和 Talend Dictionary Service 生成证书，并将其添加到 Web 浏览器信任库。

## 步骤

1. 要在运行于 HTTPS 中的 Talend Data Preparation 和 Talend Dictionary Service 之间启用 SSL 通信，请获取 Talend Dictionary Service 证书或其证书颁发机构，并使用以下命令将其添加到 Talend Data Preparation 信任库：

   keytool -import -trustcacerts -alias &lt;cert-alias&gt; -file &lt;dictionary-service\_certificate.crt&gt; -keystore &lt;truststore.jks&gt;
2. 在 &lt;Data\_Preparation\_Path&gt;/config/application.properties 文件中，添加以下属性以设置信任库：
   ```
   tls.trust-store=/path/to/<truststore.jks>
   tls.trust-store-password=<trust-store_password>

   false to disable hostname verification
   tls.verify-hostname=true
   ```
3. 重新启动服务。

## 结果

运行于 HTTPS 中的 Talend Data Preparation 实例现在可以与同样使用安全 HTTPS 连接运行的 Talend Dictionary Service 通信了。