Skip to content
This repository was archived by the owner on Oct 6, 2025. It is now read-only.

Commit b418190

Browse files
committed
added missing cause exception to thrown RuntimeException
1 parent 1bdb200 commit b418190

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

  • codex-process-data-transfer/src/main/java/de/netzwerk_universitaetsmedizin/codex/processes/data_transfer/crypto

codex-process-data-transfer/src/main/java/de/netzwerk_universitaetsmedizin/codex/processes/data_transfer/crypto/CrrKeyProviderImpl.java

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ public static CrrKeyProviderImpl fromFiles(String crrPrivateKeyFile, String crrP
5858
}
5959
catch (NoSuchAlgorithmException | InvalidKeySpecException | IOException e)
6060
{
61-
throw new RuntimeException("Error while reading CRR private-key from " + crrPrivateKeyFile);
61+
throw new RuntimeException("Error while reading CRR private-key from " + crrPrivateKeyFile, e);
6262
}
6363

6464
try
@@ -69,19 +69,17 @@ public static CrrKeyProviderImpl fromFiles(String crrPrivateKeyFile, String crrP
6969
if (!Files.isReadable(crrPublicKeyPath))
7070
throw new RuntimeException("CRR public-key at " + crrPublicKeyFile + " not readable");
7171

72-
7372
crrPublicKey = PemIo.readPublicKeyFromPem(crrPublicKeyPath);
7473
}
7574
}
7675
catch (NoSuchAlgorithmException | InvalidKeySpecException | IOException e)
7776
{
78-
throw new RuntimeException("Error while reading CRR public-key from " + crrPublicKeyFile);
77+
throw new RuntimeException("Error while reading CRR public-key from " + crrPublicKeyFile, e);
7978
}
8079

8180
return new CrrKeyProviderImpl(crrPrivateKey, crrPublicKey);
8281
}
8382

84-
8583
private final PrivateKey crrPrivateKey;
8684
private final PublicKey crrPublicKey;
8785

0 commit comments

Comments
 (0)