Skip to content

AutoNAT: Clarify cases in which response status E_DIAL_ERROR should be returned #411

@elenaf9

Description

@elenaf9

Follow up on libp2p/rust-libp2p#2618 (comment).

Concerning the ResponseStatus E_DIAL_ERROR, the AutoNAT spec currently only states that:

If all dials fail, the receiver sends a DialResponse message with the ResponseStatus E_DIAL_ERROR.

However, the Go implementation also returns DialErrors without even trying to the dial a remote peer. Concretely, this happens when skip_dial returns true for the client's observed address, which is the case if it is e.g. a relayed or private address.
I don't think that this should count as an dial error since the server never actually tried to dial the client. Instead a DialRefused should be returned (which would also match the returned status_text "refusing to dial peer with blocked observed address").

If folks disagree and are in favor of returning a DialError, this should be part of the spec.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions