Skip to content

Defining /http #63

Closed
Closed
@victorb

Description

@victorb

Currently, libraries are implementing /http while it hasn't been defined 1 2. We should catch up with the implementations and define it, then implement the behaviour.

As far as I know:

  • Can be be wrapped within /tls to support https.
  • Is a path protocol (as /unix), meaning no further multiaddrs can follow specifying /http/a/b/c as we don't know when it ends. This is a general problem for path protocols (currently just /unix)
  • Unsure of how to deal with complex strings that contains ?, / and other characters that might confuse multiaddr. Encode them maybe?

Examples:

  • https://1.2.3.4:5001/api => /ip4/1.2.3.4/tcp/5001/tls/http/api
  • http://1.2.3.4/api => /ip4/1.2.3.4/tcp/80/http/api
  • http://1.2.3.4 => /ip4/1.2.3.4/tcp/80/http
  • http://1.2.3.4/api/ => /ip4/1.2.3.4/tcp/80/http/api/ (keeping trailing slash)

Issues mentioning /http and /tls/http (https)

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