As you may know, Cloudflare doesn’t proxy everything apart from:
80, 8080, 8880, 2052, 2082, 2086, 2095
443, 2053, 2083, 2087, 2096, 8443
Even Spectrum wouldn’t help because it does only proxy TCP connections.
To use Teamspeak behind a Cloudflare protected domain you need to add some additional DNS records:
Add a new DNS A record for your Teamspeak server as a subdomain. Let’s call it: 'ts.’ and point it to your Teamspeak server IP address. If you are unsure how to do it, have a look at this tutorial..
Ensure the cloud icon is (just click on it, if it’s )
Add a new SRV record for this subdomain as follows:
- select ‘SRV’ from the drop down menu
- add the following as ‘Name’ and save the settings:
Next step is to set the priority and weight. Any value may work. I’ve set mine to 0. Port 9987 is the default port and may vary. Ask your Teamspeak host if you’re unsure:
That’s it. You should now be able to connect to your TS Server, using the address ‘ts.yourdomain.com:9987’.
You still need to add the port within your Teamspeak Client, to connect to your server:
This DNS record will not hide your TS IP address comnpletely even though ‘ts.yourdomain.com’ is set to ! As soon a someone connects to your server, the origin IP will be revealed. But this setting prevents your server of being detected by DNS scanners, because they would see Cloudflare IPs. This is a snippet from my client logs:
25.01.2019 22:18:48 ClientUI Info Connect to server: ts.yourdomain.com 25.01.2019 22:18:48 ClientUI Info Trying to resolve ts.yourdomain.com 25.01.2019 22:18:48 TSDNS Info A/AAAA DNS resolve for possible TSDNS successful, "yourdomain.com" =(h: 220.127.116.11 p:0) 25.01.2019 22:18:48 TSDNS Info A/AAAA DNS resolve successful, "ts.yourdomain.com" =(h: 18.104.22.168 p:0) 25.01.2019 22:18:48 TSDNS Info A/AAAA DNS resolve for possible TSDNS successful, "ts.yourdomain.com" =(h: 22.214.171.124 p:0) 25.01.2019 22:18:48 TSDNS Info A/AAAA DNS resolve successful, "dc-474e18d1343c.yourdomain.com" =(h: 62.xx.xx.xx p:0) 25.01.2019 22:18:48 ClientUI Info Lookup finished: ip=62.xx.xx.xx port=9987 query=ts.yourdomain.com error=0 25.01.2019 22:18:48 ClientUI Info Resolve successful: 62.xx.xx.xx:9987
While this one is a Cloudflare IP:
25.01.2019 22:18:48 TSDNS Info A/AAAA DNS resolve for possible TSDNS successful, “ts.yourdomain.com” =(h: 126.96.36.199 p:0)
the next one will reveal your origin:
25.01.2019 22:18:48 TSDNS Info A/AAAA DNS resolve successful, “dc-474e18d1343c.yourdomain.com” =(h: 62.xx.xx.xx p:0)
This reflects my setup which works for years now.