{"id":15635978,"url":"https://github.com/passy/hls-proxy","last_synced_at":"2025-04-30T05:22:42.068Z","repository":{"id":66088508,"uuid":"56804264","full_name":"passy/hls-proxy","owner":"passy","description":"A reverse HTTP proxy that may eventually do things","archived":false,"fork":false,"pushed_at":"2016-07-10T13:46:32.000Z","size":49,"stargazers_count":6,"open_issues_count":0,"forks_count":2,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-03-30T13:04:16.864Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Haskell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/passy.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2016-04-21T20:39:42.000Z","updated_at":"2022-07-14T19:10:55.000Z","dependencies_parsed_at":"2023-02-23T06:30:26.189Z","dependency_job_id":null,"html_url":"https://github.com/passy/hls-proxy","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/passy%2Fhls-proxy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/passy%2Fhls-proxy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/passy%2Fhls-proxy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/passy%2Fhls-proxy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/passy","download_url":"https://codeload.github.com/passy/hls-proxy/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251645989,"owners_count":21620848,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-03T11:01:31.196Z","updated_at":"2025-04-30T05:22:42.043Z","avatar_url":"https://github.com/passy.png","language":"Haskell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# hls-proxy [![Build Status](https://travis-ci.org/passy/hls-proxy.svg?branch=master)](https://travis-ci.org/passy/hls-proxy)\n\n\u003e A tool that if you're lucky you'll never need.\n\nA collection of various unportable hacks to transform HLS streams for debugging\npurposes. This is highly tailored towards the sort of setup I'm working with\nright now, so it will almost certainly not work out-of-the-box for you.\n\n## Setup (mitmproxy)\n\n`mitmproxy` is great! Getting TLS to run your device is actually surprisingly\neasy. I'll assume here that you're setting up an Android device.\n\n- Install [mitmproxy](https://mitmproxy.org/). They've got packages for pretty\n  much everything.\n- Set your device's HTTP proxy to your local machine's IP address, port 8888.\n- Run `mitmproxy` bare-bones in the same WiFi as your device:\n`mitmproxy -b 0.0.0.0 -p 8888`.\n- Go to [mitm.it](http://mitm.it) and install the TLS CA certificate.\n- I haven't changed the `mitm_redirect.py` script to take parameters, so you may\n  need to update it to match your host settings.\n- Run `mitmproxy` again, this time in script mode to redirect all requests to\n  the target host to `hls_proxy` instead:\n  `mitmproxy -s mitm_redirect.py -b 0.0.0.0 -p 8888`.\n\n## Setup (Charles)\n\nCharles is way more painful to setup, but to each their own. I'll assume here\nthat you're setting up an Android device.\n\n- Get [Charles](https://www.charlesproxy.com/) set up on your machine.\n- Make sure your on the same WiFi as your phone.\n- Install and trust the Charles TLS certificate. The recommended way of\n  installing it through http://charlesproxy.com/getssl didn't work. I had to\n  download it on a laptop, adb-push it to the device and manually install it\n  there. YMMV.\n- Enable SSL proxying in Charles (I think it's the default, but better\n  double-check).\n- Build this tool (see below) and start it on, let's say port 8080:\n  `hls-proxy -- -p 8080 my-cdn.com`\n- Set up a remote port mapping in Charles, by going to `Tools -\u003e Map Remote` and\n  set up a rule proxying to your local reverse proxy, e.g.\n  \"From: https://my-cdn.com:443/ -\u003e http://localhost:8080\"\n\nNow use your app, device or whatever and start a stream. You should see the\naccess log on stdout. If not, something went wrong with your Charles setup. Back\nto StackOverflow, sorry.\n\n## Building\n\nThis tool is built with [stack](http://haskellstack.org).\n\n```bash\ngit clone https://github.com/passy/hls-proxy\ncd hls-proxy\nstack setup\nstack build\nstack exec hls-proxy -- --help\n```\n\n## License\n\nBSD-3\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpassy%2Fhls-proxy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpassy%2Fhls-proxy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpassy%2Fhls-proxy/lists"}