You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pdfbox.apache.org by le...@apache.org on 2023/10/05 06:27:28 UTC
svn commit: r1912742 - in /pdfbox/branches/3.0: app/ debugger-app/ debugger/ examples/ parent/ pdfbox/ pdfbox/src/main/java/org/apache/pdfbox/pdmodel/encryption/ preflight-app/ preflight/ tools/
Author: lehmi
Date: Thu Oct 5 06:27:27 2023
New Revision: 1912742
URL: http://svn.apache.org/viewvc?rev=1912742&view=rev
Log:
PDFBOX-5693: remove unused bcmail dependency, replace Class.forName call
Modified:
pdfbox/branches/3.0/app/pom.xml
pdfbox/branches/3.0/debugger-app/pom.xml
pdfbox/branches/3.0/debugger/pom.xml
pdfbox/branches/3.0/examples/pom.xml
pdfbox/branches/3.0/parent/pom.xml
pdfbox/branches/3.0/pdfbox/pom.xml
pdfbox/branches/3.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/encryption/SecurityProvider.java
pdfbox/branches/3.0/preflight-app/pom.xml
pdfbox/branches/3.0/preflight/pom.xml
pdfbox/branches/3.0/tools/pom.xml
Modified: pdfbox/branches/3.0/app/pom.xml
URL: http://svn.apache.org/viewvc/pdfbox/branches/3.0/app/pom.xml?rev=1912742&r1=1912741&r2=1912742&view=diff
==============================================================================
--- pdfbox/branches/3.0/app/pom.xml (original)
+++ pdfbox/branches/3.0/app/pom.xml Thu Oct 5 06:27:27 2023
@@ -41,7 +41,7 @@
</dependency>
<dependency>
<groupId>org.bouncycastle</groupId>
- <artifactId>bcmail-jdk18on</artifactId>
+ <artifactId>bcpkix-jdk18on</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
Modified: pdfbox/branches/3.0/debugger-app/pom.xml
URL: http://svn.apache.org/viewvc/pdfbox/branches/3.0/debugger-app/pom.xml?rev=1912742&r1=1912741&r2=1912742&view=diff
==============================================================================
--- pdfbox/branches/3.0/debugger-app/pom.xml (original)
+++ pdfbox/branches/3.0/debugger-app/pom.xml Thu Oct 5 06:27:27 2023
@@ -41,7 +41,7 @@
</dependency>
<dependency>
<groupId>org.bouncycastle</groupId>
- <artifactId>bcmail-jdk18on</artifactId>
+ <artifactId>bcpkix-jdk18on</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
Modified: pdfbox/branches/3.0/debugger/pom.xml
URL: http://svn.apache.org/viewvc/pdfbox/branches/3.0/debugger/pom.xml?rev=1912742&r1=1912741&r2=1912742&view=diff
==============================================================================
--- pdfbox/branches/3.0/debugger/pom.xml (original)
+++ pdfbox/branches/3.0/debugger/pom.xml Thu Oct 5 06:27:27 2023
@@ -39,11 +39,6 @@
<dependencies>
<dependency>
- <groupId>org.bouncycastle</groupId>
- <artifactId>bcmail-jdk18on</artifactId>
- <optional>true</optional>
- </dependency>
- <dependency>
<groupId>${project.groupId}</groupId>
<artifactId>pdfbox</artifactId>
<version>${project.version}</version>
Modified: pdfbox/branches/3.0/examples/pom.xml
URL: http://svn.apache.org/viewvc/pdfbox/branches/3.0/examples/pom.xml?rev=1912742&r1=1912741&r2=1912742&view=diff
==============================================================================
--- pdfbox/branches/3.0/examples/pom.xml (original)
+++ pdfbox/branches/3.0/examples/pom.xml Thu Oct 5 06:27:27 2023
@@ -45,8 +45,11 @@
<dependencies>
<dependency>
<groupId>org.bouncycastle</groupId>
- <artifactId>bcmail-jdk18on</artifactId>
- <optional>true</optional>
+ <artifactId>bcprov-jdk18on</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.bouncycastle</groupId>
+ <artifactId>bcpkix-jdk18on</artifactId>
</dependency>
<dependency>
<groupId>${project.groupId}</groupId>
Modified: pdfbox/branches/3.0/parent/pom.xml
URL: http://svn.apache.org/viewvc/pdfbox/branches/3.0/parent/pom.xml?rev=1912742&r1=1912741&r2=1912742&view=diff
==============================================================================
--- pdfbox/branches/3.0/parent/pom.xml (original)
+++ pdfbox/branches/3.0/parent/pom.xml Thu Oct 5 06:27:27 2023
@@ -85,11 +85,6 @@
</dependency>
<dependency>
<groupId>org.bouncycastle</groupId>
- <artifactId>bcmail-jdk18on</artifactId>
- <version>${bouncycastle.version}</version>
- </dependency>
- <dependency>
- <groupId>org.bouncycastle</groupId>
<artifactId>bcpkix-jdk18on</artifactId>
<version>${bouncycastle.version}</version>
</dependency>
Modified: pdfbox/branches/3.0/pdfbox/pom.xml
URL: http://svn.apache.org/viewvc/pdfbox/branches/3.0/pdfbox/pom.xml?rev=1912742&r1=1912741&r2=1912742&view=diff
==============================================================================
--- pdfbox/branches/3.0/pdfbox/pom.xml (original)
+++ pdfbox/branches/3.0/pdfbox/pom.xml Thu Oct 5 06:27:27 2023
@@ -57,12 +57,14 @@
</dependency>
<dependency>
<groupId>org.bouncycastle</groupId>
- <artifactId>bcmail-jdk18on</artifactId>
+ <artifactId>bcprov-jdk18on</artifactId>
+ <scope>compile</scope>
<optional>true</optional>
</dependency>
<dependency>
<groupId>org.bouncycastle</groupId>
- <artifactId>bcprov-jdk18on</artifactId>
+ <artifactId>bcpkix-jdk18on</artifactId>
+ <scope>compile</scope>
<optional>true</optional>
</dependency>
<dependency>
Modified: pdfbox/branches/3.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/encryption/SecurityProvider.java
URL: http://svn.apache.org/viewvc/pdfbox/branches/3.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/encryption/SecurityProvider.java?rev=1912742&r1=1912741&r2=1912742&view=diff
==============================================================================
--- pdfbox/branches/3.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/encryption/SecurityProvider.java (original)
+++ pdfbox/branches/3.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/encryption/SecurityProvider.java Thu Oct 5 06:27:27 2023
@@ -17,9 +17,10 @@
package org.apache.pdfbox.pdmodel.encryption;
import java.io.IOException;
-import java.lang.reflect.InvocationTargetException;
import java.security.Provider;
+import org.bouncycastle.jce.provider.BouncyCastleProvider;
+
/**
* Singleton which provides a security provider.
*
@@ -44,18 +45,7 @@ public class SecurityProvider
// TODO synchronize access
if (provider == null)
{
- try
- {
- Class<Provider> providerClass = (Class<Provider>) Class
- .forName("org.bouncycastle.jce.provider.BouncyCastleProvider");
- provider = providerClass.getDeclaredConstructor().newInstance();
- }
- catch (ClassNotFoundException | InstantiationException | IllegalAccessException |
- NoSuchMethodException | SecurityException | IllegalArgumentException |
- InvocationTargetException ex)
- {
- throw new IOException(ex);
- }
+ provider = new BouncyCastleProvider();
}
return provider;
}
Modified: pdfbox/branches/3.0/preflight-app/pom.xml
URL: http://svn.apache.org/viewvc/pdfbox/branches/3.0/preflight-app/pom.xml?rev=1912742&r1=1912741&r2=1912742&view=diff
==============================================================================
Binary files - no diff available.
Modified: pdfbox/branches/3.0/preflight/pom.xml
URL: http://svn.apache.org/viewvc/pdfbox/branches/3.0/preflight/pom.xml?rev=1912742&r1=1912741&r2=1912742&view=diff
==============================================================================
--- pdfbox/branches/3.0/preflight/pom.xml (original)
+++ pdfbox/branches/3.0/preflight/pom.xml Thu Oct 5 06:27:27 2023
@@ -164,21 +164,11 @@
<!-- TODO find a suitable place to store the isator test pdfs <dependency>
<groupId>org.pdfa</groupId> <artifactId>isartor</artifactId> <version>1.0-20080813</version>
<scope>test</scope> </dependency> -->
- <dependency>
- <groupId>org.bouncycastle</groupId>
- <artifactId>bcmail-jdk18on</artifactId>
- <optional>true</optional>
- </dependency>
- <dependency>
- <groupId>org.bouncycastle</groupId>
- <artifactId>bcprov-jdk18on</artifactId>
- <optional>true</optional>
- </dependency>
- <dependency>
- <groupId>org.apache.pdfbox</groupId>
- <artifactId>jbig2-imageio</artifactId>
- <scope>test</scope>
- </dependency>
+ <dependency>
+ <groupId>org.apache.pdfbox</groupId>
+ <artifactId>jbig2-imageio</artifactId>
+ <scope>test</scope>
+ </dependency>
</dependencies>
Modified: pdfbox/branches/3.0/tools/pom.xml
URL: http://svn.apache.org/viewvc/pdfbox/branches/3.0/tools/pom.xml?rev=1912742&r1=1912741&r2=1912742&view=diff
==============================================================================
--- pdfbox/branches/3.0/tools/pom.xml (original)
+++ pdfbox/branches/3.0/tools/pom.xml Thu Oct 5 06:27:27 2023
@@ -39,11 +39,6 @@
<dependencies>
<dependency>
- <groupId>org.bouncycastle</groupId>
- <artifactId>bcmail-jdk18on</artifactId>
- <optional>true</optional>
- </dependency>
- <dependency>
<groupId>${project.groupId}</groupId>
<artifactId>pdfbox-debugger</artifactId>
<version>${project.version}</version>