latest.ipv8.attestation.wallet.irmaexact.gabi.attributes
Copyright (c), Privacy By Design Foundation All rights reserved.
This source code has been ported from https://github.com/privacybydesign/irmago The authors of this file are not -in any way- affiliated with the original authors or organizations.
Module Contents
Classes
Metadata position information. |
|
Metadata values. |
Functions
|
Covert an integer of unbounded size to bytes. |
|
Convert a short (stored in a Python int type) to bytes. |
|
cr = |
Attributes
- latest.ipv8.attestation.wallet.irmaexact.gabi.attributes.ExpiryFactor
- latest.ipv8.attestation.wallet.irmaexact.gabi.attributes.metadataLength
- class latest.ipv8.attestation.wallet.irmaexact.gabi.attributes.metadataField(length: int, offset: int)
Metadata position information.
- latest.ipv8.attestation.wallet.irmaexact.gabi.attributes.versionField
- latest.ipv8.attestation.wallet.irmaexact.gabi.attributes.signingDateField
- latest.ipv8.attestation.wallet.irmaexact.gabi.attributes.validityField
- latest.ipv8.attestation.wallet.irmaexact.gabi.attributes.keyCounterField
- latest.ipv8.attestation.wallet.irmaexact.gabi.attributes.credentialID
- latest.ipv8.attestation.wallet.irmaexact.gabi.attributes.int_to_str(n: int) bytes
Covert an integer of unbounded size to bytes.
- latest.ipv8.attestation.wallet.irmaexact.gabi.attributes.shortToByte(x: int) bytes
Convert a short (stored in a Python int type) to bytes.
- class latest.ipv8.attestation.wallet.irmaexact.gabi.attributes.MetadataAttribute(version: bytes)
Metadata values.
- setField(field: metadataField, value: bytes) None
Set a given metadata field position to a given value.
- field(field: metadataField) bytes
Retrieve the value of a given field.
- setSigningDate(timestamp: int | None = None) None
Set the date of signing in the metadata.
Note that the timestamp is a short in units of
ExpiryFactor
.
- latest.ipv8.attestation.wallet.irmaexact.gabi.attributes.make_attribute_list(cr: dict[str, Any], attribute_order: list[str] | None = None, validity_signing: tuple[int, int | None] | None = None) tuple[list[int], int]
- cr =
- {
u’attributes’: { … “name”: “value” … }, u’credential’: u’pbdf.nijmegen.address’, u’keyCounter’: 0, u’validity’: 1570123936
}.
- Parameters:
attribute_order (list) – the order in which to handle the keys