QCA::PKeyBase
Search for usage in LXR
#include <QtCrypto>
Public key implementation provider base
- Note
- This class is part of the provider plugin interface and should not be used directly by applications. You probably want PKey, PublicKey, or PrivateKey instead.
Definition at line 522 of file qcaprovider.h.
◆ PKeyBase()
Standard constructor.
- Parameters
-
p | the Provider associated with this context |
type | type of key provided by this context |
◆ bits()
virtual int QCA::PKeyBase::bits |
( |
| ) |
const |
|
pure virtual |
Returns the number of bits in the key.
◆ canExport()
virtual bool QCA::PKeyBase::canExport |
( |
| ) |
const |
|
pure virtual |
Returns true if the components of this key are accessible and whether it can be serialized into an output format.
Private keys from a smart card device will often not be exportable.
◆ convertToPublic()
virtual void QCA::PKeyBase::convertToPublic |
( |
| ) |
|
|
pure virtual |
If the key is a private key, this function will convert it into a public key (all private key data includes the public data as well, which is why this is possible).
If the key is already a public key, then this function has no effect.
◆ decrypt()
Decrypt data.
- Parameters
-
in | the input data to decrypt |
out | pointer to an array to store the plaintext result |
alg | the encryption algorithm used to generate the input data |
◆ deriveKey()
Compute a symmetric key based on this private key and some other public key.
Essentially for Diffie-Hellman only.
- Parameters
-
theirs | the other side (public key) to be used for key generation. |
◆ encrypt()
Encrypt data.
- Parameters
-
in | the input data to encrypt |
alg | the encryption algorithm to use |
◆ endSign()
Complete a signing operation, and return the signature value.
If there is an error signing, an empty array is returned.
◆ endVerify()
virtual bool QCA::PKeyBase::endVerify |
( |
const QByteArray & |
sig | ) |
|
|
virtual |
Complete a verify operation, and return true if successful.
If there is an error verifying, this function returns false.
- Parameters
-
sig | the signature to verify with the input data |
◆ finished
void QCA::PKeyBase::finished |
( |
| ) |
|
|
signal |
Emitted when an asynchronous operation completes on this key.
Such operations will be documented that they emit this signal.
◆ isNull()
virtual bool QCA::PKeyBase::isNull |
( |
| ) |
const |
|
pure virtual |
Returns true if this object is not valid.
This is the default state, and the object may also become this state if a conversion or generation function fails.
◆ isPrivate()
virtual bool QCA::PKeyBase::isPrivate |
( |
| ) |
const |
|
pure virtual |
Returns true if this is a private key, otherwise false.
◆ maximumEncryptSize()
Returns the maximum number of bytes that can be encrypted by this key.
- Parameters
-
alg | the algorithm to be used for encryption |
◆ startSign()
Begin a signing operation.
- Parameters
-
alg | the signature algorithm to use |
format | the signature format to use |
◆ startVerify()
Begin a verify operation.
- Parameters
-
alg | the signature algorithm used by the input signature |
format | the signature format used by the input signature |
◆ type()
Returns the type of public key.
◆ update()
virtual void QCA::PKeyBase::update |
( |
const MemoryRegion & |
in | ) |
|
|
virtual |
Process the plaintext input data for either signing or verifying, whichever operation is active.
- Parameters
-
in | the input data to process |
The documentation for this class was generated from the following file:
This file is part of the KDE documentation.
Documentation copyright © 1996-2023 The KDE developers.
Generated on Sat Dec 9 2023 03:47:45 by
doxygen 1.8.17 written
by
Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.