constants.go 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. // SPDX-FileCopyrightText: 2023 The Pion community <https://pion.ly>
  2. // SPDX-License-Identifier: MIT
  3. package webrtc
  4. import "github.com/pion/dtls/v2"
  5. const (
  6. // Unknown defines default public constant to use for "enum" like struct
  7. // comparisons when no value was defined.
  8. Unknown = iota
  9. unknownStr = "unknown"
  10. // Equal to UDP MTU
  11. receiveMTU = 1460
  12. // simulcastProbeCount is the amount of RTP Packets
  13. // that handleUndeclaredSSRC will read and try to dispatch from
  14. // mid and rid values
  15. simulcastProbeCount = 10
  16. // simulcastMaxProbeRoutines is how many active routines can be used to probe
  17. // If the total amount of incoming SSRCes exceeds this new requests will be ignored
  18. simulcastMaxProbeRoutines = 25
  19. mediaSectionApplication = "application"
  20. sdpAttributeRid = "rid"
  21. sdpAttributeSimulcast = "simulcast"
  22. rtpOutboundMTU = 1200
  23. rtpPayloadTypeBitmask = 0x7F
  24. incomingUnhandledRTPSsrc = "Incoming unhandled RTP ssrc(%d), OnTrack will not be fired. %v"
  25. generatedCertificateOrigin = "WebRTC"
  26. sdesRepairRTPStreamIDURI = "urn:ietf:params:rtp-hdrext:sdes:repaired-rtp-stream-id"
  27. )
  28. func defaultSrtpProtectionProfiles() []dtls.SRTPProtectionProfile {
  29. return []dtls.SRTPProtectionProfile{dtls.SRTP_AEAD_AES_256_GCM, dtls.SRTP_AEAD_AES_128_GCM, dtls.SRTP_AES128_CM_HMAC_SHA1_80}
  30. }