Review Teamspeak3 Proxy

maxst

Member
Dec 15, 2015
22
6
35
Dear Community,

I invested some time to create a python3 based transparent teamspeak3 proxy. Main Idea was to hide the original teamspeak3 server somewhere and have different gateways to access the server instead of accessing the teamspeak3 server directly. You can also install the ts3proxy to a server of your choice and connect to any teamspeak3 server you want to hide your real client IP. You can even give your friends access to your proxy so that they can hide their real IP address to a specific ts3 server, too.

If you have new ideas / suggestions / problems please dont hesitate to fill in an issue or pull request on github. License is GNU GPL3.

For installation and Source Code visit:
https://github.com/Kandru/ts3proxy

FAQ
  • I get an error with "no module named 'yaml'" -> install python3-yaml
  • listen() takes exactly one argument (0 given) -> use python3.6, not python2!
  • How to see your python version: "python --version" or "python3 --version"
If you got the time, please:
  • try this tool and post how it worked for you
  • CPU and memory consumption
  • stability
  • suggestions or new feature wishes?

Explained for the 5yo 1nject:
With this tool you can easily hide your origin teamspeak3 server. This is quite useful if you want to "protect" your real teamspeak server and/or teamspeak client IP. The teamspeak3 server only see client connections from this tool, the client only see the tool and thinks that this is the server.

Even easier:
Teamspeak3 Client <-> MY TOOL <-> Teamspeak3 Server
Client IP <-> Server1 IP (with my tool running on it) <-> Server2 IP (with TS3 Server running on it)

It's just a proxy like every other proxy (e.g. web proxy).
 
Last edited:

Shield

Member
Dec 8, 2015
125
14
53
Tried to explain it for you <3 (see first post).
how to setup and run this? step by step please? when run this script got error


root@ubuntu:/home# ./ts3proxy.py
Traceback (most recent call last):
File "./ts3proxy.py", line 5, in <module>
import yaml
ImportError: No module named 'yaml'
 

maxst

Member
Dec 15, 2015
22
6
35
Hey Shield,
you're missing the python3 module "yaml". To install it via ubuntu just type:
apt-get install python3-yaml
and you should be fine :)
One more recommendation: do not run the proxy as root in productivity. That's a security risk and really not neccessary ;) - Installation is superb simple. Just extract the latest version from github on a server of your choice, install python3 (with yaml module) and start the ts3proxy.py file. Change the config entries to fit your needs.
One hint:
Even if you can change the server query / file transfer port on both ends you should keep them the same because otherwise the client wont find the specific port. This tool is transparent and I don't know how to swap the filetransfer port that the server gives to the client.
 

maxst

Member
Dec 15, 2015
22
6
35
Currently not possible. Feel free to add a pull request (if you know some python) or I will have to think about an good solution. Ban via iptables should be easy possible ;) - or ban them via unique ts3 ID only.

And yes jakesmith62 the way a proxy works is that every client that is connected to the proxy does hide his real IP and instead of this IP the ts3 server will only the the proxy IP.
 
Last edited:

Grid

Active Member
Dec 31, 2015
70
13
80
Tried to explain it for you <3 (see first post).
Thank you dude, everything's clear for me now :).
Do you think you could create a proxy/vpn plugin for TS ?
That would be the best to be protected on the client side.
 

maxst

Member
Dec 15, 2015
22
6
35
I don't know if it's worth the work because you can just buy/grep some VPN provider and do that on your own. Public VPNs wouldn't be that good. I don't even know if the teamspeak API let me do sth like this.
 

Nico

Member
Feb 4, 2016
20
1
38
Error:
Code:
bungee@Dedi:~/ts3proxy$ ./ts3proxy.py
Traceback (most recent call last):
  File "./ts3proxy.py", line 25, in <module>
    int(config['ts3FileTransfer']['remotePort'])
  File "/home/bungee/ts3proxy/proxy/tcp.py", line 20, in __init__
    self.socket.listen()
TypeError: listen() takes exactly one argument (0 given)

Config:
Code:
bungee@Dedi:~/ts3proxy$ cat config.yml
ts3server:
  relayPort: 9987
  remoteAddr: 185.188.6.hide
  remotePort: 9987
ts3FileTransfer:
  relayPort: 30033
  remoteAddr: 185.188.6.hide
  remotePort: 30033
ts3ServerQuery:
  relayPort: 10011
  remoteAddr: 185.188.6.hide
  remotePort: 10011
 

Nico

Member
Feb 4, 2016
20
1
38
Code:
root@Dedi:~# dpkg --get-selections | grep python
dh-python                                       install
libpython3-stdlib:amd64                         install
libpython3.4-minimal:amd64                      install
libpython3.4-stdlib:amd64                       install
python3                                         install
python3-minimal                                 install
python3-yaml                                    install
python3.4                                       install
python3.4-minimal                               install

Same Error ...
 

Bluscream

Retired Staff
Contributor
May 8, 2015
967
934
211
Code:
blu@homeserver:/opt/ts3proxy$ python ts3proxy.py
Traceback (most recent call last):
  File "ts3proxy.py", line 7, in <module>
    from proxy.udp import Udp
ImportError: No module named proxy.udp
blu@homeserver:/opt/ts3proxy$ tree
.
├── config.yml
├── LICENSE
├── proxy
│   ├── tcp.py
│   ├── ts3client.py
│   └── udp.py
├── README.md
└── ts3proxy.py

1 directory, 7 files
 

Bluscream

Retired Staff
Contributor
May 8, 2015
967
934
211
Thank you dude, everything's clear for me now :).
Do you think you could create a proxy/vpn plugin for TS ?
That would be the best to be protected on the client side.
afaik you can use this clientside, just set the remoteAddr lines to the server you want to to connect to and connect to your server on the port.
 

maxst

Member
Dec 15, 2015
22
6
35
@B1uscr34m,
you're sure that you even used python3? is "python" a symlink to python3? pls post "python --version" ;) also try to execute it with "python3 ./ts3proxy.py", may be that relative path will help you with your problem.

Edit1: released a new version on github. Please head over there and have a look on how to install it properly ;)
 
Last edited:

Bluscream

Retired Staff
Contributor
May 8, 2015
967
934
211
https://github.com/Kandru/ts3proxy/pull/1

I'm currently looking up a way to do weblist stuff from within python, so you can disable the weblist reporting from the real server that way people connecting via weblist will also only see the proxy address

EDIT: I might need access to the source of https://r4p3.net/threads/teamspeak-3-serverlist-emulator-open-source.1486

The concept:
  1. ts3proxy uses a python telnet connection to disable weblist reporting for the real server on start
  2. ts3proxy uses py telnet to gather serverinfo required for weblisting (slots, name, etc) every 15 mins and sends them to teamspeaks weblist so the weblist shows the real server running under the fake ip
 
Last edited by a moderator:

maxst

Member
Dec 15, 2015
22
6
35
  1. ts3proxy uses a python telnet connection to disable weblist reporting for the real server on start
I don't really see the sense in this. I would rather give some advice in the README should be enough. You can disable this via serverquery and with the teamspeak clients (you need the rights to change server options).

  1. ts3proxy uses py telnet to gather serverinfo required for weblisting (slots, name, etc) every 15 mins and sends them to teamspeaks weblist so the weblist shows the real server running under the fake ip
Seems to be a good idea :) - but should be disabled by default in the config.yml but maybe make the query optional. So that you can hardcore the server name for the proxy and take the "online users" from the proxy itself. Because the query port could (maybe) be disabled on the origin server or someone doesnt want to gather the information from the origin server.
 
Last edited:
Top