werift 0.25.1 → 0.26.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/common/src/asn1.d.ts +42 -0
- package/lib/common/src/asn1.js +163 -0
- package/lib/common/src/asn1.js.map +1 -0
- package/lib/common/src/binaryData.js.map +1 -1
- package/lib/common/src/index.d.ts +6 -5
- package/lib/common/src/index.js +6 -5
- package/lib/common/src/index.js.map +1 -1
- package/lib/common/src/log.d.ts +12 -1
- package/lib/common/src/log.js +137 -5
- package/lib/common/src/log.js.map +1 -1
- package/lib/common/src/network.js.map +1 -1
- package/lib/common/src/queue.d.ts +41 -0
- package/lib/common/src/queue.js +146 -0
- package/lib/common/src/queue.js.map +1 -0
- package/lib/common/src/transport.d.ts +15 -2
- package/lib/common/src/transport.js +98 -14
- package/lib/common/src/transport.js.map +1 -1
- package/lib/dtls/src/cipher/create.js.map +1 -1
- package/lib/dtls/src/cipher/ec.js +8 -8
- package/lib/dtls/src/cipher/ec.js.map +1 -1
- package/lib/dtls/src/cipher/namedCurve.js +6 -7
- package/lib/dtls/src/cipher/namedCurve.js.map +1 -1
- package/lib/dtls/src/cipher/prf.d.ts +2 -2
- package/lib/dtls/src/cipher/prf.js +29 -8
- package/lib/dtls/src/cipher/prf.js.map +1 -1
- package/lib/dtls/src/cipher/suites/aead.d.ts +1 -1
- package/lib/dtls/src/context/certificate.d.ts +32 -0
- package/lib/dtls/src/context/certificate.js +54 -0
- package/lib/dtls/src/context/certificate.js.map +1 -0
- package/lib/dtls/src/context/cipher.d.ts +12 -6
- package/lib/dtls/src/context/cipher.js +52 -103
- package/lib/dtls/src/context/cipher.js.map +1 -1
- package/lib/dtls/src/context/transport.d.ts +4 -0
- package/lib/dtls/src/context/transport.js +14 -0
- package/lib/dtls/src/context/transport.js.map +1 -1
- package/lib/dtls/src/flight/client/flight5.js.map +1 -1
- package/lib/dtls/src/flight/flight.js +8 -1
- package/lib/dtls/src/flight/flight.js.map +1 -1
- package/lib/dtls/src/flight/server/flight2.js.map +1 -1
- package/lib/dtls/src/flight/server/flight4.d.ts +2 -1
- package/lib/dtls/src/flight/server/flight4.js +8 -2
- package/lib/dtls/src/flight/server/flight4.js.map +1 -1
- package/lib/dtls/src/handshake/extensions/signature.d.ts +1 -1
- package/lib/dtls/src/handshake/extensions/signature.js.map +1 -1
- package/lib/dtls/src/handshake/message/alert.js +1 -1
- package/lib/dtls/src/handshake/message/alert.js.map +1 -1
- package/lib/dtls/src/handshake/message/certificate.js +1 -1
- package/lib/dtls/src/handshake/message/certificate.js.map +1 -1
- package/lib/dtls/src/handshake/message/changeCipherSpec.js +2 -3
- package/lib/dtls/src/handshake/message/changeCipherSpec.js.map +1 -1
- package/lib/dtls/src/handshake/message/client/certificateVerify.d.ts +1 -1
- package/lib/dtls/src/handshake/message/client/certificateVerify.js +1 -1
- package/lib/dtls/src/handshake/message/client/certificateVerify.js.map +1 -1
- package/lib/dtls/src/handshake/message/client/hello.js +1 -1
- package/lib/dtls/src/handshake/message/client/hello.js.map +1 -1
- package/lib/dtls/src/handshake/message/client/keyExchange.js +1 -1
- package/lib/dtls/src/handshake/message/client/keyExchange.js.map +1 -1
- package/lib/dtls/src/handshake/message/server/certificateRequest.d.ts +1 -1
- package/lib/dtls/src/handshake/message/server/certificateRequest.js +1 -1
- package/lib/dtls/src/handshake/message/server/certificateRequest.js.map +1 -1
- package/lib/dtls/src/handshake/message/server/hello.d.ts +1 -1
- package/lib/dtls/src/handshake/message/server/hello.js +2 -2
- package/lib/dtls/src/handshake/message/server/hello.js.map +1 -1
- package/lib/dtls/src/handshake/message/server/helloDone.js +1 -1
- package/lib/dtls/src/handshake/message/server/helloDone.js.map +1 -1
- package/lib/dtls/src/handshake/message/server/helloVerifyRequest.js +1 -1
- package/lib/dtls/src/handshake/message/server/helloVerifyRequest.js.map +1 -1
- package/lib/dtls/src/handshake/message/server/keyExchange.d.ts +1 -1
- package/lib/dtls/src/handshake/message/server/keyExchange.js +1 -1
- package/lib/dtls/src/handshake/message/server/keyExchange.js.map +1 -1
- package/lib/dtls/src/handshake/random.d.ts +2 -2
- package/lib/dtls/src/handshake/random.js +2 -2
- package/lib/dtls/src/handshake/random.js.map +1 -1
- package/lib/dtls/src/imports/common.d.ts +1 -0
- package/lib/dtls/src/imports/common.js +1 -0
- package/lib/dtls/src/imports/common.js.map +1 -1
- package/lib/dtls/src/index.d.ts +2 -2
- package/lib/dtls/src/index.js +2 -2
- package/lib/dtls/src/index.js.map +1 -1
- package/lib/dtls/src/record/message/fragment.d.ts +1 -1
- package/lib/dtls/src/record/message/fragment.js +3 -3
- package/lib/dtls/src/record/message/fragment.js.map +1 -1
- package/lib/dtls/src/record/message/header.js +2 -2
- package/lib/dtls/src/record/message/header.js.map +1 -1
- package/lib/dtls/src/server.js +1 -1
- package/lib/dtls/src/server.js.map +1 -1
- package/lib/dtls/src/socket.d.ts +2 -2
- package/lib/dtls/src/socket.js +2 -2
- package/lib/dtls/src/socket.js.map +1 -1
- package/lib/ice/src/exceptions.d.ts +30 -0
- package/lib/ice/src/exceptions.js +43 -1
- package/lib/ice/src/exceptions.js.map +1 -1
- package/lib/ice/src/helper.d.ts +1 -1
- package/lib/ice/src/ice.d.ts +142 -0
- package/lib/ice/src/ice.js +809 -53
- package/lib/ice/src/ice.js.map +1 -1
- package/lib/ice/src/iceBase.d.ts +49 -0
- package/lib/ice/src/iceBase.js.map +1 -1
- package/lib/ice/src/index.d.ts +5 -5
- package/lib/ice/src/index.js +5 -5
- package/lib/ice/src/index.js.map +1 -1
- package/lib/ice/src/internal/resolveHostAddresses.d.ts +26 -0
- package/lib/ice/src/internal/resolveHostAddresses.js +45 -0
- package/lib/ice/src/internal/resolveHostAddresses.js.map +1 -0
- package/lib/ice/src/stun/protocol.d.ts +3 -1
- package/lib/ice/src/stun/protocol.js +16 -0
- package/lib/ice/src/stun/protocol.js.map +1 -1
- package/lib/ice/src/stun/tcpProtocol.d.ts +2 -0
- package/lib/ice/src/stun/tcpProtocol.js +16 -1
- package/lib/ice/src/stun/tcpProtocol.js.map +1 -1
- package/lib/ice/src/stun/transaction.d.ts +5 -0
- package/lib/ice/src/stun/transaction.js +7 -1
- package/lib/ice/src/stun/transaction.js.map +1 -1
- package/lib/ice/src/turn/protocol.d.ts +73 -4
- package/lib/ice/src/turn/protocol.js +241 -12
- package/lib/ice/src/turn/protocol.js.map +1 -1
- package/lib/ice/src/utils.js.map +1 -1
- package/lib/ice-server/src/stun/message.d.ts +5 -1
- package/lib/ice-server/src/stun/message.js +33 -2
- package/lib/ice-server/src/stun/message.js.map +1 -1
- package/lib/ice-server/src/turn/auth.d.ts +1 -1
- package/lib/index.mjs +24263 -16477
- package/lib/nonstandard/index.mjs +9272 -6178
- package/lib/polyfill/dom.mjs +24872 -20543
- package/lib/polyfill/index.mjs +24872 -20543
- package/lib/rtp/src/codec/av1.d.ts +61 -1
- package/lib/rtp/src/codec/av1.js +332 -33
- package/lib/rtp/src/codec/av1.js.map +1 -1
- package/lib/rtp/src/codec/base.d.ts +49 -1
- package/lib/rtp/src/codec/base.js +81 -1
- package/lib/rtp/src/codec/base.js.map +1 -1
- package/lib/rtp/src/codec/g711.d.ts +37 -0
- package/lib/rtp/src/codec/g711.js +109 -0
- package/lib/rtp/src/codec/g711.js.map +1 -0
- package/lib/rtp/src/codec/g722.d.ts +31 -0
- package/lib/rtp/src/codec/g722.js +82 -0
- package/lib/rtp/src/codec/g722.js.map +1 -0
- package/lib/rtp/src/codec/h264.d.ts +81 -7
- package/lib/rtp/src/codec/h264.js +382 -21
- package/lib/rtp/src/codec/h264.js.map +1 -1
- package/lib/rtp/src/codec/h265.d.ts +101 -0
- package/lib/rtp/src/codec/h265.js +615 -0
- package/lib/rtp/src/codec/h265.js.map +1 -0
- package/lib/rtp/src/codec/index.d.ts +6 -1
- package/lib/rtp/src/codec/index.js +25 -0
- package/lib/rtp/src/codec/index.js.map +1 -1
- package/lib/rtp/src/codec/mp4a.d.ts +88 -0
- package/lib/rtp/src/codec/mp4a.js +386 -0
- package/lib/rtp/src/codec/mp4a.js.map +1 -0
- package/lib/rtp/src/codec/opus.d.ts +14 -2
- package/lib/rtp/src/codec/opus.js +32 -2
- package/lib/rtp/src/codec/opus.js.map +1 -1
- package/lib/rtp/src/codec/telephoneEvent.d.ts +102 -0
- package/lib/rtp/src/codec/telephoneEvent.js +176 -0
- package/lib/rtp/src/codec/telephoneEvent.js.map +1 -0
- package/lib/rtp/src/codec/vp8.d.ts +26 -1
- package/lib/rtp/src/codec/vp8.js +76 -2
- package/lib/rtp/src/codec/vp8.js.map +1 -1
- package/lib/rtp/src/codec/vp9.d.ts +25 -1
- package/lib/rtp/src/codec/vp9.js +64 -2
- package/lib/rtp/src/codec/vp9.js.map +1 -1
- package/lib/rtp/src/const.d.ts +1 -0
- package/lib/rtp/src/const.js +5 -0
- package/lib/rtp/src/const.js.map +1 -0
- package/lib/rtp/src/extra/container/mp4/container.js +4 -1
- package/lib/rtp/src/extra/container/mp4/container.js.map +1 -1
- package/lib/rtp/src/extra/container/mp4/h264.d.ts +26 -0
- package/lib/rtp/src/extra/container/mp4/h264.js +54 -0
- package/lib/rtp/src/extra/container/mp4/h264.js.map +1 -1
- package/lib/rtp/src/extra/container/webm/container.d.ts +1 -1
- package/lib/rtp/src/extra/container/webm/ebml/ebml.d.ts +6 -0
- package/lib/rtp/src/extra/container/webm/ebml/ebml.js +20 -1
- package/lib/rtp/src/extra/container/webm/ebml/ebml.js.map +1 -1
- package/lib/rtp/src/extra/processor/depacketizer.d.ts +1 -1
- package/lib/rtp/src/extra/processor/depacketizer.js +1 -1
- package/lib/rtp/src/extra/processor/depacketizer.js.map +1 -1
- package/lib/rtp/src/extra/processor/depacketizerCallback.d.ts +1 -11
- package/lib/rtp/src/extra/processor/depacketizerTransformer.d.ts +1 -1
- package/lib/rtp/src/extra/processor/dtxCallback.d.ts +1 -11
- package/lib/rtp/src/extra/processor/interface.d.ts +16 -11
- package/lib/rtp/src/extra/processor/interface.js.map +1 -1
- package/lib/rtp/src/extra/processor/jitterBufferCallback.d.ts +1 -11
- package/lib/rtp/src/extra/processor/jitterBufferTransformer.d.ts +1 -1
- package/lib/rtp/src/extra/processor/mp4.d.ts +16 -0
- package/lib/rtp/src/extra/processor/mp4.js +55 -21
- package/lib/rtp/src/extra/processor/mp4.js.map +1 -1
- package/lib/rtp/src/extra/processor/nack.d.ts +1 -1
- package/lib/rtp/src/extra/processor/nack.js +1 -1
- package/lib/rtp/src/extra/processor/nack.js.map +1 -1
- package/lib/rtp/src/extra/processor/nackHandlerCallback.d.ts +1 -11
- package/lib/rtp/src/extra/processor/ntpTime.js.map +1 -1
- package/lib/rtp/src/extra/processor/ntpTimeCallback.d.ts +1 -11
- package/lib/rtp/src/extra/processor/rtcpCallback.d.ts +1 -1
- package/lib/rtp/src/extra/processor/rtcpCallback.js.map +1 -1
- package/lib/rtp/src/extra/processor/rtpCallback.d.ts +1 -1
- package/lib/rtp/src/extra/processor/rtpCallback.js +1 -1
- package/lib/rtp/src/extra/processor/rtpCallback.js.map +1 -1
- package/lib/rtp/src/extra/processor/rtpStream.d.ts +2 -2
- package/lib/rtp/src/extra/processor/rtpStream.js.map +1 -1
- package/lib/rtp/src/extra/processor/rtpTime.js.map +1 -1
- package/lib/rtp/src/extra/processor/rtpTimeCallback.d.ts +1 -11
- package/lib/rtp/src/extra/processor/webm.d.ts +27 -0
- package/lib/rtp/src/extra/processor/webm.js +43 -16
- package/lib/rtp/src/extra/processor/webm.js.map +1 -1
- package/lib/rtp/src/extra/processor/webmCallback.js +6 -1
- package/lib/rtp/src/extra/processor/webmCallback.js.map +1 -1
- package/lib/rtp/src/extra/processor/webmStream.js.map +1 -1
- package/lib/rtp/src/helper.d.ts +2 -2
- package/lib/rtp/src/helper.js +2 -6
- package/lib/rtp/src/helper.js.map +1 -1
- package/lib/rtp/src/index.d.ts +4 -2
- package/lib/rtp/src/index.js +4 -2
- package/lib/rtp/src/index.js.map +1 -1
- package/lib/rtp/src/rtcp/psfb/fullIntraRequest.js +2 -1
- package/lib/rtp/src/rtcp/psfb/fullIntraRequest.js.map +1 -1
- package/lib/rtp/src/rtcp/rtcp.js +2 -1
- package/lib/rtp/src/rtcp/rtcp.js.map +1 -1
- package/lib/rtp/src/rtcp/sr.d.ts +4 -3
- package/lib/rtp/src/rtcp/sr.js +3 -2
- package/lib/rtp/src/rtcp/sr.js.map +1 -1
- package/lib/rtp/src/rtp/mediaClock.d.ts +283 -0
- package/lib/rtp/src/rtp/mediaClock.js +655 -0
- package/lib/rtp/src/rtp/mediaClock.js.map +1 -0
- package/lib/rtp/src/srtp/cipher/ctr.d.ts +2 -2
- package/lib/rtp/src/srtp/cipher/ctr.js +1 -1
- package/lib/rtp/src/srtp/cipher/ctr.js.map +1 -1
- package/lib/rtp/src/srtp/cipher/gcm.d.ts +1 -1
- package/lib/rtp/src/srtp/cipher/gcm.js +1 -1
- package/lib/rtp/src/srtp/cipher/gcm.js.map +1 -1
- package/lib/rtp/src/srtp/context/context.d.ts +29 -1
- package/lib/rtp/src/srtp/context/context.js +78 -24
- package/lib/rtp/src/srtp/context/context.js.map +1 -1
- package/lib/rtp/src/srtp/context/srtp.js +23 -15
- package/lib/rtp/src/srtp/context/srtp.js.map +1 -1
- package/lib/rtp/src/util.d.ts +59 -6
- package/lib/rtp/src/util.js +88 -10
- package/lib/rtp/src/util.js.map +1 -1
- package/lib/sctp/src/index.d.ts +4 -3
- package/lib/sctp/src/index.js +10 -8
- package/lib/sctp/src/index.js.map +1 -1
- package/lib/sctp/src/sctp.d.ts +11 -2
- package/lib/sctp/src/sctp.js +47 -28
- package/lib/sctp/src/sctp.js.map +1 -1
- package/lib/webrtc/src/api/peerConfig.d.ts +264 -0
- package/lib/webrtc/src/api/peerConfig.js +250 -0
- package/lib/webrtc/src/api/peerConfig.js.map +1 -0
- package/lib/webrtc/src/api/peerConnectionEvents.d.ts +36 -0
- package/lib/webrtc/src/api/peerConnectionEvents.js +44 -0
- package/lib/webrtc/src/api/peerConnectionEvents.js.map +1 -0
- package/lib/webrtc/src/dataChannel.d.ts +1 -1
- package/lib/webrtc/src/dataChannel.js +1 -1
- package/lib/webrtc/src/dataChannel.js.map +1 -1
- package/lib/webrtc/src/index.d.ts +2 -2
- package/lib/webrtc/src/index.js +2 -2
- package/lib/webrtc/src/index.js.map +1 -1
- package/lib/webrtc/src/media/codec.d.ts +18 -0
- package/lib/webrtc/src/media/codec.js +43 -2
- package/lib/webrtc/src/media/codec.js.map +1 -1
- package/lib/webrtc/src/media/codecCompatibility.d.ts +5 -0
- package/lib/webrtc/src/media/codecCompatibility.js +15 -4
- package/lib/webrtc/src/media/codecCompatibility.js.map +1 -1
- package/lib/webrtc/src/media/index.d.ts +1 -1
- package/lib/webrtc/src/media/index.js +1 -1
- package/lib/webrtc/src/media/index.js.map +1 -1
- package/lib/webrtc/src/media/receiver/nack.js +3 -4
- package/lib/webrtc/src/media/receiver/nack.js.map +1 -1
- package/lib/webrtc/src/media/receiver/receiverTwcc.js.map +1 -1
- package/lib/webrtc/src/media/router.d.ts +116 -5
- package/lib/webrtc/src/media/router.js +281 -29
- package/lib/webrtc/src/media/router.js.map +1 -1
- package/lib/webrtc/src/media/rtpReceiver.d.ts +107 -12
- package/lib/webrtc/src/media/rtpReceiver.js +255 -28
- package/lib/webrtc/src/media/rtpReceiver.js.map +1 -1
- package/lib/webrtc/src/media/rtpSender.d.ts +56 -3
- package/lib/webrtc/src/media/rtpSender.js +180 -21
- package/lib/webrtc/src/media/rtpSender.js.map +1 -1
- package/lib/webrtc/src/media/rtpTransceiver.d.ts +94 -1
- package/lib/webrtc/src/media/rtpTransceiver.js +111 -2
- package/lib/webrtc/src/media/rtpTransceiver.js.map +1 -1
- package/lib/webrtc/src/media/sender/senderBWE.d.ts +2 -1
- package/lib/webrtc/src/media/sender/senderBWE.js +22 -10
- package/lib/webrtc/src/media/sender/senderBWE.js.map +1 -1
- package/lib/webrtc/src/media/track.d.ts +1 -1
- package/lib/webrtc/src/media/track.js +1 -1
- package/lib/webrtc/src/media/track.js.map +1 -1
- package/lib/webrtc/src/negotiation/bundleTopology.d.ts +107 -0
- package/lib/webrtc/src/negotiation/bundleTopology.js +380 -0
- package/lib/webrtc/src/negotiation/bundleTopology.js.map +1 -0
- package/lib/webrtc/src/negotiation/descriptionValidation.d.ts +51 -0
- package/lib/webrtc/src/negotiation/descriptionValidation.js +261 -0
- package/lib/webrtc/src/negotiation/descriptionValidation.js.map +1 -0
- package/lib/webrtc/src/negotiation/iceRestartRequest.d.ts +21 -0
- package/lib/webrtc/src/negotiation/iceRestartRequest.js +61 -0
- package/lib/webrtc/src/negotiation/iceRestartRequest.js.map +1 -0
- package/lib/webrtc/src/negotiation/internalState.d.ts +34 -0
- package/lib/webrtc/src/negotiation/internalState.js +21 -0
- package/lib/webrtc/src/negotiation/internalState.js.map +1 -0
- package/lib/webrtc/src/negotiation/negotiationNeeded.d.ts +44 -0
- package/lib/webrtc/src/negotiation/negotiationNeeded.js +118 -0
- package/lib/webrtc/src/negotiation/negotiationNeeded.js.map +1 -0
- package/lib/webrtc/src/negotiation/remoteCandidates.d.ts +86 -0
- package/lib/webrtc/src/negotiation/remoteCandidates.js +344 -0
- package/lib/webrtc/src/negotiation/remoteCandidates.js.map +1 -0
- package/lib/webrtc/src/negotiation/remoteMediaApplication.d.ts +71 -0
- package/lib/webrtc/src/negotiation/remoteMediaApplication.js +398 -0
- package/lib/webrtc/src/negotiation/remoteMediaApplication.js.map +1 -0
- package/lib/webrtc/src/negotiation/transportActivation.d.ts +59 -0
- package/lib/webrtc/src/negotiation/transportActivation.js +345 -0
- package/lib/webrtc/src/negotiation/transportActivation.js.map +1 -0
- package/lib/webrtc/src/negotiationTransaction.d.ts +233 -0
- package/lib/webrtc/src/negotiationTransaction.js +591 -0
- package/lib/webrtc/src/negotiationTransaction.js.map +1 -0
- package/lib/webrtc/src/nonstandard/dummyMedia.js +20 -6
- package/lib/webrtc/src/nonstandard/dummyMedia.js.map +1 -1
- package/lib/webrtc/src/nonstandard/index.d.ts +1 -1
- package/lib/webrtc/src/nonstandard/index.js +1 -1
- package/lib/webrtc/src/nonstandard/index.js.map +1 -1
- package/lib/webrtc/src/nonstandard/navigator.js.map +1 -1
- package/lib/webrtc/src/nonstandard/recorder/writer/index.d.ts +1 -1
- package/lib/webrtc/src/nonstandard/recorder/writer/index.js.map +1 -1
- package/lib/webrtc/src/nonstandard/recorder/writer/webm.d.ts +2 -2
- package/lib/webrtc/src/nonstandard/recorder/writer/webm.js +2 -2
- package/lib/webrtc/src/nonstandard/recorder/writer/webm.js.map +1 -1
- package/lib/webrtc/src/nonstandard/userMedia/packetizer.d.ts +4 -4
- package/lib/webrtc/src/nonstandard/userMedia/packetizer.js +61 -306
- package/lib/webrtc/src/nonstandard/userMedia/packetizer.js.map +1 -1
- package/lib/webrtc/src/nonstandard/userMedia.d.ts +4 -2
- package/lib/webrtc/src/nonstandard/userMedia.js +43 -9
- package/lib/webrtc/src/nonstandard/userMedia.js.map +1 -1
- package/lib/webrtc/src/peerConnection.d.ts +132 -237
- package/lib/webrtc/src/peerConnection.js +971 -906
- package/lib/webrtc/src/peerConnection.js.map +1 -1
- package/lib/webrtc/src/polyfill/api.d.ts +5 -5
- package/lib/webrtc/src/polyfill/api.js.map +1 -1
- package/lib/webrtc/src/polyfill/index.js.map +1 -1
- package/lib/webrtc/src/polyfill/install.js +1 -1
- package/lib/webrtc/src/polyfill/install.js.map +1 -1
- package/lib/webrtc/src/polyfill/mediaDevices.js.map +1 -1
- package/lib/webrtc/src/polyfill/registers/mp4Webm.js.map +1 -1
- package/lib/webrtc/src/polyfill/registers/rtpRtcp.js.map +1 -1
- package/lib/webrtc/src/polyfill/selectSettings.js.map +1 -1
- package/lib/webrtc/src/polyfill/sourceIo.js.map +1 -1
- package/lib/webrtc/src/sctpManager.d.ts +66 -2
- package/lib/webrtc/src/sctpManager.js +122 -5
- package/lib/webrtc/src/sctpManager.js.map +1 -1
- package/lib/webrtc/src/sdp.js.map +1 -1
- package/lib/webrtc/src/sdpManager.d.ts +55 -11
- package/lib/webrtc/src/sdpManager.js +367 -89
- package/lib/webrtc/src/sdpManager.js.map +1 -1
- package/lib/webrtc/src/secureTransportManager.d.ts +38 -25
- package/lib/webrtc/src/secureTransportManager.js +130 -34
- package/lib/webrtc/src/secureTransportManager.js.map +1 -1
- package/lib/webrtc/src/transceiverManager.d.ts +62 -18
- package/lib/webrtc/src/transceiverManager.js +266 -105
- package/lib/webrtc/src/transceiverManager.js.map +1 -1
- package/lib/webrtc/src/transport/dtls.d.ts +11 -2
- package/lib/webrtc/src/transport/dtls.js +37 -13
- package/lib/webrtc/src/transport/dtls.js.map +1 -1
- package/lib/webrtc/src/transport/ice.d.ts +254 -7
- package/lib/webrtc/src/transport/ice.js +608 -52
- package/lib/webrtc/src/transport/ice.js.map +1 -1
- package/lib/webrtc/src/transport/iceCandidateAttribute.d.ts +98 -0
- package/lib/webrtc/src/transport/iceCandidateAttribute.js +129 -0
- package/lib/webrtc/src/transport/iceCandidateAttribute.js.map +1 -0
- package/lib/webrtc/src/transport/sctp.d.ts +4 -1
- package/lib/webrtc/src/transport/sctp.js +83 -17
- package/lib/webrtc/src/transport/sctp.js.map +1 -1
- package/lib/webrtc/src/utils.d.ts +3 -3
- package/lib/webrtc/src/utils.js +1 -1
- package/lib/webrtc/src/utils.js.map +1 -1
- package/package.json +13 -14
package/lib/ice/src/ice.d.ts
CHANGED
|
@@ -17,18 +17,80 @@ export declare class Connection implements IceConnection {
|
|
|
17
17
|
turnServer?: Address;
|
|
18
18
|
options: IceOptions;
|
|
19
19
|
remoteCandidatesEnd: boolean;
|
|
20
|
+
/**
|
|
21
|
+
* End-of-candidates arrived while earlier candidates were still resolving
|
|
22
|
+
* (mDNS). No candidate is accepted any more; `remoteCandidatesEnd` follows
|
|
23
|
+
* once those resolutions settle.
|
|
24
|
+
*/
|
|
25
|
+
private remoteCandidatesEndRequested;
|
|
26
|
+
/** mDNS resolutions of remote candidates that arrived before end-of-candidates. */
|
|
27
|
+
private readonly remoteResolutions;
|
|
20
28
|
localCandidatesEnd: boolean;
|
|
29
|
+
/** connect() began this generation's checks (their outcome sets the state). */
|
|
30
|
+
private checksBegun;
|
|
21
31
|
generation: number;
|
|
32
|
+
/**
|
|
33
|
+
* Counts every reset of the remote generation: a local ICE restart and a
|
|
34
|
+
* remote-only one. Remote-side work (a candidate's mDNS lookup, the wait
|
|
35
|
+
* for end-of-candidates, consent, a nomination in flight) belongs to the
|
|
36
|
+
* value it started with. A remote-only restart leaves `generation` (the
|
|
37
|
+
* local gathering's) alone.
|
|
38
|
+
*/
|
|
39
|
+
private remoteGeneration;
|
|
40
|
+
/**
|
|
41
|
+
* Local credentials STUN requests may use, by ufrag: the current ones, the
|
|
42
|
+
* generation the last restart replaced and a staged (provisional) one.
|
|
43
|
+
*/
|
|
22
44
|
userHistory: {
|
|
23
45
|
[username: string]: string;
|
|
24
46
|
};
|
|
47
|
+
/** restart() ran once (the constructor's first generation exists). */
|
|
48
|
+
private restarted;
|
|
25
49
|
private readonly tieBreaker;
|
|
26
50
|
state: IceState;
|
|
27
51
|
lookup?: MdnsLookup;
|
|
28
52
|
private _remoteCandidates;
|
|
29
53
|
nominated?: CandidatePair;
|
|
30
54
|
private nominating;
|
|
55
|
+
/**
|
|
56
|
+
* Aborted when the remote generation ends (restart, restartRemote, close):
|
|
57
|
+
* every check and nomination transaction of that generation stops with it.
|
|
58
|
+
*
|
|
59
|
+
* Every STUN request of the agent and what cancels it (a late result of an
|
|
60
|
+
* ended generation changes no state of the generation that replaced it):
|
|
61
|
+
* - `checkStart` (live check): its handle (`pair.handle`: checklist
|
|
62
|
+
* completed, replaced, other remote ufrag dropped) and this signal; an
|
|
63
|
+
* aborted check changes nothing.
|
|
64
|
+
* - `retryCheck` (487 role conflict / 401 retry): the handle of the check
|
|
65
|
+
* it replaces and this signal (the retry is a `checkStart`).
|
|
66
|
+
* - regular nomination in `checkStart` (toward an ICE-lite peer): the
|
|
67
|
+
* check's signal; `isStaleNomination` guards `nominating`, the pair state
|
|
68
|
+
* and `checkComplete`.
|
|
69
|
+
* - `nominateTcpPair`: this signal; `isStaleNomination`.
|
|
70
|
+
* - `checkProvisional` / `nominateProvisional`: `generation.checks`
|
|
71
|
+
* (`endProvisional()`, a replacement pranswer, close); `belongs()`.
|
|
72
|
+
* - `queryConsent`: a per-request `AbortController` and
|
|
73
|
+
* `stopConsentLifecycle()`; `consentSessionId`.
|
|
74
|
+
* - `serverReflexiveCandidate` (gathering): `protocol.close()`; otherwise
|
|
75
|
+
* it ends by its retransmission timeout, and `stale()` drops the
|
|
76
|
+
* candidate of an ended gather.
|
|
77
|
+
* - TURN client requests: the `closing` signal and `TurnProtocol.close()`.
|
|
78
|
+
* Regression tests: `tests/ice/check-cancel.test.ts`.
|
|
79
|
+
*/
|
|
80
|
+
private remoteChecks;
|
|
31
81
|
private checkListDone;
|
|
82
|
+
/** Resolves when the agent closes: work that awaits the network stops waiting. */
|
|
83
|
+
private readonly closedSignal;
|
|
84
|
+
private signalClosed;
|
|
85
|
+
/** Aborted by close(): a TURN allocation still running is released. */
|
|
86
|
+
private readonly closing;
|
|
87
|
+
/**
|
|
88
|
+
* Results for connect(). Known constraint (as in develop): a restart
|
|
89
|
+
* replaces the queue, so a connect() still waiting on the old one never
|
|
90
|
+
* settles (the agent is still collected). It cannot simply return, since
|
|
91
|
+
* the caller (webrtc's `TransactionActivation`) treats a returned start as
|
|
92
|
+
* a connected ICE transport.
|
|
93
|
+
*/
|
|
32
94
|
private checkListState;
|
|
33
95
|
private earlyChecks;
|
|
34
96
|
private earlyChecksDone;
|
|
@@ -41,6 +103,10 @@ export declare class Connection implements IceConnection {
|
|
|
41
103
|
private consentSessionId;
|
|
42
104
|
private consentExpiryTimer?;
|
|
43
105
|
private consentRequestAbort?;
|
|
106
|
+
/** ICE restart generation checked beside the selected current pair. */
|
|
107
|
+
private provisional?;
|
|
108
|
+
/** Last server-reflexive candidate each UDP socket advertised. */
|
|
109
|
+
private readonly reflexiveBySocket;
|
|
44
110
|
readonly onData: Event<[Buffer<ArrayBufferLike>]>;
|
|
45
111
|
readonly stateChanged: Event<[IceState]>;
|
|
46
112
|
readonly onIceCandidate: Event<[Candidate]>;
|
|
@@ -65,13 +131,72 @@ export declare class Connection implements IceConnection {
|
|
|
65
131
|
set iceControlling(value: boolean);
|
|
66
132
|
get iceLite(): boolean;
|
|
67
133
|
restart(): Promise<void>;
|
|
134
|
+
/**
|
|
135
|
+
* Only the remote side restarted (new remote credentials in an answer to an
|
|
136
|
+
* offer that kept the local ones): the remote generation, its checks and
|
|
137
|
+
* the selected pair start over; local credentials and candidates stay.
|
|
138
|
+
*/
|
|
139
|
+
restartRemote(): void;
|
|
140
|
+
/**
|
|
141
|
+
* Stop the checks and nominations in flight for the checklist a restart
|
|
142
|
+
* replaces (or close ends), and start a signal for the next generation.
|
|
143
|
+
*/
|
|
144
|
+
private cancelChecks;
|
|
145
|
+
/**
|
|
146
|
+
* Drop the provisional generation and stop the checks still in flight for
|
|
147
|
+
* it (their retransmissions would outlive it).
|
|
148
|
+
*/
|
|
149
|
+
private endProvisional;
|
|
150
|
+
/** Accept provisional checks without changing the selected current pair. */
|
|
151
|
+
stageLocalCredentials(usernameFragment: string, password: string): void;
|
|
152
|
+
discardStagedLocalCredentials(usernameFragment: string): void;
|
|
153
|
+
/** Remote credentials of the provisional generation (pranswer). */
|
|
154
|
+
setProvisionalRemoteParams({ usernameFragment, password, }: {
|
|
155
|
+
usernameFragment: string;
|
|
156
|
+
password: string;
|
|
157
|
+
}): void;
|
|
158
|
+
addProvisionalRemoteCandidate(remoteCandidate: Candidate | undefined): Promise<void>;
|
|
159
|
+
/** Start checks for the provisional generation; the selected pair is kept. */
|
|
160
|
+
startProvisionalChecks(): void;
|
|
161
|
+
get provisionalNominated(): CandidatePair | undefined;
|
|
162
|
+
private tryProvisionalPair;
|
|
163
|
+
private checkProvisional;
|
|
164
|
+
private nominateProvisional;
|
|
165
|
+
/** Incoming check for the provisional ufrag; never touches the current checklist. */
|
|
166
|
+
private checkIncomingProvisional;
|
|
167
|
+
/** Called after restart, before re-gathering the chosen generation. */
|
|
168
|
+
commitLocalCredentials(usernameFragment: string, password: string): void;
|
|
169
|
+
/**
|
|
170
|
+
* Drop the remote candidates (and their pairs) that name a ufrag other than
|
|
171
|
+
* `usernameFragment`: they belong to another remote generation and cannot
|
|
172
|
+
* pass checks with its credentials. Candidates without a ufrag stay.
|
|
173
|
+
*/
|
|
174
|
+
dropOtherRemoteGenerations(usernameFragment: string): void;
|
|
68
175
|
resetNominatedPair(): void;
|
|
69
176
|
setRemoteParams({ iceLite, usernameFragment, password, }: {
|
|
70
177
|
iceLite: boolean;
|
|
71
178
|
usernameFragment: string;
|
|
72
179
|
password: string;
|
|
73
180
|
}): void;
|
|
181
|
+
/**
|
|
182
|
+
* Gather the local candidates of the current generation.
|
|
183
|
+
*
|
|
184
|
+
* After an ICE restart everything the kept sockets already advertised is
|
|
185
|
+
* advertised again synchronously, before this method first awaits: the host
|
|
186
|
+
* candidates and the server-reflexive address each kept socket had. Only
|
|
187
|
+
* work that needs a server follows (a fresh STUN query, a new TURN
|
|
188
|
+
* allocation), so a caller may let it finish in the background.
|
|
189
|
+
*/
|
|
74
190
|
gatherCandidates(): Promise<void>;
|
|
191
|
+
/**
|
|
192
|
+
* Whether gathering started for `generation` still belongs to the agent:
|
|
193
|
+
* no ICE restart replaced the generation and the agent is not closed.
|
|
194
|
+
*/
|
|
195
|
+
private isGathering;
|
|
196
|
+
/** A copy of `candidate` labelled with the current generation and ufrag. */
|
|
197
|
+
private withGeneration;
|
|
198
|
+
/** Whether gathering contacts a STUN or TURN server (more than re-advertising sockets). */
|
|
199
|
+
get gathersFromServers(): boolean;
|
|
75
200
|
private appendLocalCandidate;
|
|
76
201
|
private ensureProtocol;
|
|
77
202
|
/**
|
|
@@ -100,6 +225,14 @@ export declare class Connection implements IceConnection {
|
|
|
100
225
|
private queryConsent;
|
|
101
226
|
close(): Promise<void>;
|
|
102
227
|
private setState;
|
|
228
|
+
/**
|
|
229
|
+
* Known constraint (as in develop): candidates are not deduplicated. A
|
|
230
|
+
* description applied again in the same generation (BUNDLE split and
|
|
231
|
+
* merge after an ICE restart) adds its candidates and pairs a second time,
|
|
232
|
+
* until the next restart. Deduplicating here alone breaks the pairs a
|
|
233
|
+
* provisional generation dropped and the repeated add rebuilds; a fix needs
|
|
234
|
+
* the pairing and provisional lifecycle together.
|
|
235
|
+
*/
|
|
103
236
|
addRemoteCandidate(remoteCandidate: Candidate | undefined): Promise<void>;
|
|
104
237
|
send: (data: Buffer) => Promise<void>;
|
|
105
238
|
getDefaultCandidate(): Candidate;
|
|
@@ -116,6 +249,11 @@ export declare class Connection implements IceConnection {
|
|
|
116
249
|
resolve: (value: void | PromiseLike<void>) => void;
|
|
117
250
|
reject: (reason?: any) => void;
|
|
118
251
|
};
|
|
252
|
+
/**
|
|
253
|
+
* 487 / 401 retry of a check: the retry is cancelled with the check it
|
|
254
|
+
* replaces (its handle) and, through checkStart, with the generation.
|
|
255
|
+
*/
|
|
256
|
+
private retryCheck;
|
|
119
257
|
private isTcpPair;
|
|
120
258
|
/**
|
|
121
259
|
* Aggressive nomination lets each side settle on whichever TCP connection
|
|
@@ -137,6 +275,10 @@ export declare class Connection implements IceConnection {
|
|
|
137
275
|
private addPair;
|
|
138
276
|
checkIncoming(message: Message, addr: Address, protocol: Protocol): void;
|
|
139
277
|
private tryPair;
|
|
278
|
+
/**
|
|
279
|
+
* Pair a local candidate gathered after remote candidates arrived (a late
|
|
280
|
+
* TURN allocation, a slow host socket) with them.
|
|
281
|
+
*/
|
|
140
282
|
private pairLocalProtocol;
|
|
141
283
|
private pairRemoteCandidate;
|
|
142
284
|
private buildRequest;
|