xbr._frealm

Classes

FederatedRealm

A federated realm is a WAMP application realm with a trust anchor rooted in Ethereum, and

Seeder

Module Contents

class FederatedRealm(name_or_address: str, gateway_config: Dict[str, Any] | None = None)[source]

Bases: object

A federated realm is a WAMP application realm with a trust anchor rooted in Ethereum, and which can be shared between multiple parties.

A federated realm is globally identified on an Ethereum chain (e.g. on Mainnet or Rinkeby) by an Ethereum address associated to a federated realm owner by an on-chain record stored in the WAMP Network contract. The federated realm address thus only needs to exist as an identifier of the federated realm-owner record.

CONTRACT_ABI: str = ''[source]
CONTRACT_ADDRESS[source]
__slots__ = ('_name_or_address', '_gateway_config', '_status', '_name_category', '_w3', '_ens', '_address',...[source]
_address: str | None = None[source]
_contract: web3.contract.Contract | None = None[source]
_ens = None[source]
_gateway_config = None[source]
_initialize_background()[source]
_name_category: str | None = None[source]
_name_or_address[source]
_root_ca = None[source]
_seeders: List[Seeder] = [][source]
_status = 'STOPPED'[source]
_w3 = None[source]
property address[source]
property gateway_config: Dict[str, Any] | None[source]
initialize()[source]
Returns:

property name_category: str | None[source]
property name_or_address: str[source]
root_ca() xbr._eip712_authority_certificate.EIP712AuthorityCertificate[source]
property seeders: List[Seeder][source]
property status: str[source]
class Seeder(frealm: FederatedRealm, operator: str | None = None, label: str | None = None, country: str | None = None, legal: str | None = None, endpoint: str | None = None, bandwidth_requested: int | None = None, bandwidth_offered: int | None = None)[source]

Bases: object

__slots__ = ('_frealm', '_operator', '_label', '_country', '_legal', '_endpoint', '_bandwidth_requested',...[source]
_bandwidth_offered: str | None = None[source]
_bandwidth_requested: str | None = None[source]
_country: str | None = None[source]
static _create_eip712_connect(chain_id: int, verifying_contract: bytes, channel_binding: str, channel_id: bytes, block_no: int, challenge: bytes, pubkey: bytes, realm: bytes, delegate: bytes, seeder: bytes, bandwidth: int)[source]
_endpoint: str | None = None[source]
_frealm: FederatedRealm[source]
_label: str | None = None[source]
_operator: str | None = None[source]
property bandwidth_offered: int | None[source]

return:

property bandwidth_requested: int | None[source]

return:

property country: str | None[source]

Operator country (ISO 3166-1 alpha-2), e.g. "US".

Returns:

ISO 3166-1 alpha-2 country code.

create_authextra(client_key: autobahn.wamp.interfaces.ICryptosignKey, delegate_key: autobahn.wamp.interfaces.IEthereumKey, bandwidth_requested: int, channel_id: bytes | None = None, channel_binding: str | None = None) twisted.internet.defer.Deferred[source]
Parameters:
  • client_key

  • delegate_key

  • bandwidth_requested

  • channel_id

  • channel_binding

Returns:

property endpoint: str | None[source]

Public WAMP endpoint of seeder. Secure WebSocket URL resolving to a public IPv4 or IPv6 listening url accepting incoming WAMP-WebSocket connections, e.g. wss://service1.example.com/ws.

Returns:

The endpoint URL.

property frealm: FederatedRealm[source]

return:

property label: str | None[source]

Operator endpoint label.

Returns:

A human readable label for the operator or specific operator endpoint.

property legal: str | None[source]

return:

property operator: str | None[source]

Operator address, e.g. "0xe59C7418403CF1D973485B36660728a5f4A8fF9c".

Returns:

The Ethereum address of the endpoint operator.