diff options
author | Dominik Schürmann <dominik@dominikschuermann.de> | 2014-04-16 19:40:36 +0200 |
---|---|---|
committer | Dominik Schürmann <dominik@dominikschuermann.de> | 2014-04-16 19:40:36 +0200 |
commit | b0c65729a98dfbd61063491a5facff2f782f56af (patch) | |
tree | a5f6756144051f9d8f804d549276bddde98106c0 /libraries | |
parent | 676262b052b12f1d72162acb9bf435a8630644a0 (diff) | |
parent | 8b4700d5218ce19ca5b51daecda55f2ab4489e17 (diff) | |
download | open-keychain-b0c65729a98dfbd61063491a5facff2f782f56af.tar.gz open-keychain-b0c65729a98dfbd61063491a5facff2f782f56af.tar.bz2 open-keychain-b0c65729a98dfbd61063491a5facff2f782f56af.zip |
Merge pull request #576 from Valodim/stripped-secretkeys
Support stripped secretkeys
Diffstat (limited to 'libraries')
-rw-r--r-- | libraries/spongycastle/pg/src/main/j2me/org/spongycastle/openpgp/PGPSecretKey.java | 11 | ||||
-rw-r--r-- | libraries/spongycastle/pg/src/main/java/org/spongycastle/openpgp/PGPSecretKey.java | 11 |
2 files changed, 20 insertions, 2 deletions
diff --git a/libraries/spongycastle/pg/src/main/j2me/org/spongycastle/openpgp/PGPSecretKey.java b/libraries/spongycastle/pg/src/main/j2me/org/spongycastle/openpgp/PGPSecretKey.java index 2554be8f1..8552f6fca 100644 --- a/libraries/spongycastle/pg/src/main/j2me/org/spongycastle/openpgp/PGPSecretKey.java +++ b/libraries/spongycastle/pg/src/main/j2me/org/spongycastle/openpgp/PGPSecretKey.java @@ -278,7 +278,16 @@ public class PGPSecretKey { return pub.getUserIDs(); } - + + /** + * Return the S2K object used to encrypt this secret key. + * + * @return this secret key's s2k object' + */ + public S2K getS2K() { + return secret.getS2K(); + } + /** * Return any user attribute vectors associated with the key. * diff --git a/libraries/spongycastle/pg/src/main/java/org/spongycastle/openpgp/PGPSecretKey.java b/libraries/spongycastle/pg/src/main/java/org/spongycastle/openpgp/PGPSecretKey.java index c0f7dfa3b..f7e3a50c7 100644 --- a/libraries/spongycastle/pg/src/main/java/org/spongycastle/openpgp/PGPSecretKey.java +++ b/libraries/spongycastle/pg/src/main/java/org/spongycastle/openpgp/PGPSecretKey.java @@ -431,7 +431,16 @@ public class PGPSecretKey { return pub.getUserIDs(); } - + + /** + * Return the S2K this secret key is encrypted with. + * + * @return the S2K for this key. + */ + public S2K getS2K() { + return secret.getS2K(); + } + /** * Return any user attribute vectors associated with the key. * |