libp2p/peerinfo

    Dark Mode
Search:
Group by:
  Source   Edit

Our local peer info

Types

AddressMapper = proc (listenAddrs: seq[MultiAddress]): Future[seq[MultiAddress]] {.
    ...gcsafe, raises: [].}
  Source   Edit
PeerInfo {.public.} = ref object
  peerId*: PeerId
  listenAddrs*: seq[MultiAddress]
  addrs: seq[MultiAddress]
  addressMappers*: seq[AddressMapper]
  protocols*: seq[string]
  protoVersion*: string
  agentVersion*: string
  privateKey*: PrivateKey
  publicKey*: PublicKey
  signedPeerRecord*: SignedPeerRecord
  Source   Edit
PeerInfoError = object of LPError
  Source   Edit

Procs

proc addrs(p: PeerInfo): seq[MultiAddress] {....raises: [], public, ...tags: [].}
  Source   Edit
proc fullAddrs(p: PeerInfo): MaResult[seq[MultiAddress]] {....raises: [], public,
    ...tags: [RootEffect].}
  Source   Edit
proc new(p: typedesc[PeerInfo]; key: PrivateKey;
         listenAddrs: openArray[MultiAddress] = [];
         protocols: openArray[string] = []; protoVersion: string = "";
         agentVersion: string = ""; addressMappers = newSeq[AddressMapper]()): PeerInfo {.
    ...raises: [LPError], raises: [], public.}
  Source   Edit
proc parseFullAddress(ma: MultiAddress): MaResult[(PeerId, MultiAddress)] {.
    ...raises: [], public, ...tags: [RootEffect].}
  Source   Edit
proc parseFullAddress(ma: string | seq[byte]): MaResult[(PeerId, MultiAddress)] {.
    ...raises: [], public.}
  Source   Edit
func shortLog(p: PeerInfo): auto {....raises: [], public, ...tags: [RootEffect].}
  Source   Edit
proc update(p: PeerInfo): Future[void] {.stackTrace: false, ...gcsafe, raises: [],
    raises: [], public, ...raises: [], public, ...tags: [RootEffect].}
  Source   Edit

Templates

template formatItIMPL(it: PeerInfo): auto
  Source   Edit

Exports

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