Key Exchange

PaymentChannel


cfxdb.xbrmm.PaymentChannel

alias of Channel

class cfxdb.xbrmm.PaymentChannels(slot=None, compress=None, build=None, cast=None)[source]

Bases: MapUuidFlatBuffers

XBR payment channels by channel_oid.

Map zlmdb.MapUuidFlatBuffers from channel_oid to cfxdb.xbr.Channel

class cfxdb.xbrmm.IndexPaymentChannelByDelegate(slot=None, compress=None)[source]

Bases: MapBytes20TimestampUuid

Index: (delegate_adr, created_timestamp) -> channel_oid

cfxdb.xbrmm.PaymentChannelBalance

alias of ChannelBalance

class cfxdb.xbrmm.PaymentChannelBalances(slot=None, compress=None, build=None, cast=None)[source]

Bases: MapUuidFlatBuffers

XBR payment channels current balances by channel_oid.

Map zlmdb.MapBytes20FlatBuffers from channel_oid to cfxdb.xbr.Balance

Offer


class cfxdb.xbrmm.Offer(from_fbs=None)[source]

Data encryption key offerings by XBR providers.

marshal() dict[source]
property timestamp: datetime64

Offer transaction time (epoch time in ns)

property offer: UUID

ID of the data encryption key offer.

property seller: bytes

Address of the XBR provider offering the data encryption key.

property seller_session_id: int

WAMP session ID of the caller that originally placed this offer.

property seller_authid: str

WAMP session authid of the caller that originally placed this offer.

property key: UUID

ID of the data encryption key offered.

property api: UUID

ID of the API the encrypted data (this key is for) is provided under.

Returns

property uri: str

URI under which the data encrypted with the key offered is provided under.

property valid_from: datetime64

Timestamp from which the offer is valid (epoch time in ns).

property signature: bytes

Seller delegate signature for the offer. The signature covers all information of the original offer placement request and requestor.

property price: int

Price of data encryption key in XBR tokens.

property categories: dict

Dictionary of optional user defined categories the specific data that is provided falls under.

property expires: datetime64

Optional data at which this offer expires (epoch time in ns).

property copies: int

Optional maximum number of times this data encryption key is to be sold or 0 for unlimited.

property remaining: int

Remaining number of copies to be sold (if “copies” is set >0, otherwise 0).

static cast(buf)[source]
build(builder)[source]
class cfxdb.xbrmm.Offers(slot=None, compress=None, build=None, cast=None)[source]

Bases: MapUuidFlatBuffers

Persisted data encryption key offers.

Map zlmdb.MapBytes32FlatBuffers from offer_id to cfxdb.xbr.Offer

class cfxdb.xbrmm.IndexOfferByKey(slot=None, compress=None)[source]

Bases: MapUuidUuid

Index: key_id -> offer_id