Skip to content

Commit

Permalink
Fix #1027: Invalid BC version in deployment descriptor
Browse files Browse the repository at this point in the history
  • Loading branch information
banterCZ committed Sep 8, 2023
1 parent 53b24ed commit 7928c4a
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
16 changes: 8 additions & 8 deletions docs/Installing-Bouncy-Castle.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ Java 11 no longer provides a library extension mechanism and thus Bouncy Castle

#### Bouncy Castle on Tomcat

Copy [`bcprov-jdk18on-172.jar`](https://mvnrepository.com/artifact/org.bouncycastle/bcprov-jdk18on) to your `${CATALINA_HOME}/lib` folder.
Copy [`bcprov-jdk18on-176.jar`](https://mvnrepository.com/artifact/org.bouncycastle/bcprov-jdk18on) to your `${CATALINA_HOME}/lib` folder.

<!-- begin box warning -->
Bouncy Castle library will not work properly in case any war file deployed to Tomcat contains another copy of the Bouncy Castle library, even if the war file is not related to PowerAuth.
Expand All @@ -28,7 +28,7 @@ Bouncy Castle library must be only present in the `${CATALINA_HOME}/lib` folder.

#### Bouncy Castle on JBoss / Wildfly

PowerAuth server requires a specific version of Bouncy Castle library: `bcprov-jdk18on-172.jar`
PowerAuth server requires a specific version of Bouncy Castle library: `bcprov-jdk18on-176.jar`

In order to make PowerAuth Server work on JBoss / Wildfly, you need to add and enable the external Bouncy Castle module on the server
by adding the `<global-modules>` element in the `standalone.xml` file:
Expand All @@ -46,12 +46,12 @@ The module should be defined using a new module XML file in JBoss folder `module
<?xml version="1.0" encoding="UTF-8"?>
<module name="org.bouncycastle.external" xmlns="urn:jboss:module:1.8">
<resources>
<resource-root path="bcprov-jdk18on-172.jar"/>
<resource-root path="bcprov-jdk18on-176.jar"/>
</resources>
</module>
```

Finally, copy the Bouncy Castle library `bcprov-jdk18on-172.jar` into folder `modules/system/layers/base/org/bouncycastle/external/main` so that it is available for the module.
Finally, copy the Bouncy Castle library `bcprov-jdk18on-176.jar` into folder `modules/system/layers/base/org/bouncycastle/external/main` so that it is available for the module.

<!-- begin box warning -->
Do not reuse Bouncy Castle module `org.bouncycastle` from JBoss, because version of library provided by JBoss may differ from version required by PowerAuth.
Expand Down Expand Up @@ -82,7 +82,7 @@ Java 8 provides a library extension mechanism which can be used to installed Bou

##### Standalone Tomcat

When running a standalone Tomcat instance, all you need to do is to copy [`bcprov-jdk18on-172.jar`](https://mvnrepository.com/artifact/org.bouncycastle/bcprov-jdk18on) to your `${JDK_HOME}/jre/lib/ext` folder.
When running a standalone Tomcat instance, all you need to do is to copy [`bcprov-jdk18on-176.jar`](https://mvnrepository.com/artifact/org.bouncycastle/bcprov-jdk18on) to your `${JDK_HOME}/jre/lib/ext` folder.

##### Embedded Tomcat

Expand All @@ -96,7 +96,7 @@ Make sure to add the provider to the top of the list (ideally, N=2).

#### Bouncy Castle on JBoss / Wildfly

PowerAuth server requires a specific version of Bouncy Castle library: `bcprov-jdk18on-172.jar`
PowerAuth server requires a specific version of Bouncy Castle library: `bcprov-jdk18on-176.jar`

In order to make PowerAuth Server work on JBoss / Wildfly, you need to add and enable the external Bouncy Castle module on the server
by adding the `<global-modules>` element in the `standalone.xml` file:
Expand All @@ -114,12 +114,12 @@ The module should be defined using a new module XML file in JBoss folder `module
<?xml version="1.0" encoding="UTF-8"?>
<module name="org.bouncycastle.external" xmlns="urn:jboss:module:1.8">
<resources>
<resource-root path="bcprov-jdk18on-172.jar"/>
<resource-root path="bcprov-jdk18on-176.jar"/>
</resources>
</module>
```

Finally, copy the Bouncy Castle library `bcprov-jdk18on-172.jar` into folder `modules/system/layers/base/org/bouncycastle/external/main` so that it is available for the module.
Finally, copy the Bouncy Castle library `bcprov-jdk18on-176.jar` into folder `modules/system/layers/base/org/bouncycastle/external/main` so that it is available for the module.

<!-- begin box warning -->
Do not reuse Bouncy Castle module `org.bouncycastle` from JBoss, because version of library provided by JBoss may differ from version required by PowerAuth.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

<resources>
<!-- use WAR provided Bouncy Castle -->
<resource-root path="WEB-INF/lib/bcprov-jdk18on-1.72.jar" use-physical-code-source="true"/>
<resource-root path="WEB-INF/lib/bcprov-jdk18on-1.76.jar" use-physical-code-source="true"/>
</resources>

<dependencies>
Expand Down

0 comments on commit 7928c4a

Please sign in to comment.