github ipfs/kubo v0.6.0
Release v0.6.0

latest releases: v0.27.0, v0.27.0-rc2, v0.27.0-rc1...
3 years ago

This is a relatively small release in terms of code changes, but it contains some significant changes to the IPFS protocol.

Highlights

The highlights in this release include:

  • The QUIC transport is enabled by default. Furthermore, go-ipfs will automatically run a migration to listen on the QUIC transport (on the same address/port as the TCP transport) to make this upgrade process seamless.
  • The new NOISE security transport is now supported but won't be selected by default. This transport will replace SECIO as the default cross-language interoperability security transport. TLS 1.3 will still remain the default security transport between go-ipfs nodes for now.

MIGRATION: This release contains a small config migration to enable listening on the QUIC transport in addition the TCP transport. This migration will:

  • Normalize multiaddrs in the bootstrap list to use the /p2p/Qm... syntax for multiaddrs instead of the /ipfs/Qm... syntax.
  • Add QUIC addresses for the default bootstrapers, as necessary. If you've removed the default bootstrappers from your bootstrap config, the migration won't add them back.
  • Add a QUIC listener address to mirror any TCP addresses present in your config. For example, if you're listening on /ip4/0.0.0.0/tcp/1234, this migration will add a listen address for /ip4/0.0.0.0/udp/1234/quic.

QUIC by default

This release enables the QUIC transport (draft 28) by default for both inbound and outbound connections. When connecting to new peers, libp2p will continue to dial all advertised addresses (tcp + quic) in parallel so if the QUIC connection fails for some reason, the connection should still succeed.

The QUIC transport has several key benefits over the current TCP based transports:

  • It takes fewer round-trips to establish a connection. With the QUIC transport, the IPFS handshake takes two round trips (one to establish the QUIC connection, one for the libp2p handshake). In the future, we should be able to reduce this to one round trip for the initial connection, and zero round trips for subsequent connections to a previously seen peer. This is especially important for DHT requests that contact many new peers.
  • Because it's UDP based instead of TCP based, it uses fewer file descriptors. The QUIC transport will open one UDP socket per listen address instead of one socket per connection. This should, in the future, allow us to keep more connections open.
  • Because QUIC connections don't consume file descriptors, we're able to remove the rate limit on outbound QUIC connections, further speeding up DHT queries.

Unfortunately, this change isn't without drawbacks: the QUIC transport may not be able to max out some links (usually due to poorly tuned kernel parameters). On the other hand, it may also be faster in some cases

If you hit this performance issue on Linux, you should tune the net.core.rmem_default and net.core.rmem_max sysctl parameters to increase your UDP receive buffer sizes.

If necessary, you can disable the QUIC transport by running:

> ipfs config --json Swarm.Transports.Network.QUIC false

NOTE: The QUIC transport included in this release is backwards incompatible with the experimental QUIC transport included in previous releases. Unfortunately, the QUIC protocol underwent some significant breaking changes and supporting multiple versions wasn't an option. In practice this degrades gracefully as go-ipfs will simply fall back on the TCP transport when dialing nodes with incompatible QUIC versions.

Noise Transport

This go-ipfs release introduces a new security transport: libp2p Noise (built from the Noise Protocol Framework). While TLS1.3 remains the default go-ipfs security transport, Noise is simpler to implement from scratch and will be the standard cross-platform libp2p security transport going forward.

This brings us one step closer to deprecating and removing support for SECIO.

While enabled by default, Noise won't actually be used by default it's negotiated. Given that TLS1.3 is still the default security transport for go-ipfs, this usually won't happen. If you'd like to prefer Noise over other security transports, you can change its priority in the config (Swarm.Transports.Security.Noise).

Gateway

This release brings two gateway-relevant features: custom 404 pages and base36 support.

Custom 404

You can now customize 404 Not Found error pages by including an ipfs-404.html file somewhere in the request path. When a requested file isn't found, go-ipfs will look for an ipfs-404.html in the same directory as the requested file, and in each ancestor directory. If found, this file will be returned (with a 404 status code) instead of the usual error message.

