diff options
Diffstat (limited to 'tdecore/tdehw/tdecryptographiccarddevice.h')
-rw-r--r-- | tdecore/tdehw/tdecryptographiccarddevice.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tdecore/tdehw/tdecryptographiccarddevice.h b/tdecore/tdehw/tdecryptographiccarddevice.h index fd0364fd8..c9de6091b 100644 --- a/tdecore/tdehw/tdecryptographiccarddevice.h +++ b/tdecore/tdehw/tdecryptographiccarddevice.h @@ -82,6 +82,16 @@ class TDECORE_EXPORT TDECryptographicCardDevice : public TDEGenericDevice */ X509CertificatePtrList cardX509Certificates(); + /** + * Create a new random key and encrypt with the public key + * contained in the given certificate. + * @param plaintext Generated (decrypted) random key + * @param ciphertext Encrypted key + * @param certificate X509 certificate containing the public key to use + * @return 0 on success, -1 on general failure, -2 on encryption failure + */ + static int createNewSecretRSAKeyFromCertificate(TQByteArray &plaintext, TQByteArray &ciphertext, X509* certificate); + public slots: void cardStatusChanged(TQString status, TQString atr); |