toniebox-reverse-engineering/teddycloud

[DNS][CC3235] Set DNS server or method for CC3235 Chip

Closed this issue · 5 comments

Describe the issue you are experiencing

How can I find a better solution to set the DNS for the toniebox with the chip CC3235 without breaking the other tonieboxes in the house. I don't want to hack the kids working toniebox, yet. I have the spare one which I'm currently hacking and it seems the most difficult one to handle. No custom FW and no ESP32 features....

What type of installation are you running?

  • Toniebox version chip CC3235
  • Fritzbox as router
  • Teddycloud Docker with own IP address running on debian VM running on Proxmox on dell server
  • Adguard home as DNS server for complete network- Pihole possible but Adguard currently prefered

Teddycloud version
v0.6.2

Steps to reproduce the issue

  • Image dumped from certificate chip
  • Certificated extracted via CC3200tool
  • Flashed Teddycloud certificates on certificate chip
  • DNS setting to redirect prod.de.tbs.toys and rtnl.bxcl.de to teddycloud docker ip ==> Break the other tonieboxes.

tried already

  • Run binwalk on image to find DNS entry = => No luck
  • I can't differentiate in adguard the dns request from the different tonieboxes as all request comes from the fritzbox to adguard.

Limitation

  • I still want to keep the fritzbox as DHCP server for the network.

In short: You can't change the DNS entries of a CC3235 in the image. The image is encrypted and signed. You may access it unencrypted if you dump the OTA updates in teddyCloud. But this won't solve the signing problem of the firmware.

You need a configurable DHCP server or a seperate wifi.

@SciLor Many thanks for putting the issue in the correct Repo. I'm still a bit lost about the different Repo of the project.

And thank you for your feedback. I need to think a bit more again. I wanted to check in if someone had a smarter idea :(.

BR

Get a cheap used WiFi router and set everything up with that. That’s the way I would proceed

Dear all,

I've found a solution !!!

If you have a fritzbox & adguard running you can use the DNS rewrite function.

  1. Set in the fritzbox the "local DNS server" to the adguard server. This is needed so that you can see which device is hitting your adguard. This is needed to avoid only seen the fritzbox querying adguard.
  2. Your Teddycloud needs to have a fixed IP.

If you have that, in Adguard home add the following custom filters:

||prod.de.tbs.toys^$dnsrewrite=NOERROR;A;XXX.XXX.XXX.XXX,client=XXX.XXX.XXX.XXX
||rtnl.bxcl.de^$dnsrewrite=NOERROR;A;XXX.XXX.XXX.XXX,client=XXX.XXX.XXX.XXX

The code says the following: Redirect all requests for prod.de.tbs.toys to the teddy IP address but this rule is only valid for the client toniebox ip. The rest of your device still can hit prod.de.tbs.toys as usual.

What advantages does this have. You don't need to specify a DNS server in the docker-composer and I can still have the kids toniebox working as usual.

"My" Toniebox is for experimenting and for the kids to use as special Toniebox version.

Best regards

added that approach to the flash guide also

image