Hi, I'm trying to record the Mega Channel's Greek stream
https://www.megatv.com/live/
from the network log, it loads a placeholder 1 second video
and then after about 5 seconds, it loads a player from embed.vindral.com which isn't some known m3u/mpd stream, it's something like thisCode:https://streamcdnh4-0df53bbc22ae482295dbcf7370989099.msvdn.net/vod/JCAyrKr2UqYk/original.mp4
and then the last thing on the log is a "wss" URL like this that seems to contain an AV1 videoCode:https://lb.cdn.vindral.com/api/v2/connect/?channelId=alteregomedia_megatv1_ci_6cc490c7-e5c6-486b-acf0-9bb9c20fa670
Does anyone know what's this? If it's supported by the usual ffmpeg/N_m3u8DL-RE somehow?Code:wss://ume3-node-07.cdn.vindral.com/subscribe?channelId=alteregomedia_megatv1_ci_6cc490c7-e5c6-486b-acf0-9bb9c20fa670&sessionId=REDACTED&clientId=REDACTED&audio.bitRate=128000&audio.codec=aac&video.width=1280&video.height=720&video.bitRate=2200000&video.codec=av1&burstMs=2000
Support our site by donate $5 directly to us Thanks!!!
Try StreamFab Downloader and download streaming video from Netflix, Amazon!
Try StreamFab Downloader and download streaming video from Netflix, Amazon!
+ Reply to Thread
Results 1 to 8 of 8
-
-
WSS would mean WebSocket in this case. I've never seen it used in this way, usually it's used to open a channel for things like a webchat, where your browser 'subscribes' to new messages or status updates and sends its own messages through that same channel. In this case, it's the audio and video content that flows to the browser once the channel is opened and the link is established.
Which is why I don't think tyou will have much luck with the usual software that you mention as the model of communicating is quite different conpared to requesting a playlist, receiving links to packages of audio and video and doing that in a loop. Apparently, not even VLC supports this. -
Took me a while, but this will record AV1 and AAC data and write them to files live (don't select h264 streams, didn't get them to work):
Code:import json import struct import threading import time import websocket if __name__ == '__main__': def parse_rendition_data(data): payload_offset = struct.unpack('>H', data[1:3])[0] flags = data[3] rendition_id = data[4] payload = data[payload_offset:] return { 'renditionId': rendition_id, 'flags': flags, 'payload': payload } def generate_adts_header(frame_length): # Settings: # + MPEG-4 # + No CRC # + AAC Low Complexity # + 2 Channels # + 48000 Hz # + 1 Frame/ADTS header adts_header = bytearray([ 0b11111111, 0b11110001, 0b01001100, (0b10000000 | ((frame_length >> 11) & 0b00000011)), (frame_length >> 3) & 0xFF, ((frame_length & 0b111) << 5) | 0b00011111, 0b11111100 ]) return adts_header def on_message(ws, message): if isinstance(message, str): print(">", message) else: message_data = parse_rendition_data(message) payload = message_data["payload"] if message_data["flags"] & 0x08 == 0 and message_data["flags"] & 0x04 == 0: if not (message_data["flags"] & 0x02): if message_data["renditionId"] == 10: with open("y_video.mp4", "ab") as f: f.write(payload) elif message_data["renditionId"] == 1: with open("y_audio.aac", "ab") as f: f.write(generate_adts_header(len(payload) + 7)) f.write(payload) def on_open(ws): print("[Opened connection]") def on_error(ws, error): print(f"[ERROR: {error}]") exit() def on_close(ws, close_status_code, close_msg): print(f"[Closed connection: Code: {close_status_code}, Reason: {close_msg}]") def heartbeat(ws): while True: time.sleep(5) ping_message = json.dumps({ "type": "ping" }) print("<", ping_message) ws.send(ping_message.encode()) WSS_URL = "wss://ume3-edge-01.cdn.vindral.com/subscribe?channelId=alteregomedia_megatv1_ci_6cc490c7-e5c6-486b-acf0-9bb9c20fa670&sessionId=ece2f6d2-b264-48c6-a3fe-2a0f3265b8df&clientId=36e4a9f8-8f57-40c0-92f4-0eadc9caaed2&audio.bitRate=128000&audio.codec=aac&video.width=1280&video.height=720&video.bitRate=2200000&video.codec=av1&burstMs=2000" ws = websocket.WebSocketApp( WSS_URL, on_message=on_message, on_open=on_open, on_error=on_error, on_close=on_close ) thread = threading.Thread(target=heartbeat, args=(ws,)) thread.daemon = True thread.start() ws.run_forever()
Bypass HMACs, One-time-tokens and Lic.Wrapping: https://github.com/DevLARLEY/WidevineProxy2 -
That's a re-stream that will probably get down, Mega has shut down its direct m3u stream before with a message on the video stream as an overlay covering the whole video about unofficial re-streams before they took it down
That's great, thanks a ton! It surprises me that there hasn't been a stream like this before. Do you know if it would be possible for it to be piped to mpv or VLC to play directly? Or it would probably require the players to support the protocol?Last edited by Hackerpcs; 25th Mar 2025 at 20:27.
-
You can just open the file with mpv as soon as it is created. What I haven't figured out yet is how to mux both 'raw' aac audio and this av1 stuff.
Bypass HMACs, One-time-tokens and Lic.Wrapping: https://github.com/DevLARLEY/WidevineProxy2 -
I mean live. I need to merge ~5-10 10-50kb chunks of audio/video into an mkv file while it's running while being in sync
Bypass HMACs, One-time-tokens and Lic.Wrapping: https://github.com/DevLARLEY/WidevineProxy2
Similar Threads
-
"code":400,"error":true,"message" on http://getwvkeys.cc
By johnsonkiss in forum Video Streaming DownloadingReplies: 14Last Post: 25th Jul 2024, 21:45 -
getwvkeys.cc code":400,"error":true,"message":"Failed to get license: 405
By Koldunas in forum Newbie / General discussionsReplies: 0Last Post: 27th Sep 2023, 02:44 -
{"code": 2048, "message": "Authentication failed"} when getting license
By warmachine in forum Video Streaming DownloadingReplies: 2Last Post: 26th May 2023, 16:34 -
How to change "m3u8" to "json" and "ts" to "js" extension
By wowza in forum Newbie / General discussionsReplies: 6Last Post: 4th Mar 2023, 15:36 -
VirtualDub: "AVI Import Filter error: (Unknown) 80040154"
By Xavier in forum Newbie / General discussionsReplies: 11Last Post: 15th Dec 2021, 17:49