hyesung913 cb16f68432 rtmp: improve control message compatibility with non-standard cameras (#4909)
* feat: improve RTMP control message compatibility with non-standard cameras

- Add flexible chunk stream ID validation for control messages
- Support common non-standard chunk stream IDs (2,3,4,5,6) used by various cameras
- Maintain backward compatibility with standard RTMP clients
- Fix connection issues with PTZ cameras using chunk stream ID 4

This resolves compatibility issues with IP cameras that don't strictly follow
RTMP spec while maintaining full support for standard RTMP implementations.
Previously, cameras using non-standard chunk stream IDs would fail with
'unexpected chunk stream ID' errors. Now MediaMTX provides nginx-rtmp level
compatibility with real-world camera implementations."

* add tests

* entirely remove control chunk stream ID validation

---------

Co-authored-by: Hyesung.Kim <hyesung.kim@xcath.com>
Co-authored-by: aler9 <46489434+aler9@users.noreply.github.com>
2025-09-03 15:11:32 +02:00
2025-08-31 16:57:27 +02:00
2025-09-02 10:39:11 +02:00
2025-08-09 16:05:34 +02:00
2025-08-09 16:05:34 +02:00
2025-07-26 16:44:32 +02:00
2023-07-02 14:03:53 +02:00
2023-05-16 16:14:20 +02:00
2025-09-02 10:39:11 +02:00
2025-08-31 16:57:27 +02:00

MediaMTX

Website Test Lint CodeCov Release Docker Hub


MediaMTX is a ready-to-use and zero-dependency real-time media server and media proxy that allows to publish, read, proxy, record and playback video and audio streams. It has been conceived as a "media router" that routes media streams from one end to the other.

Features

  • Publish live streams to the server with SRT, WebRTC, RTSP, RTMP, HLS, MPEG-TS, RTP
  • Read live streams from the server with SRT, WebRTC, RTSP, RTMP, HLS
  • Streams are automatically converted from a protocol to another
  • Serve several streams at once in separate paths
  • Record streams to disk in fMP4 or MPEG-TS format
  • Playback recorded streams
  • Authenticate users with internal, HTTP or JWT authentication
  • Forward streams to other servers
  • Proxy requests to other servers
  • Control the server through the Control API
  • Reload the configuration without disconnecting existing clients (hot reloading)
  • Monitor the server through Prometheus-compatible metrics
  • Run hooks (external commands) when clients connect, disconnect, read or publish streams
  • Compatible with Linux, Windows and macOS, does not require any dependency or interpreter, it's a single executable
  • ...and many others.
Description
No description provided
Readme MIT 217 MiB
Languages
Go 95.3%
JavaScript 2.2%
HTML 1.4%
Makefile 0.5%
Dockerfile 0.4%
Other 0.2%