Gcr.Pkcs11Certificate¶
- Subclasses:
None
Methods¶
- Inherited:
- Structs:
class |
|
class |
|
class |
|
class |
|
class |
|
class |
|
Virtual Methods¶
- Inherited:
Properties¶
- Inherited:
Name |
Type |
Flags |
Short Description |
---|---|---|---|
r/w/co |
The data displayed in the renderer |
Signals¶
- Inherited:
Fields¶
- Inherited:
Name |
Type |
Access |
Description |
---|---|---|---|
parent |
r |
Class Details¶
- class Gcr.Pkcs11Certificate(**kwargs)¶
- Bases:
- Abstract:
No
- Structure:
A certificate loaded from a PKCS#11 storage. It is also a valid [class`Gck`.Object] and can be used as such.
Use [func`Gcr`.Pkcs11Certificate.lookup_issuer] to lookup the issuer of a given certificate in the PKCS#11 store.
Various common PKCS#11 certificate attributes are automatically loaded and are available via [method`Gcr`.Pkcs11Certificate.get_attributes].
- classmethod lookup_issuer(certificate, cancellable)[source]¶
- Parameters:
certificate (
Gcr.Certificate
) – aGcr.Certificate
cancellable (
Gio.Cancellable
orNone
) – a cancellable
- Raises:
- Returns:
a new
Gcr.Pkcs11Certificate
, orNone
- Return type:
Lookup a the issuer of a certificate in the PKCS#11 storage. The lookup is done using the issuer DN of the certificate. No certificate chain verification is done. Use a crypto library to make trust decisions.
This call may block, see [func`Gcr`.Pkcs11Certificate.lookup_issuer] for the non-blocking version.
Will return
None
if no issuer certificate is found. Use error to determine if an error occurred.
- classmethod lookup_issuer_async(certificate, cancellable, callback, *user_data)[source]¶
- Parameters:
certificate (
Gcr.Certificate
) – aGcr.Certificate
cancellable (
Gio.Cancellable
orNone
) – a cancellablecallback (
Gio.AsyncReadyCallback
orNone
) – aGio.AsyncReadyCallback
to call when the operation completesuser_data (
object
orNone
) – the data to pass to callback function
Lookup a the issuer of a certificate in the PKCS#11 storage. The lookup is done using the issuer DN of the certificate. No certificate chain verification is done. Use a crypto library to make trust decisions.
When the operation is finished, callback will be called. You can then call [func`Gcr`.Pkcs11Certificate.lookup_issuer_finish] to get the result of the operation.
- classmethod lookup_issuer_finish(result)[source]¶
- Parameters:
result (
Gio.AsyncResult
) – theGio.AsyncResult
passed to the callback- Raises:
- Returns:
a new
Gcr.Pkcs11Certificate
, orNone
- Return type:
Finishes an asynchronous operation started by [func`Gcr`.Pkcs11Certificate.lookup_issuer_async].
Will return
None
if no issuer certificate is found. Use error to determine if an error occurred.
- classmethod new_from_uri(pkcs11_uri, cancellable)[source]¶
- Parameters:
pkcs11_uri (
str
) – a A PKCS \#11 URIcancellable (
Gio.Cancellable
orNone
) – aGio.Cancellable
- Raises:
- Returns:
a new
Gcr.Certificate
, orNone
- Return type:
Lookup a certificate in the PKCS#11 storage by the given URI.
This call may block, see
Gcr.Pkcs11Certificate.new_from_uri_async
() for the non-blocking version.Will return
None
if no certificate is found. Use error to determine if an error occurred.
- classmethod new_from_uri_async(pkcs11_uri, cancellable, callback, *user_data)[source]¶
- Parameters:
pkcs11_uri (
str
) – a A PKCS \#11 URIcancellable (
Gio.Cancellable
orNone
) – aGio.Cancellable
callback (
Gio.AsyncReadyCallback
orNone
) – aGio.AsyncReadyCallback
to call when the operation completesuser_data (
object
orNone
) – the data to pass to callback function
Lookup a certificate in the PKCS#11 storage by the given URI.
When the operation is finished, callback will be called. You can then call
Gcr.Pkcs11Certificate.new_from_uri_finish
() to get the result of the operation.
- classmethod new_from_uri_finish(result)[source]¶
- Parameters:
result (
Gio.AsyncResult
) – theGio.AsyncResult
passed to the callback- Raises:
- Returns:
a new
Gcr.Certificate
, orNone
- Return type:
Finishes an asynchronous operation started by
Gcr.Pkcs11Certificate.new_from_uri_async
().Will return
None
if no certificate is found. Use error to determine if an error occurred.
Property Details¶
- Gcr.Pkcs11Certificate.props.attributes¶
- Name:
attributes
- Type:
- Default Value:
- Flags:
Automatically loaded attributes for this certificate.