Types
AutonatV2Codec {.pure.} = enum DialRequest = "/libp2p/autonat/2/dial-request", DialBack = "/libp2p/autonat/2/dial-back"
- Source Edit
AutonatV2Error = object of LPError
- Source Edit
AutonatV2Msg = object case msgType*: MsgType of MsgType.DialRequest: dialReq*: DialRequest of MsgType.DialResponse: dialResp*: DialResponse of MsgType.DialDataRequest: dialDataReq*: DialDataRequest of MsgType.DialDataResponse: dialDataResp*: DialDataResponse
- Source Edit
AutonatV2Response = object reachability*: NetworkReachability dialResp*: DialResponse addrs*: Opt[MultiAddress]
- Source Edit
DialBackResponse = object status*: DialBackStatus
- Source Edit
DialBackStatus {.pure.} = enum Ok = 0
- Source Edit
DialDataRequest = object addrIdx*: AddrIdx numBytes*: NumBytes
- Source Edit
DialDataResponse = object data*: seq[byte]
- Source Edit
DialRequest = object addrs*: seq[MultiAddress] nonce*: Nonce
- Source Edit
DialResponse = object status*: ResponseStatus addrIdx*: Opt[AddrIdx] dialStatus*: Opt[DialStatus]
- Source Edit
DialStatus {.pure.} = enum Unused = 0, EDialError = 100, EDialBackError = 101, Ok = 200
- Source Edit
ResponseStatus {.pure.} = enum EInternalError = 0, ERequestRejected = 100, EDialRefused = 101, Ok = 200
- Source Edit
Consts
AutonatV2MsgLpSize: int = 1024
- Source Edit
DefaultAmplificationAttackDialTimeout: Duration = (value: 3000000000)
- Source Edit
DefaultDialDataSize: uint64 = 51200
- Source Edit
DefaultDialTimeout: Duration = (value: 15000000000)
- Source Edit
DialBackLpSize: int = 1024
- Source Edit
DialDataResponseLpSize: int = 5000
- Source Edit
Procs
proc `==`(a, b: AutonatV2Msg): bool {....raises: [], tags: [], forbids: [].}
- Source Edit
proc decode(T: typedesc[AutonatV2Msg]; pb: ProtoBuffer): Opt[T] {....raises: [].}
- Source Edit
proc decode(T: typedesc[DialBack]; pb: ProtoBuffer): Opt[T] {....raises: [].}
- Source Edit
proc decode(T: typedesc[DialBackResponse]; pb: ProtoBuffer): Opt[T] {....raises: [].}
- Source Edit
proc decode(T: typedesc[DialDataRequest]; pb: ProtoBuffer): Opt[T] {....raises: [].}
- Source Edit
proc decode(T: typedesc[DialDataResponse]; pb: ProtoBuffer): Opt[T] {....raises: [].}
- Source Edit
proc decode(T: typedesc[DialRequest]; pb: ProtoBuffer): Opt[T] {....raises: [].}
- Source Edit
proc decode(T: typedesc[DialResponse]; pb: ProtoBuffer): Opt[T] {....raises: [].}
- Source Edit
proc encode(dialBack: DialBack): ProtoBuffer {....raises: [], tags: [], forbids: [].}
- Source Edit
proc encode(dialBackResp: DialBackResponse): ProtoBuffer {....raises: [], tags: [], forbids: [].}
- Source Edit
proc encode(dialDataReq: DialDataRequest): ProtoBuffer {....raises: [], tags: [], forbids: [].}
- Source Edit
proc encode(dialDataResp: DialDataResponse): ProtoBuffer {....raises: [], tags: [], forbids: [].}
- Source Edit
proc encode(dialReq: DialRequest): ProtoBuffer {....raises: [], tags: [], forbids: [].}
- Source Edit
proc encode(dialResp: DialResponse): ProtoBuffer {....raises: [], tags: [], forbids: [].}
- Source Edit
proc encode(msg: AutonatV2Msg): ProtoBuffer {....raises: [], tags: [], forbids: [].}
- Source Edit