Update go deps (major)
This PR contains the following updates:
| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| github.com/pion/dtls/v2 | v2.2.12 -> v3.0.1 |
||||
| github.com/pion/rtp | v1.8.9 -> v2.0.0 |
Release Notes
pion/dtls (github.com/pion/dtls/v2)
v3.0.1
Changelog
-
e20b162Fix multiple calls to Handshake -
f3e8a9eFix segfault in State::serialize method -
5a72b12Update module github.com/pion/transport/v3 to v3.0.7 -
c5ab822Update module golang.org/x/net to v0.27.0 -
23674bdUpdate module golang.org/x/crypto to v0.25.0 -
7ab74fbAdd support for MKI in use_srtp -
7139e0eFix time units in example -
2ed7caaUpdate module github.com/pion/transport/v3 to v3.0.6
v3.0.0
Pion DTLS v3.0.0 is now available. Pion DTLS is a Go implementation of DTLS. It allows for secure communication over UDP. It is commonly used for VPNs, WebRTC and other real-time protocols.
This release includes 115 commits from 17 authors. This release added Connection Identifiers, concurrent handshaking when Accepting inbound connections, Censorship Circumvention and better resilience against packet loss during handshaking.
A special thank you to kevmo314 and hasheddan for all their hard work on making this release happen.
This release contains breaking changes. Please read the following carefully, the breakage can't be caught at compile time. Each change will have a linked commit. Looking at examples/ in the linked commit should show what code you need to change in your application.
Breaking Changes
Before /v2 Pion DTLS would handshake on Server or Client creation. This design caused the Accept implementation to be blocking. A new connection couldn't be accept until the previous one had finished.
This design also doesn't match the crypto/tls implementation in stdlib. This mismatch would cause frustration/confusion for users.
Now the handshaking only occurs when Read,Write or Handshake is called. In most cases users shouldn't notice a difference.
If you do want a Handshake performed without a Read or Write this is the change needed.
Before
dtlsConn, err := dtls.Client(dtlsEndpoint, dtlsConfig)
if err != nil {
// handle error
}
// Perform logic from negotiated SRTP Profile
srtpProfile, ok := dtlsConn.SelectedSRTPProtectionProfile()
After
dtlsConn, err = dtls.Client(dtlsEndpoint, dtlsEndpoint.RemoteAddr(), dtlsConfig)
if err != nil {
// handle error
}
err = dtlsConn.Handshake()
if err != nil {
// Explicitly perform handshake
}
// Perform logic from negotiated SRTP Profile
srtpProfile, ok := dtlsConn.SelectedSRTPProtectionProfile()
This change was made in e4064683
New Features
Connection IDs
Connection IDs is a new feature added to the DTLS protocol itself. This change allows for clients to change IPs/Ports during a session. This allows for devices to roam (like phones) or for low power devices to shut down and reconnect without losing their DTLS session!
Connection ID generation is pluggable via the dtls.Config structure, and a random CID generator with a static size is provided for convenience. A new example has been added to demonstrate this functionality.
For those interested in digging deeper into the full set of changes, the majority of work was done in #570.
Censorship Circumvention
Software that is used to circumvent censorship like snowflake uses Pion. To block this (and other) software goverments have looked for patterns and differences in Pion DTLS and blocked it.
This new release contains hooks that allows users to randomize and circumvent these blocks. Users can modify ClientHello, ServerHello and CertificateRequest. Users can also smuggle information in a ServerHello/ClientHello RandomBytes.
You can see them all here here
Changelog
The complete log between v2.2.7 and v3.0.0:
-
0a8d838Prepare /v3 -
b6fd38eUpdate module github.com/pion/transport/v3 to v3.0.5 -
e406468Perform handshake on first read/write -
6178064Mark NULL and AES256CM SRTP ciphers as supported -
bc3159aAdded DTLS-SRTP IDs for NULL and AES256CM ciphers -
d013d0cOn Read Retransmit send FSM to SENDING -
ec76652Retransmit last flight when in finished -
602dc71Make localConnectionID thread safe -
0a1b73aRespect disableRetransmitBackoff -
a6d9640Add OnConnectionAttempt to Config -
48d6748Implement retransmit backoff according to 4.2.4.1 -
45e16a0Update module golang.org/x/net to v0.26.0 -
a5d1facFlight3: respect curves configuration -
61b3466Add ability to select cert based on ch rand bytes -
eddca22Update module golang.org/x/crypto to v0.24.0 -
edc7ad0Limit size of encrypted packet queue -
fbbdf66Update module golang.org/x/net to v0.25.0 -
efd6737Add test for PSK and Identity -
cb62aacFix typo in test -
494c1a3Remove testify dependency -
adec94aUpdate golang Docker tag to v1.22 -
8738ce1Add handshake hooking -
2c36d63Update module golang.org/x/net to v0.24.0 -
d606c79Update module golang.org/x/crypto to v0.22.0 -
f6f666eUpdate module golang.org/x/net to v0.23.0 [SECURITY] -
e008bc4Update CI configs to v0.11.12 -
3e667b0Update go.mod version to 1.19 -
ae51db9Update CI configs to v0.11.7 -
8244c45Update CI configs to v0.11.4 -
0ad9cfdUpdate module github.com/pion/transport/v3 to v3.0.2 -
8a93e0eFix TestErrorsTemporary -
38e39e4Update module golang.org/x/net to v0.22.0 -
a245727Update module golang.org/x/crypto to v0.21.0 -
5e95b5cUpdate module github.com/stretchr/testify to v1.9.0 -
35a00d3Fix linter errors -
96b8c29Fix linter errors -
2597464Update module golang.org/x/net to v0.20.0 -
42b6772Update module golang.org/x/crypto to v0.18.0 -
bb54a30If not found in the cache return nil -
3427819Format code -
798b32aFix flight1parse processing exception -
ba72fbaUpdate CI configs to v0.11.3 -
520d84cUpdate CI configs to v0.11.0 -
cfa868cRemove 'AUTHORS.txt' from README.md -
b4a403cRemove 'Generate Authors' workflow -
9ffd96cDrop invalid record silently during handshake -
3e8a7d7Update module golang.org/x/crypto to v0.17.0 [SECURITY] -
dc751e3Update module golang.org/x/net to v0.19.0 -
3f3d833Update module golang.org/x/crypto to v0.16.0 -
a8f7062Use atomic to avoid stale SRTP protection profile -
9cc3df9Respect Algorithm value in CertificateRequest -
7faf25fUpdate module golang.org/x/net to v0.17.0 [SECURITY] -
c864545Update module golang.org/x/net to v0.15.0 -
28431d9Export CipherSuiteID in connection State -
8401874Update module golang.org/x/crypto to v0.13.0 -
744e27aUpdate actions/checkout action to v4 -
2b584afSpecifying underlying type of conn ID atomic.Value -
70caf30Use atomic.Value to maintain Go 1.13 compatibility -
60064c6Update module github.com/pion/transport/v3 to v3.0.1 -
ef50d6bUpdate AUTHORS.txt -
7e5003aUpdate AUTHORS.txt -
dbc7fd9Update module github.com/pion/transport/v3 to v3.0.0 -
a681f67Correctly identify client and server with PSK ID -
e85f106Update module github.com/pion/transport/v2 to v2.2.2 -
7bf18f8Update module golang.org/x/net to v0.14.0 -
609e5beClear CIDs on potential session resumption -
e142ee1Serialize CIDs in state -
37fbc04Add CID send only client example -
6df50a6Add CID listener example -
f5875c1Set UDP routing if CID is enabled -
e663309Add CID routing unit tests -
9db84b5Add CID based datagram routing -
a8998afAdd UDP net.PacketListener unit tests -
71db42bIntroduce UDP net.PacketListener -
3afeb7dAdd PacketBuffer unit tests -
eb305b1Introduce net PacketBuffer -
703da0cConsume net package in tests -
4f53ce1Introduce net package -
f1d8b0aWrap Alerts when CID is negotiated -
3082313Convert nil CIDs to empty byte slice -
83b1254Fix name of cipher suite initialization function -
818feb8Set timeout to 10 minutes on e2e workflow -
d29c6f0Add basic connection ID generators -
2f2bc8dAdd e2e CID tests -
ee04141Update tests to wrap net.Conn -
f960a37Wrap net.Conn in DTLS listener -
afb61f1Update DTLS Conn to use PacketConn and CID -
d082911Add Conn to PacketConn utility -
e5420deUpdate handshaker to handle CID extension -
8922879Update ciphersuites to support CIDs -
8ba47cbImplement AEAD additional data with CID -
27fd131Add local and remote CID to state -
9a37bfdImplement AddUint48 utility -
1ce6f27Add CID content type -
6af61b1Allow packets to specify CID wrapped -
b7b1e44Add support for CID related generators -
2005135Add support for parsing CID records -
9e4a4e7Add DTLS connection ID extension -
e9b3ce0Update pion/transport to latest -
a1d270fUpdate module golang.org/x/crypto to v0.12.0 -
a6eca6cUpdate CI configs to v0.10.11 -
eb34e7dUpdate module golang.org/x/net to v0.13.0 -
c9eb5f2Update module golang.org/x/net to v0.12.0 -
b033847Clean up unneccessary nested logic -
7307f62Fix return of nil alertErrors -
b905606Add unmarshal unit tests for extensions -
0736d45Fix parsing supported EC point formats -
93704b3Add Daniel Mangum to AUTHORS.txt -
cabe5b8Enable Supported Signature Algorithms -
265bf11Enable Elliptic Curve Supported Point Formats -
d7303d0Wait for OpenSSL server shutdown in e2e test -
159122fUpdate e2e Go image to 1.20 -
8a11cf2Remove extraneous error checks in handshaker -
4fc3d8fUpdate module golang.org/x/net to v0.11.0 -
4b76abfUpdate module golang.org/x/crypto to v0.10.0
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
👻 Immortal: This PR will be recreated if closed unmerged. Get config help if that's undesired.
- [ ] If you want to rebase/retry this PR, check this box
This PR was generated by Mend Renovate. View the repository job log.
ℹ Artifact update notice
File name: go.mod
In order to perform the update(s) described in the table above, Renovate ran the go get command, which resulted in the following additional change(s):
- 2 additional dependencies were updated
Details:
| Package | Change |
|---|---|
golang.org/x/crypto |
v0.24.0 -> v0.25.0 |
golang.org/x/net |
v0.26.0 -> v0.27.0 |