Support for Base36

This release adds support for a new multibase encoding: base36. Base36 is an optimally efficient case-insensitive alphanumeric encoding. Case-insensitive alphanumeric encodings are important for the subdomain gateway as domain names are case insensitive.

While base32 (the current default encoding used in subdomains) is simpler than base36, it's not optimally efficient and base36 Ed25519 IPNS keys are 2 characters too big to fit into the 63 character subdomain length limit. The extra efficiency from base36 brings us under this limit and allows Ed25519 IPNS keys to work with the subdomain gateway.

This release adds support for base36 but won't use it by default. If you'd like to re-encode an Ed25519 IPNS key into base36, you can use the ipfs cid format command:

$ ipfs cid format -v 1 --codec libp2p-key -b base36 bafzaajaiaejca4syrpdu6gdx4wsdnokxkprgzxf4wrstuc34gxw5k5jrag2so5gk k51qzi5uqu5dj16qyiq0tajolkojyl9qdkr254920wxv7ghtuwcz593tp69z9m

Gossipsub Upgrade

This release brings a new gossipsub protocol version: 1.1. You can read about it in the blog post.

Connectivity

This release introduces a new "peering" feature. The peering subsystem configures go-ipfs to connect to, remain connected to, and reconnect to a set of nodes. Nodes should use this subsystem to create "sticky" links between frequently useful peers to improve reliability.

Use-cases:

  • An IPFS gateway connected to an IPFS cluster should peer to ensure that the gateway can always fetch content from the cluster.
  • A dapp may peer embedded go-ipfs nodes with a set of pinning services or textile cafes/hubs.
  • A set of friends may peer to ensure that they can always fetch each other's content.

Changelog

Contributors

Contributor Commits Lines ± Files Changed
vyzo 224 +8016/-2810 304
Marten Seemann 87 +6081/-2607 215
Steven Allen 157 +4763/-1628 266
Aarsh Shah 33 +4619/-1634 128
Dirk McCormick 26 +3596/-1156 69
Yusef Napora 66 +2622/-785 98
Raúl Kripalani 24 +2424/-782 61
Hector Sanjuan 30 +999/-177 61
Louis Thibault 2 +1111/-4 4
Will Scott 15 +717/-219 31
dependabot-preview[bot] 53 +640/-64 106
Michael Muré 7 +456/-213 17
David Dias 11 +426/-88 15
Peter Rabbitson 11 +254/-189 31
Lukasz Zimnoch 9 +361/-49 13
Jakub Sztandera 4 +157/-104 9
Rod Vagg 1 +91/-83 2
RubenKelevra 13 +84/-84 30
JP Hastings-Spital 1 +145/-0 2
Adin Schmahmann 11 +67/-37 15
Marcin Rataj 11 +41/-43 11
Tiger 5 +53/-8 6
Akira 2 +35/-19 2
Casey Chance 2 +31/-22 2
Alan Shaw 1 +44/-0 2
Jessica Schilling 4 +20/-19 7
Gowtham G 4 +22/-14 6
Jeromy Johnson 3 +24/-6 3
Edgar Aroutiounian 3 +16/-8 3
Peter Wu 2 +12/-9 2
Sawood Alam 2 +7/-7 2
Command 1 +12/-0 1
Eric Myhre 1 +9/-2 1
mawei 2 +5/-5 2
decanus 1 +5/-5 1
Ignacio Hagopian 2 +7/-2 2
Alfonso Montero 1 +1/-5 1
Volker Mische 1 +2/-2 1
Shotaro Yamada 1 +2/-1 1
Mark Gaiser 1 +1/-1 1
Johnny 1 +1/-1 1
Ganesh Prasad Kumble 1 +1/-1 1
Dominic Della Valle 1 +1/-1 1
Corbin Page 1 +1/-1 1
Bryan Stenson 1 +1/-1 1
Bernhard M. Wiedemann 1 +1/-1 1

Don't miss a new kubo release

NewReleases is sending notifications on new releases.