From 2f8373055629e18f5b8d276730348816c7eec2d3 Mon Sep 17 00:00:00 2001 From: guillaumemichel Date: Tue, 3 Sep 2024 12:17:19 +0200 Subject: [PATCH] increase webrtc max message size from 16kiB to 256kiB --- transports/webrtc-websys/src/connection.rs | 2 +- transports/webrtc/src/tokio/sdp.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/transports/webrtc-websys/src/connection.rs b/transports/webrtc-websys/src/connection.rs index d0c6ccd2238..587b2f59029 100644 --- a/transports/webrtc-websys/src/connection.rs +++ b/transports/webrtc-websys/src/connection.rs @@ -298,7 +298,7 @@ mod sdp_tests { #[test] fn test_fingerprint() { - let sdp = "v=0\r\no=- 0 0 IN IP6 ::1\r\ns=-\r\nc=IN IP6 ::1\r\nt=0 0\r\na=ice-lite\r\nm=application 61885 UDP/DTLS/SCTP webrtc-datachannel\r\na=mid:0\r\na=setup:passive\r\na=ice-ufrag:libp2p+webrtc+v1/YwapWySn6fE6L9i47PhlB6X4gzNXcgFs\r\na=ice-pwd:libp2p+webrtc+v1/YwapWySn6fE6L9i47PhlB6X4gzNXcgFs\r\na=fingerprint:sha-256 A8:17:77:1E:02:7E:D1:2B:53:92:70:A6:8E:F9:02:CC:21:72:3A:92:5D:F4:97:5F:27:C4:5E:75:D4:F4:31:89\r\na=sctp-port:5000\r\na=max-message-size:16384\r\na=candidate:1467250027 1 UDP 1467250027 ::1 61885 typ host\r\n"; + let sdp = "v=0\r\no=- 0 0 IN IP6 ::1\r\ns=-\r\nc=IN IP6 ::1\r\nt=0 0\r\na=ice-lite\r\nm=application 61885 UDP/DTLS/SCTP webrtc-datachannel\r\na=mid:0\r\na=setup:passive\r\na=ice-ufrag:libp2p+webrtc+v1/YwapWySn6fE6L9i47PhlB6X4gzNXcgFs\r\na=ice-pwd:libp2p+webrtc+v1/YwapWySn6fE6L9i47PhlB6X4gzNXcgFs\r\na=fingerprint:sha-256 A8:17:77:1E:02:7E:D1:2B:53:92:70:A6:8E:F9:02:CC:21:72:3A:92:5D:F4:97:5F:27:C4:5E:75:D4:F4:31:89\r\na=sctp-port:5000\r\na=max-message-size:262144\r\na=candidate:1467250027 1 UDP 1467250027 ::1 61885 typ host\r\n"; let fingerprint = parse_fingerprint(sdp).unwrap(); diff --git a/transports/webrtc/src/tokio/sdp.rs b/transports/webrtc/src/tokio/sdp.rs index 4be4c19f188..396d8af584f 100644 --- a/transports/webrtc/src/tokio/sdp.rs +++ b/transports/webrtc/src/tokio/sdp.rs @@ -140,5 +140,5 @@ a=ice-pwd:{pwd} a=fingerprint:{fingerprint_algorithm} {fingerprint_value} a=setup:actpass a=sctp-port:5000 -a=max-message-size:16384 +a=max-message-size:262144 ";