libp2p/routing_record

    Dark Mode
Search:
Group by:
  Source   Edit

This module implements Routing Records.Functions related to signed peer records

Types

AddressInfo = object
  address*: MultiAddress
  Source   Edit
PeerRecord = object
  peerId*: PeerId
  seqNo*: uint64
  addresses*: seq[AddressInfo]
  Source   Edit

Procs

proc checkValid(spr: SignedPeerRecord): Result[void, EnvelopeError] {.
    ...raises: [], tags: [RootEffect].}
  Source   Edit
proc decode(T: typedesc[PeerRecord]; buffer: seq[byte]): Result[PeerRecord,
    ProtoError] {....raises: [].}
  Source   Edit
proc encode(record: PeerRecord): seq[byte] {....raises: [], tags: [].}
  Source   Edit
proc init(T: typedesc[PeerRecord]; peerId: PeerId; addresses: seq[MultiAddress];
          seqNo = toUnix(getTime()).uint64): T:type {....raises: [].}
  Source   Edit
proc payloadDomain(T: typedesc[PeerRecord]): string {....raises: [].}
  Source   Edit
proc payloadType(T: typedesc[PeerRecord]): seq[byte] {....raises: [].}
  Source   Edit

Exports

formatItIMPL, hash, init, getField, shortLog, >=, getBytes, shortLog, write, $, init, public, shortLog, PeerId, ==, toBytes, <=, match, hex, random, init, write, init, validate, init, init, hasPublicKey, match, <, >, len, maxInlineKeyLength, cmp, extractPublicKey, mapAnd, writeLPVarint, DNSANY, hash, append, $, MaError, IP, IPFS, write, getField, TranscoderOnion3, HTTPS, peekArray, MaPatternOp, CircuitRelay, concat, isEmpty, HTTP, getRepeatedField, getField, ProtoScalar, getProtoHeader, contains, WSS, protocols, &, Unreliable, getLen, UNIX, len, init, protoName, TranscoderDNS, validate, TranscoderIP6, initVBuffer, protoCode, mapEq, [], MaPattern, $, MaPatResult, initProtoBuffer, init, ProtoField, peekVarint, TranscoderP2P, protoArgument, getRequiredRepeatedField, mapOr, match, writeSeq, write, ProtoResult, WebRTCDirect, DNS6, initVBuffer, WebSockets, UDP, TranscoderIP6Zone, VBuffer, QUIC, toOpenArray, TranscoderOnion, IP4, TranscoderPort, write, isEnough, getRequiredField, getField, shortLog, readSeq, writeArray, write, UTP, Onion3, init, public, MAKind, [], getField, checkFieldNumber, IP6, shortLog, DNSADDR, ProtoFlags, isEmpty, IpTransportProtocol, getRepeatedField, ==, finish, TranscoderUnix, $, isEmpty, write, writePBVarint, ProtoFieldKind, TCP, MaResult, finish, ProtoError, &=, init, init, init, MultiAddress, initProtoBuffer, MAProtocol, readVarint, getPackedRepeatedField, TcpOnion3, getProtoHeader, ProtoHeader, init, vsizeof, getField, protoAddress, DNS4, readArray, writePacked, getRepeatedField, protoArgument, getPtr, TranscoderIP4, init, initVBuffer, P2PPattern, MaInvalidAddress, initProtoBuffer, isEnough, items, peekSeq, Reliable, hex, [], ProtoBuffer, matchPartial, DNS, len, WS, high, toString, encode, writeVarint, SupportedWireTypes, bytes, verify, mac, Signature, shortLog, $, toBytes, DigestSheme, ephemeral, getField, init, sign, encode, shuffle, random, supported, init, Secret, write, init, init, ==, ECDHEScheme, init, ephemeral, getBytes, createExchange, stretchKeys, write, public, init, init, SignedPayload, toBytes, PrivateKey, keyOpenArray, decode, decodeProposal, init, init, newRng, selectBest, Envelope, getPublicKey, init, init, getField, getField, iv, init, ==, write, init, SupportedSchemes, libp2p_pki_schemes, RsaDefaultKeySize, key, SupportedSchemesInt, random, toBytes, random, macOpenArray, CryptoError, toRawBytes, payload, write, CryptoResult, write, EnvelopeError, encode, createProposal, init, write, init, shortLog, init, getBytes, shortLog, PKScheme, init, PublicKey, init, getBytes, init, getField, ivOpenArray, random, orError, decodeExchange, init, $, decode, goffset, getRawBytes, getOrder, KeyPair