{"id":13787945,"url":"https://github.com/trichimtrich/turnproxy","last_synced_at":"2025-05-12T02:30:48.218Z","repository":{"id":53348586,"uuid":"255175152","full_name":"trichimtrich/turnproxy","owner":"trichimtrich","description":"turn server - into something you can - see - through 🏙","archived":false,"fork":false,"pushed_at":"2020-04-13T04:05:42.000Z","size":125,"stargazers_count":23,"open_issues_count":2,"forks_count":6,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-05-13T22:12:47.701Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/trichimtrich.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}},"created_at":"2020-04-12T21:40:44.000Z","updated_at":"2024-01-19T10:27:13.000Z","dependencies_parsed_at":"2022-09-11T06:51:52.861Z","dependency_job_id":null,"html_url":"https://github.com/trichimtrich/turnproxy","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/trichimtrich%2Fturnproxy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/trichimtrich%2Fturnproxy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/trichimtrich%2Fturnproxy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/trichimtrich%2Fturnproxy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/trichimtrich","download_url":"https://codeload.github.com/trichimtrich/turnproxy/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253662556,"owners_count":21944094,"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-08-03T21:00:33.622Z","updated_at":"2025-05-12T02:30:47.922Z","avatar_url":"https://github.com/trichimtrich.png","language":"Python","funding_links":[],"categories":["Open-source tools"],"sub_categories":[],"readme":"# turnproxy\n\n[![Python 3](https://img.shields.io/badge/python-3-blue.svg)](https://www.python.org/downloads/)\n[![MIT License](https://img.shields.io/badge/license-MIT-green)](https://github.com/trichimtrich/turnproxy/blob/master/LICENSE)\n\n\u003e `turn` ~server~ into something you can `see` through\n\na small script that\n\n- tests TCP connectivity between your turn-server and any peer-destination\n- uses your turn-server as TCP proxy with SOCKS interface\n\n## usage\n\n```\n➜ python turnproxy.py --help\nusage: turnproxy command\n\ntest your turn-server tcp relay and use it as a proxy with socks interface\n\noptional arguments:\n  -h, --help  show this help message and exit\n\ncommand:\n\n    test      ask turn server to create a tcp connection to your peer host\n    run       run a socks proxy via your turn server\n```\n\n- test connection to good peer `8.8.8.8:53`\n\n```\n➜ python turnproxy.py test -t \u003cturn_host\u003e:\u003cturn_port\u003e -u username -p password -c 8.8.8.8:53\nTurn server == \u003cturn_host\u003e:\u003cturn_port\u003e\nConnecting to peer --\u003e 8.8.8.8:53\nConnection OK\n```\n\n- test connection to bad peer `8.8.8.8:54`\n\n```\n➜ python turnproxy.py test -t \u003cturn_host\u003e:\u003cturn_port\u003e -u username -p password -c 8.8.8.8:54\nTurn server == \u003cturn_host\u003e:\u003cturn_port\u003e\nConnecting to peer --\u003e 8.8.8.8:53\nError 447: b'Connection Timeout or Failure\\x00\\x00\\x00'\n```\n\n- listen on `127.0.0.1:9999` as SOCKS proxy\n\n```\n➜ python turnproxy.py run -t \u003cturn_host\u003e:\u003cturn_port\u003e -u username -p password -s 127.0.0.1:9999\nTurn server == \u003cturn_host\u003e:\u003cturn_port\u003e\nSocks server listening \u003c-- 127.0.0.1:9999\n127.0.0.1:2330 - Connected\n127.0.0.1:2330 - SOCKS established\n127.0.0.1:2330 - Client disconnected\n127.0.0.1:2335 - Connected\n...\n```\n\n- config socks proxy for your `http`, `ssh`, `redis`, `mysql`, ... clients and enjoy 😉\n\n- enable flag `-d` or `--debug` if you are curious\n\n## docs\n\nthis work is heavily inspired from the awesome disclosure below\n\n- https://www.rtcsec.com/2020/04/01-slack-webrtc-turn-compromise/\n\n## qa\n\nwhat is `turn` ?\n\n- https://tools.ietf.org/html/rfc5766\n\nthen, what is `stun` ?\n\n- https://tools.ietf.org/html/rfc5389\n- https://tools.ietf.org/html/rfc3489\n\nwhere they are used ?\n\n- https://webrtc.org/\n- https://en.wikipedia.org/wiki/Session_Initiation_Protocol\n\ni mean where?\n\n- http://messenger.com/\n- https://discordapp.com/\n- https://slack.com/\n- http://cloudretro.io/\n\nthats too much info, i just want to test this script\n\n- https://meetrix.io/blog/webrtc/coturn/installation.html","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftrichimtrich%2Fturnproxy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftrichimtrich%2Fturnproxy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftrichimtrich%2Fturnproxy/lists"}