阿帕奇堡垒 TLS
Apache Fortress TLS
我是 ldap enviromnet 的新手,我正在尝试使用 symas openldap (https://github.com/apache/directory-fortress-core/blob/master/README-QUICKSTART-SLAPD.md)
设置 apache 堡垒
当我使用 ldap 设置时,所有集成测试都成功通过,但是当我设置 ldaps 时它抛出握手错误。
有人知道我必须设置所有客户端和服务器证书吗,因为设置为存储库 README,这是不可能的。
固定:
根据该项目创建者的以下回答,我正确设置了 LDAPS。
下一题:
但是现在我在 运行 Apache Fortress Rest 设置的第 3 步时出现错误:
mvn clean install -Dload.file=./src/main/resources/FortressRestServerPolicy.xml tomcat:deploy
错误输出:
[ERROR] Failed to execute goal org.codehaus.mojo:tomcat-maven-plugin:1.0-beta-1:deploy (default-cli) on project fortress-rest: Cannot invoke Tomcat manager: Error writing to server -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.codehaus.mojo:tomcat-maven-plugin:1.0-beta-1:deploy (default-cli) on project fortress-rest: Cannot invoke Tomcat manager
Caused by: org.apache.maven.plugin.MojoExecutionException: Cannot invoke Tomcat manager
Caused by: java.io.IOException: Error writing to server
我在 tomcat 中设置了角色和用户 manager-gui(我可以通过 http 和 https 访问,hostname/manager/html)和经理脚本
在 pom.xml 中更改 tomcat maven 插件,我可以部署:
<groupId>org.apache.tomcat.maven</groupId>
<artifactId>tomcat7-maven-plugin</artifactId>
<version>2.2</version>
但是在我收到那个错误之后...
FAIL - Deployed application at context path [/fortress-rest] but context failed to start
有什么想法吗?
使用 TLS 或 LDAPS 连接到 LDAP 服务器不需要客户端证书。您需要为 LDAP 主机创建服务器端证书,并将其添加到 OpenLDAP 配置中。您还必须将该服务器的 CA 证书添加到客户端的 Java 信任库,即堡垒运行时。
有关如何完成此操作的教程,请查看 the Apache Fortress Demo。 (注意我是这个demo的作者。)
本教程的范围不仅仅是创建和使用证书。您感兴趣的具体步骤是:
- http://shawnmckinney.github.io/apache-fortress-demo/apidocs/doc-files/keys.html
- http://shawnmckinney.github.io/apache-fortress-demo/apidocs/doc-files/hosts.html
- http://shawnmckinney.github.io/apache-fortress-demo/apidocs/doc-files/openldap-ssl.html
- http://shawnmckinney.github.io/apache-fortress-demo/apidocs/doc-files/apache-fortress-core-ssl.html
我是 ldap enviromnet 的新手,我正在尝试使用 symas openldap (https://github.com/apache/directory-fortress-core/blob/master/README-QUICKSTART-SLAPD.md)
设置 apache 堡垒当我使用 ldap 设置时,所有集成测试都成功通过,但是当我设置 ldaps 时它抛出握手错误。
有人知道我必须设置所有客户端和服务器证书吗,因为设置为存储库 README,这是不可能的。
固定:
根据该项目创建者的以下回答,我正确设置了 LDAPS。
下一题:
但是现在我在 运行 Apache Fortress Rest 设置的第 3 步时出现错误:
mvn clean install -Dload.file=./src/main/resources/FortressRestServerPolicy.xml tomcat:deploy
错误输出:
[ERROR] Failed to execute goal org.codehaus.mojo:tomcat-maven-plugin:1.0-beta-1:deploy (default-cli) on project fortress-rest: Cannot invoke Tomcat manager: Error writing to server -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.codehaus.mojo:tomcat-maven-plugin:1.0-beta-1:deploy (default-cli) on project fortress-rest: Cannot invoke Tomcat manager
Caused by: org.apache.maven.plugin.MojoExecutionException: Cannot invoke Tomcat manager
Caused by: java.io.IOException: Error writing to server
我在 tomcat 中设置了角色和用户 manager-gui(我可以通过 http 和 https 访问,hostname/manager/html)和经理脚本
在 pom.xml 中更改 tomcat maven 插件,我可以部署:
<groupId>org.apache.tomcat.maven</groupId>
<artifactId>tomcat7-maven-plugin</artifactId>
<version>2.2</version>
但是在我收到那个错误之后...
FAIL - Deployed application at context path [/fortress-rest] but context failed to start
有什么想法吗?
使用 TLS 或 LDAPS 连接到 LDAP 服务器不需要客户端证书。您需要为 LDAP 主机创建服务器端证书,并将其添加到 OpenLDAP 配置中。您还必须将该服务器的 CA 证书添加到客户端的 Java 信任库,即堡垒运行时。
有关如何完成此操作的教程,请查看 the Apache Fortress Demo。 (注意我是这个demo的作者。)
本教程的范围不仅仅是创建和使用证书。您感兴趣的具体步骤是:
- http://shawnmckinney.github.io/apache-fortress-demo/apidocs/doc-files/keys.html
- http://shawnmckinney.github.io/apache-fortress-demo/apidocs/doc-files/hosts.html
- http://shawnmckinney.github.io/apache-fortress-demo/apidocs/doc-files/openldap-ssl.html
- http://shawnmckinney.github.io/apache-fortress-demo/apidocs/doc-files/apache-fortress-core-ssl.html