Skip to content

Commit 2018415

Browse files
committed
prevented addition of two id-oracle-pkcs12-trusted-key-usage attributes in PKCS12 files. Fix for github #1945
1 parent 2c933e0 commit 2018415

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

prov/src/main/java/org/bouncycastle/jcajce/provider/keystore/pkcs12/PKCS12KeyStoreSpi.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1943,6 +1943,11 @@ private SafeBag createSafeBag(String certId, Certificate cert, boolean overwrite
19431943
continue;
19441944
}
19451945

1946+
if (oid.equals(MiscObjectIdentifiers.id_oracle_pkcs12_trusted_key_usage))
1947+
{
1948+
continue;
1949+
}
1950+
19461951
ASN1EncodableVector fSeq = new ASN1EncodableVector();
19471952

19481953
fSeq.add(oid);

0 commit comments

Comments
 (0)