Releases: n0-computer/iroh
v0.91.2
v0.91.1
chore: Release iroh-base version 0.91.1
v0.91.0
⚠️ Breaking Changes
-
iroh
- changed
-
edition is now set to
edition2024
-
The relay wire protocol changed: All relayed messages now contain at least an additional ECN byte.
They might be accidentally compatible when GSO is not enabled, but they're likely not.
This means this version of iroh can't connect to older relays or older clients on newer relays.
ClientToRelayMsg::SendPacket
was removed in favor ofClientToRelayMsg::Datagrams
RelayToClientMsg::ReceivedPacket
was removed in favor ofRelayToClientMsg::Datagrams
FrameType
has changed variants:SendPacket
andRecvPacket
were removedClientToRelayDatagram
andClientToRelayDatagramBatch
were addedRelayToClientDatagram
andRelayToClientDatagramBatch
were added
-
The default relay URLs have changed. We are still maintaining relay URLs for version
0.90.0
, those will be phased out next release. -
Updated
n0-watcher
from version0.2
to0.3
- Migration guide for users:
endpoint.node_addr().initialized().await?
->endpoint.node_addr().initialized().await
(no?
needed anymore) and similarly forendpoint.home_relay()
and other uses ofWatcher
s.endpoint.node_addr().get()?
->endpoint.node_addr().get()
and similarly forendpoint.home_relay()
and other uses ofWatcher
s.- If all you have is a
&impl Watcher
but you need the current value, then you can't callWatcher::get
anymore, as that now takes a&mut self
instead of&self
. You can work around this by.clone()
ing to an intermediate watcher:watcher_ref.get()
->watcher_ref.clone().get()
- Migration guide for users:
-
- removed
- Removed
iroh::discovery::pkarr::dht::Builder::initial_publish_delay
- Removed
iroh::endpoint::Builder::relay_conn_protocol
. It's now always websockets - Removed the
iroh::RelayProtocol
re-export (the type was removed iniroh-relay
)
- Removed
- changed
-
iroh-relay
- removed
- Removed
iroh_relay::client::SendMessage
andiroh_relay::client::ReceivedMessage
in favor ofClientToRelayMsg
andRelayToClientMsg
respectively. - Removed
ClientBuilder::is_prober
- Removed
ClientBuilder::protocol
- Removed
http::Protocol
type - Removed
relay_accepts
andwebsocket_accepts
metrics
- Removed
- changed
impl Stream for Client
now producesRelayToClientMsg
instead ofReceivedMessage
Client
nowimpl Sink<ClientToRelayMsg>
instead ofimpl Sink<SendMessage>
- Moved
protos::relay::FrameType
toprotos::common::FrameType
and adjusted frame types to those of the current set of protocols - Renamed
frames_rx_ratelimited_total
metric tobytes_rx_ratelimited_total
, which now tracks bytes not frames
- removed
⛰️ Features
- (iroh) Update to new relay servers (#3412) - (f3e4307)
- (iroh,iroh-relay) [breaking] Use stride instead of custom split protocol, send ECN bits (#3389) - (f3fd988)
- (iroh-relay) [breaking] Implement new handshake protocol, refactor frame types (#3331) - (3a1592a)
- [breaking] Update to edition 2024 and update deps to latest (#3386) - (e2cfde7)
- Add the timeout duration to the relay dial error (#3406) - (db36c65)
🐛 Bug Fixes
- (iroh) Use std Mutex instead of tokio Mutex (#3374) - (eb383a6)
- (iroh) Track path validity for all paths and replace
BestAddr
withPathValidity
(#3400) - (a3187ca) - (iroh) Re-batch received relay datagram batches in case they exceed
max_receive_segments
(#3414) - (a8485ad) - (iroh) Only clear
last_call_me_maybe
when the best addr became invalid (#3415) - (bcb60d4) - (iroh-relay) Fix proptests, make
Datagrams::segment_size
be anOption<NonZeroU16>
(#3404) - (75fd57c) - Fix dht publishing at startup (#3397) - (dd1d692)
- Better tracing spans (#3399) - (f8f7f95)
- Add missing use<> for wasm_browser (#3411) - (91c2e63)
- Wait for at least one ipv6 and ipv4 qad report (#3413) - (b755db4)
🚜 Refactor
📚 Documentation
🧪 Testing
⚙️ Miscellaneous Tasks
v0.90.0
⚠️ Breaking Changes
-
iroh
-
removed
iroh::endpoint::Builder:: tls_x509
removed, this is the tls mechanism that has been removediroh::endpoint::Builder:: tls_raw_public_keys
removed, this is the default mechanism now, so not needed anymoreDisplay
implementation was removed forSecretKey
, use.to_bytes()
and encode as hex to get the previous bytes explicitly, for example:
let encoded_key = data_encoding::HEXLOWER.encode(&secret_key.to_bytes())
- removed
iroh_relay::protos::stun::StunError
- removed
iroh_relay::server::testing::stun_config
- removed
iroh_relay::protos::stun
- removed
iroh_relay::quic::QuicClient::get_addr_and_latency
- removed
DEFAULT_STUN_PORT
- Removed
iroh::discovery::dns::DnsDiscovery::new
, useDnsDiscovery::builder
instead - Removed
iroh::discovery::pkarr::PkarrPublisher::new
, usePkarrPublisher::builder
instead - Removed
iroh::discovery::pkarr::PkarrPublisher::with_options
, usePkarrPublisher::builder
instead - Removed
iroh::discovery::pkarr::PkarrResolver::new
, usePkarrResolver::builder
instead
-
changed
- all public APIs return concrete error types, rather than
anyhow::Error
iroh::protocol::ProtocolHandler
methods now returnimpl Future
instead ofBoxFuture
. You can simply remove theBox::pin(async move {})
from the implementations and instead implement the methods asasync fn
. See the updated documentation for theiroh::protocol
module for an example.iroh::protocol::ProtocolHandler
is no longer dyn-compatible. If you need a dyn-compatible version, you need to build your own dyn-compatible wrapper trait. See the (non-public)DynProtocolHandler
iniroh::protocol
as an example.iroh::watcher
is now its own craten0-watcher
, but theWatcher
trait is still a top level export iniroh
iroh::endpoint::Endpoint::node_addr
now returnsimpl Watcher<Value = Option<NodeAddr>>
iroh::endpoint::Endpoint::home_relay
now returnsimpl Watcher<Value = Vec<RelayUrl>>
iroh::endpoint::Endpoint::bound_sockets
now returnsVec<SocketAddr>
iroh-quinn
is updated to0.14.0
iroh::protocol::RouterBuilder::accept
now takesimpl Into<Box<dyn DynProtocolHandler>>
instead ofimpl ProtocolHandler
. Because of a blanketFrom
impl this change does not need any changes by users: you can still pass anyimpl ProtocolHandler
toaccept
. Additionally, if you have your own builder struct upstream, you can now also pass aBox<dyn DynProtocolHandler>
toaccept
, which wasn't possible previously.iroh::discovery::Lagged
changed from a tuple to a structiroh::watcher::Disconnected
is changed from a tuple to a structiroh::watcher::Disconnected
is no longerUnwindSafe
orRefUnwindSafe
iroh::watcher::InitializedFut
is no longerRefUnwindSafeiroh-base
iroh::endpoint::Builder::add_discovery
now takes animpl iroh::discovery::IntoDiscovery
argument instead of a closure that returns aDiscovery
. You can implement that on a builder struct, and anyT: Discovery
has an auto-impl ofIntoDiscovery
.iroh::discovery::Discovery::resolve
no longer gets a&Endpoint
argument. If you need an endpoint in your discovery service, add a builder struct and implementIntoDiscovery
for it, which gives you an endpoint that you can clone into your serviceiroh::discovery::pkarr::PkarrPublisher::n0_dns
now takes no arguments and returns aPkarrPublisherBuilder
. The secret key is set onPkarrPublisherBuilder::build
instead.
- all public APIs return concrete error types, rather than
-
-
iroh-base
changed
iroh_base::ticket::Error
is renamed toiroh_base::ticket::ParseError
iroh_base::key::KeyParsingError
has changed from athiserror
error to asnafu
erroriroh-relay
-
iroh-relay
changed
iroh_relay::node_info::MaxLengthExceededError
is no longerUnwindSafe
orRefUnwindSafe
iroh_relay::node_info::MaxLengthExceededError
was changed from athiserror
to asnafu
erroriroh_relay::client::ConnSendError
is nowiroh_relay::client::SendError
iroh_relay::protos::stun::Error
is nowiroh_relay::protos::stun::StunError
⛰️ Features
- (iroh) Allow protocols to gracefully shutdown connections (#3319) - (da571c1)
- (iroh) [breaking] Make ProtocolHandler use async functions (#3320) - (e36ac77)
- (iroh) [breaking] Remove deprecated x509 libp2p TLS authentication (#3330) - (136b855)
- (iroh) [breaking] Introduce transport abstraction (#3279) - (d915bfd)
- (iroh) Re-export
n0_watcher::Watcher
trait (#3356) - (bc6e9e3) - (iroh) [breaking] Expose
DynProtocolHandler
(#3366) - (056df1d) - Make
Endpoint::node_addr
watchable and addtrait Watcher
& combinators (#3045) - (7911255) - [breaking] Concrete errors (#3161) - (75eae87)
- Add methods to create variants of the
iroh-base::ticket::ParseError
enum. (#3362) - (1859de3)
🐛 Bug Fixes
- (iroh) Correctly hook up ipv6 addr lookups (#3342) - (b8b5bc3)
- (iroh-base) [breaking] Remove display impl for SecretKey (#3364) - (19323e6)
- Remove unneeded lifetime bound for watcher in wasm (#3354) - (84dd511)
🚜 Refactor
- (iroh) [breaking] Simplify discovery errors (#3340) - (fad99ab)
- (iroh) [breaking] Rename ProtocolError to AcceptError (#3339) - (d4de591)
- (iroh) [breaking] Rework net_report (#3314) - (dcbebe9)
- (iroh) [breaking] Add
IntoDiscovery
trait (#3327) - (7f2cdd1) - (iroh-relay,iroh) Slightly clean up staggered DNS errors (#3337) - (444c76b)
🧪 Testing
- (iroh-relay) Add 300ms timeout to the
test_qad_client_closes_unresponsive_fast
test (#3332) - (b647af9)
⚙️ Miscellaneous Tasks
- ()* Upgrade to the latest
iroh-metrics
,portmapper
, andswarm-discovery
(#3369) - (79bc05b) - (iroh) [breaking] Change default relays to new "canary" relays (#3368) - (6e72f20)
- (iroh-relay) Make QAD test non-flaky by using tokio's paused time (#3341) - (2b6c258)
- (iroh-relay) Fix cargo check warning (#3346) - (c7cf08d)
- Make clippy 1.87 happy (#3318) - (02acba9)
- Update project_sync workflow (#3325) - (518400b)
Bugfix
- Use staging relay in n0_dns_pkarr_relay (#3335) - ([aebbc72](aebbc727ffbb...
v0.35.0
⚠️ Breaking Changes
iroh
- remove
pub fn default_from_node(url: RelayUrl, stun_port: u16) -> RelayMap
- change
pub fn from_url(url: RelayUrl) -> RelayMap
, useFrom<RelayUrl>
insteadRouter::spawn
is now a plain function instead of anasync fn
Router::spawn
is now infallible, instead of returninganyhow::Result<()>
- All metrics structs (
iroh::metrics::{MagicsockMetrics, PortmapMetrics, NetReportMetrics}
) now implementMetricsGroup
from the new version0.34
ofiroh-metrics
and no longer implement traits from[email protected]
. - Metrics are no longer registered onto the static superglobal
Core
.iroh
does not usestatic_core
feature ofiroh-metrics
. Metrics are now exposed from the subsystems that track them, see e.g.Endpoint::metrics
. - Several methods now take a
Metrics
argument. You can always passDefault::default
if you don't want to unify metrics tracking with other sections. pkarr::SignedPacket
, as used as a parameter iniroh::dns::node_info::NodeInfo::to_pkarr_signed_packet
andiroh::dns::node_info::NodeInfo::from_pkarr_signed_packet
is now expectingpkarr
at major version3
instead of2
- remove
iroh-relay
- change
- Minor change in the
From
impls forConnSendError
due to changing the underlying library
- Minor change in the
- change
⛰️ Features
- (iroh) Allow connecting with "fallback" ALPNs (#3282) - (839bfaa)
- (iroh) Add
net-report
method on theiroh::Endpoint
that returns aWatchable<Report>
(#3293) - (3448b4b) - (iroh,iroh-relay) Enable proxying and test-utils support for websockets, allow configuring websockets in
endpoint::Builder
(#3217) - (8a24a95) - (iroh-relay) [breaking] Adjust APIs to make it easier to create
RelayMap
s from lists ofRelayUrls
(#3292) - (cd0a47a) - Update to [email protected] (#3274) - (1d79f92)
- [breaking] Metrics refactor (#3262) - (1957ca8)
- Fix minimal crates selection (#3255) - (a62a2bd)
- Improve transfer, publish, resolve examples (#3296) - (30577d3)
🐛 Bug Fixes
- (iroh) [breaking] Update dependencies & fix 0-RTT with newer rustls by pulling the expected
NodeId
out of theServerName
in verifiers (#3290) - (af882a6) - (iroh-dns-server) Backwards compatibility for packets stored with iroh-dns-server v0.34 or lower (#3295) - (74b8baa)
- (iroh-dns-server) Fixes for packet expiry (#3297) - (146f423)
- (iroh-relay) Don't stop relay client actor if queues become full (#3294) - (f3c9af3)
⚙️ Miscellaneous Tasks
- (iroh) Add
echo-no-router.rs
example (#3267) - (7e13aa3) - Update to mozilla-actions/[email protected] (#3268) - (792e6c4)
Deps
v0.34.1
✏️ Notes
With this patch release, we have updated from the alpha
to the v0.25.1
version of hickory-resolver
. If you have been pinning your own versions, you may have a conflict when updating to [email protected]
.
⛰️ Features
- (iroh) Move
iroh-net-report
back intoiroh
(#3251) - (d6bc83f) - (iroh-relay) Allow to authenticate nodes via a HTTP POST request (#3246) - (592c3b5)
🐛 Bug Fixes
- (iroh) Reduce log-level of unknown pong message (#3242) - (cf3e650)
- (iroh) Reap ActiveRelayActor handles for idle relays (#3249) - (528a32c)
- Backoff before retry if relay connection terminates (#3254) - (bc6e98c)
⚙️ Miscellaneous Tasks
- (iroh) Update from alpha to release 0.25 hickory (#3256) - (26289ca)
- (iroh) Don't depend on unused
rustls-platform-verifier
dependency (#3257) - (42b605e) - (iroh-relay) Fix README.md instuctions to enable
server
feature (#3239) - (7588135)
Deps
v0.34.0
⚠️ Breaking Changes
iroh
- added:
endpoint::Builder::tls_x509
to enable using X.509 TLS certificates.
By default iroh endpoints will now use the newRawPublicKey
TLS configuration. This means they will not be able to talk to older iroh nodes. If needed, the old mechanism can still be used by configuring the endpoint like this:
- added:
let endpoint = Endpoint::builder()
.tls_x509() // <--- this enables the old style TLS authentication
// ...
.bind();
-
changed:
- renamed
iroh::discovery::local_swarm_discovery
toiroh::discovery::mdns
- renamed
iroh::discovery::local_swarm_discovery::LocalSwarmDiscovery
toiroh::discovery::mdns::MdnsDiscovery
- changed the default cert format for
Reloading
certificate mode fromDER
toPEM
- trait method
ProtocolHandler::accept(&self, connection: iroh::endpoint::Connection)
used to take aniroh::endpoint::Connecting
, now takes airoh::endpoint::Connection
.
- renamed
-
iroh-net-report
- removed:
iroh-base
: We removed the unusedgetrandom
optional dependency. As such, there doesn't exist agetrandom
feature flag iniroh-base
anymore.MAPPED_ADDR_PORT
is removed.
- changed:
IpMappedAddr::socket_addr
->IpMappedAddr::private_socket_addr
- removed:
⛰️ Features
- (iroh) Enable
netwatch::netmon::Monitor
and themetrics
feature in Wasm (#3206) - (7acfe39) - (iroh) [breaking] Allow for limiting incoming connections on the router (#3157) - (3e16848)
- (iroh) [breaking] Switch TLS authentication to raw public keys (#2937) - (d8c8c8e)
- [breaking] Add
DiscoveryItem::user_data
method and adjustlocally-discovered-nodes
example (#3215) - (f6b5f5c)
🐛 Bug Fixes
- (iroh) Don't cause re-stuns all the time in browsers (#3234) - (ef3645e)
- (iroh-base) [breaking] Remove unused
getrandom
dependency (#3202) - (0c7a122) - (iroh-relay) Report round-trip-latency instead of single-trip for QAD (#3230) - (00f8309)
- (relay) [breaking] Change default cert format from der to pem (#3204) - (4930837)
- Update project_sync (#3213) - (aa7463b)
🚜 Refactor
- (iroh) Factor out socket-related state & construction into
magicsock::SocketState
andActorSocketState
(#3203) - (2a49265) - (iroh, iroh-net-report) [breaking] Make ports more private (#3207) - (906250b)
📚 Documentation
⚙️ Miscellaneous Tasks
v0.33.0
⚠️ Breaking Changes
- iroh
- removed
iroh::test_utils::create_dns_resolver
is removed, useiroh::dns::DnsResolver::new
insteadiroh::dns::resolver
andiroh::dns::default_resolver
are removed. There is no static, global DNS resolver anymore. If you want to share a DNS resolver between endpoints, create the resolver yourself withiroh::dns::DnsResolver::new
and clone it into the endpoint builders (inEndpointBuilder::dns_resolver
). If you want to reuse the DNS resolver from an endpoint, you can access it withEndpoint::dns_resolver
and clone it to wherever you need it.iroh::dns::node_info::{IrohAttr, TxtAttrs, node_id_from_hickory_name}
are no longer public. Useiroh::dns::DnsResolver::lookup_node_by_id
oriroh::dns::DnsResolver::lookup_node_by_domain_name
to lookup node info from DNS.iroh::dns::node_info::{to_z32, from_z32}
are removed. Use the methods oniroh::dns::node_info::NodeIdExt
trait instead.iroh::dns::ResolverExt
is removed. Use the methods oniroh::dns::DnsResolver
instead.iroh::discovery::Discovery::publish
now takesdata: &NodeData
as its single argument.iroh::discovery::NodeData
is a re-export ofiroh_relay::dns::node_info::NodeData
, and contains relay URL and direct addresses. See docs forNodeData
for details.iroh::Endpoint::connect_with
was removed, useiroh::Endpoint::connect_with_opts
instead
- changed
iroh::dns::DnsResolver
used to be a type alias and now is a reexport ofiroh_relay::dns::DnsResolver
structiroh::dns::node_info
module is now a reexport ofiroh_relay::dns::node_info
iroh::discovery::dns::{N0_DNS_NODE_ORIGIN_PROD, N0_DNS_NODE_ORIGIN_STAGING}
are now reexports ofiroh_relay::dns::{N0_DNS_NODE_ORIGIN_PROD, N0_DNS_NODE_ORIGIN_STAGING}
- The methods in
iroh::dns::DnsResolver
now take animpl ToString
instead ofimpl hickory_proto::rr::domain::IntoName
for theirhost
argument iroh::discovery::DiscoveryItem
no longer has any public fields. There are now getters for the contained data, and constructors for createing aDiscoveryItem
from aNodeInfo
.iroh_relay::dns::node_info::NodeInfo
is changed.NodeInfo::new
now has a singleNodeId
argument. UseNodeInfo::with_direct_addresses
andNodeInfo::with_relay_url
to set addresses and relay URL. Alternatively, useNodeInfo::from_parts
and pass aNodeData
struct.NodeInfo
now has two public fieldsnode_id: NodeId
anddata: NodeData
, and setter and getter methods for the relay URL and direct addresses.
iroh::discovery::pkarr::PkarrPublisher::update_addr_info
now takes aNodeData
argumentiroh::endpoint::Connection::into_0rtt
now returnsiroh::endpoint::ZeroRttAccepted
, instead ofiroh_quinn::ZeroRttAccepted
- removed
⛰️ Features
- (iroh) Enable applications to establish 0-RTT connections (#3163) - (f0abede)
- (iroh) Add subscription stream to watch all discovery results (#3181) - (695f7c1)
- (iroh) Publish and resolve user-defined data in discovery (#3176) - (ac78cf2)
- (iroh) Make
iroh
compile towasm32-unknown-unknown
(#3189) - (247b891) - (iroh-net-report) Support wasm32 building & running (#3139) - (6f923a3)
- (iroh-relay) Make
Endpoint::close
faster by aborting QAD connections faster (#3182) - (f640e83)
🐛 Bug Fixes
- (iroh) Allow gracefully closing connections (#3170) - (d9a5b8e)
- (iroh-relay) Fix the number of active relay connections (#3194) - (397d08d)
- (iroh-relay) Bring back unique node counts (#3197) - (892c767)
- Update hickory resolver to 0.25.0-.alpha.5 (#3178) - (a4fcaaa)
🚜 Refactor
- (iroh) Store quic config, instead of recreating (#3171) - (9eccb05)
- [breaking] Use a single DNS resolver (#3167) - (c39b998)
- [breaking] Streamline discovery and node info types (#3175) - (3e3798f)
🧪 Testing
⚙️ Miscellaneous Tasks
v0.32.1
v0.32.0
⚠️ Breaking Changes
-
iroh
- removed
iroh::endpoint::get_remote_node_id
has been removed. Useiroh::endpoint::Connection::remote_node_id
instead.iroh::endpoint::Connecting::local_ip
is removed.iroh::endpoint::Connecting::remote_address
is removed.iroh::endpoint::Connection::local_ip
is removed.iroh::endpoint::Connection::remote_address
is removed.discovery-pkarr-dht
feature became non-default (moved from opt-out to opt-in).
- changed
iroh::Endpoint::connect
returns aniroh::endpoint::Connection
- removed
-
iroh-net-report
- changed
iroh_net_report::Client::new
now takes additional parametermapped_addrs: Option
- changed
-
iroh-test
- whole crate is removed:
iroh_test::parse_hexdump
is replaced withdata_encoding::HEXLOWER.decode
iroh_test::CallOnDrop
is replaced withtokio_util::task::AbortOnDropHandle
iroh-test::logging
is replaced withtracing-test
- whole crate is removed:
⛰️ Features
- (iroh) Allow customising the TransportConfig for connections (#3111) - (2b92db4)
- (iroh) [breaking] Wrap the Connection struct so we own the type (#3110) - (2e61ff2)
- (iroh) [breaking] Remove access to local and remote IP addresses (#3148) - (08bd2a1)
- (iroh-relay) Make the client side of
iroh-relay
compile & run in browsers (#3119) - (03e3e3c) - [breaking] Add QUIC Address Discovery to iroh (#3049) - (243a04a)
🐛 Bug Fixes
- (iroh) Remove
quinn::Endpoint::wait_idle
fromiroh::Endpoint::close
process (#3165) - (a1d21c6) - (iroh-net-report) Only add QUIC ipv6 probes if we have an ipv6 interface (#3133) - (9275d22)
- (iroh-relay) Fix client actors not closing (#3134) - (e5bbbe1)
- Handle invalid input length when parsing a node id (#3155) - (a8d058f)
🚜 Refactor
- (iroh) Replace
timer
module withAbortOnDropHandle
and sleep (#3141) - (43e9805) - Use
n0-future
in favor offutures-*
libraries andtokio::{spawn,task,time}
(#3156) - (617fa50) - [breaking] Remove iroh-test crate (#3162) - (7b6884f)
- Cleaning up unnecessary logs (#3164) - (9a75d14)