diff options
| author | Fraser Tweedale <ftweedal@redhat.com> | 2016-03-30 12:38:24 +1100 |
|---|---|---|
| committer | Fraser Tweedale <ftweedal@redhat.com> | 2016-05-03 11:09:39 +1000 |
| commit | 94ee373d053b34e534fbb61826e586693a38c934 (patch) | |
| tree | 09d16ff256e1691d98136599d27a8a28cfed663c /base/util/src | |
| parent | e21aadd5e14dbcda73c20f20e67b1bcc8d5b5bfc (diff) | |
| download | pki-94ee373d053b34e534fbb61826e586693a38c934.tar.gz pki-94ee373d053b34e534fbb61826e586693a38c934.tar.xz pki-94ee373d053b34e534fbb61826e586693a38c934.zip | |
Lightweight CAs: add key retrieval framework
Add the framework for key retrieval when a lightweight CA is missing
its signing key. This includes all the bits for loading a
KeyRetriever implementation, initiating retrieval in a thread and
updating the record of which clones possess the key if retrieval was
successful.
It does not include a KeyRetriever implementation. A subsequent
commit will provide this.
Part of: https://fedorahosted.org/pki/ticket/1625
Diffstat (limited to 'base/util/src')
| -rw-r--r-- | base/util/src/netscape/security/pkcs/PKCS12Util.java | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/base/util/src/netscape/security/pkcs/PKCS12Util.java b/base/util/src/netscape/security/pkcs/PKCS12Util.java index 571ee1881..b1b0f0768 100644 --- a/base/util/src/netscape/security/pkcs/PKCS12Util.java +++ b/base/util/src/netscape/security/pkcs/PKCS12Util.java @@ -540,7 +540,10 @@ public class PKCS12Util { Path path = Paths.get(filename); byte[] b = Files.readAllBytes(path); + return loadFromByteArray(b, password); + } + public PKCS12 loadFromByteArray(byte[] b, Password password) throws Exception { ByteArrayInputStream bis = new ByteArrayInputStream(b); PFX pfx = (PFX) (new PFX.Template()).decode(bis); |
