yashsingh1/xdaforums huggingface dataset:
[Google Chromecast] Roeni:
I managed it to tell the DNS-Server in my router to answer DNS-Requests to netflix.com with the IP of my Raspberry PI.

On the raspberry there is a transparent HTTP/HTTPS-Proxy which forwards the traffic via an openvpn tunnnel to the usa.

(Tutorial from: https://github.com/corporate-gadfly/Tunlr-Clone)

On my PC and tablet this works very well but I have problems with chromecast.

I introduced a rule in ip tables to forward dns traffic with destination 8.8.8.8/4.4.4.4 to the local dns server on my router when the source is chromecast:

iptables -t nat -A PREROUTING -d 8.8.8.8 -s 192.168.1.126 -j DNAT --to-destination 192.168.1.1

(where 192.168.1.126 is chromecast's ip and 192.168.1.1 is the router's ip)

Does anyone know if there are some other domains which do an ip check? So I would need to include them in my dns config. Just *.Netflix.com seems not to be enough (although it's enough for pc and tablet)
[Google Chromecast] Alireza Fa:
?

Hello.I Am In Iran.I Have TD-W8151N Router.I Can Not Set It Up As you said?

What Should I do?
[Google Chromecast] ttsaon:
us vpn will help you
[Google Chromecast] igrix:
mikrotik

Hi,

in case if someone use Mikrotik router instead of some dd-wrt flashable device, here is correct iptable analog for routerOS:

/ip firewall nat
add chain=dstnat dst-address=8.8.8.8 action=dst-nat to-addresses=50.112.186.233
add chain=dstnat dst-address=8.8.4.4 action=dst-nat to-addresses=50.112.143.40

it is analog for Unlocators officiall lines:

iptables -t nat -A PREROUTING -d 8.8.8.8 -j DNAT --to-destination 50.112.186.233
iptables -t nat -A PREROUTING -d 8.8.4.4 -j DNAT --to-destination 50.112.143.40
[Google Chromecast] nike5650:
Hi,

I am from India. Router details are Binatone and firmware version is T6W-A1.004. I was able make to DNS changes and open netflix, hulu.. But I am not able to cast. When I run the iptables command it says, invalid command. Can I use ip route for this..?

---------- Post added at 12:02 PM ---------- Previous post was at 11:57 AM ----------

Hi,

I am from India. Router details are Binatone and firmware version is T6W-A1.004. I was able make to DNS changes and open netflix, hulu.. But I am not able to cast. When I run the iptables command it says, invalid command. Can I use ip route for this..?
[Google Chromecast] bhiga:
I could be wrong, but I don't think ip route will work, as you need to change the destination, not just the (routing) path between.

If your router is already using your preferred DNS, you could try blocking the Chromecast's requests to the Google DNS servers and see if it will "fall back" to your DHCP-provided DNS server. See http://xdaforums.com/showpost.php?p=47609732&postcount=103
[Google Chromecast] victorhooi:
Hi,

I can confirm that I was able to get this working with a Ubiquiti RouterStation Pro running OpenWRT and Luci.

I'm wondering, is it possible to do this without being dependent on a external commercial service like Unlocator? (i.e. could you host it on your own infrastructure?).

For example:

https://github.com/corporate-gadfly/Tunlr-Clone

is a howto about doing it yourself on your own VPS.

However, apparently their setup doesn't work with the Chromecast, due to SSL issues.

Does anybody know what services liked Unlocator do to get around this problem?

Cheers,

Victor
[Google Chromecast] crossfire77:
wow.it's working ! even pandora,vevo works great on broswer :D
[Google Chromecast] pntba:
if my router doesnt support custom firmware then how to go about this business ?

ps my router/modem is dlink 2750u
[Google Chromecast] bhiga:
Did you try the info from post #103?
[Google Chromecast] pntba:
i will try doing it today and will post it if it works or no . thanks for pointing me out to this post
[Google Chromecast] jmudrick:
If your router won't let you block specific addresses, redirecting that traffic to a fake gateway accomplishes the same thing. Worked for me on both my Linksys and TP-Link routers.
[Google Chromecast] dsteinberg:
Hello, i have a fritzbox and have tried with no luck to block specific adresses as metioned in post 103. Could you please explain how to rederect traffic to a fake gateway?

thanks
[Google Chromecast] jmudrick:
Here are screenshots from the TP-Link, destination being Google, Gateway IP being an unused address.
[Google Chromecast] dsteinberg:
Gentleman, you made my day!!

applied your fix as per your instructions and its working like a charm

this dns fix has to be reported in the Chromecast FAQ

many thanks
[Google Chromecast] bhiga:
Added. :)
[Google Chromecast] ykphuah:
Do you mean chromecast will start using the assigned DNS from DHCP once it can't connect to 8.8.8.8 and 8.8.4.4?
[Google Chromecast] jmudrick:
Yes, in my case the Static DNS provided by Unlocator.
[Google Chromecast] kahthan:
blocking the two google DNS servers didn't work for me, so will try the fake gateway redirection and see
[Google Chromecast] ykphuah:
Cool! let me check my Asus router whether it have static routes configuration, this means I don't have to do the telnet to run the iptables rules everytime I reboot the router.
[Google Chromecast] saumil25:
This did wonder on my Netgear router, here in India! Netflix, Pandora, Vevo all work just fine with Chromecast! I'm using dns of unblock-us. So glad! Thank you for posting it! :D
[Google Chromecast] neobendez:
Therefore, getting a USA VPN connection before travelling abroad has become as important as taking along the passport and credit cards. Great source...
[Google Chromecast] red.eye:
Hi,

I tried with my TP-Link W8960n but it doesn't work....

Could you please tell step by step what should I do ?

I have telnet acces to my router.... then ?

Thank you very much!!!!!!

-

Marco
[Google Chromecast] mayhemrules:
Marco, you only need to chsnge the DNS in your router to that of unlocator. Check out their website for device specific instructions.
[Google Chromecast] ykphuah:
wow, the static route method works! No more telnetting and manually running iptables! Yay!
[Google Chromecast] red.eye:
Guys,

do you mean chromecast now uses router's dns and doesn't use anymore google's ones ?

Marco
[Google Chromecast] ykphuah:
Yeah, seems like it does, once it can't reach 8.8.8.8 and 8.8.4.4.
[Google Chromecast] Philarious:
Hey there I just came to say thank you works great from germany, I have linksys e1200.

Only issue was with the netflix apk file on my phone after installing there was no cast button. I couldn't find it in the playstore-app guess because of my location, then I installed the netflix app through the chrome browser from google play site, then the button was there.

It's fast and It looks way better then before on win 7 pc with only 3000kbps stream, guess that means it's super-hd now yay.
[Google Chromecast] saumil25:
Is there any VPN Service like unlock-us that is free? Want it for Netflix on Chromecast
[Google Chromecast] dsteinberg:
hi, you should try unlocator, it works well with netflix and other services and is free, until it remains so
[Google Chromecast] Scragon:
Great, but loading issues

Hey, thanks for the great post, I have this set up and running in New Zealand now.

But I do have some issues. When casting a video from Netflix, the Chromecast gets stuck at 25% and then after about 2 mins, the video plays.

This is bearable, but then the video starts buffering about every 30 seconds, always getting stuck on 25%, rendering it kinda useless. Now I can stream HD YouTube videos fine, the problem seems to be isolated to Netflix. I have turned the quality down in the Chromecast options, still no luck. I even tried replacing the DNS with Unblock-Us, still the same issue. Anyone else having this problem, anyone know a fix? Your help would be much appreciated! :fingers-crossed:
[Google Chromecast] Hampa_D:
ive gone the manual way because i have a wnr2000v2 i can play the us netflix form chrome but i cantä cast it to chromecast, not from chrome and not from my sgs4, ive fkused dns, restarted everything, cant really figure this out
[Google Chromecast] bhiga:
I think you're pulling from US Netflix streams? If so, because you're abstracting the DNS, it's probably also pulling content from the US servers, rather than closer-to-your-region mirrors.

Essentially you're not benefiting from the normal content delivery edge network.

It's like me in the US trying to download from a mirror in Hungary rather than one from US/Canada.

If I'm right, not sure of a way around it as the content you want likely does not exist on an edge node in your region if it's not offered there.
[Google Chromecast] ykphuah:
I am from Asia and I have been facing this starting this week. Either there's more people that are using unlocator now, or that there's a lot of people having holidays to watch netflix. Will see what happens in a week or two later.
[Google Chromecast] jmudrick:
In Cambodia, have had no Netflix access for a while. May be related to broken ocean cable.
[Google Chromecast] spam.this:
For Mac OSX users, you can use OpenBSD PF (packet filter) that replaced ipfw.

I am running a Mac Mini with a wired internet connection. I enabled internet sharing for it's internet connection through the wireless device in Settings -> Sharing.

Then I added the below lines to /etc/pf.conf and then ran pfctl -f /etc/pf.conf.

You might want to enable pf with pfctl -e. You can tweak your interfaces as needed. I have my Chromecast connected on the shared wireless network.

Enjoy
[Google Chromecast] Zefco:
Happy to confirm that it works with the ASUS RT-N12 in Germany. Chromecast, Netflix APK on Andoird and Netflix Website.
[Google Chromecast] Cuzz1369:
Ahhhh...Well they finally got dd-wrt to flash on my ea2700 router. I signed up for unlocator a long time ago but there was no way to get it to work until now. I flashed dd-wrt and added the proper lines, now I can enjoy American Netflix in Canada once again. The only problem is there are a couple of series I wish to watch that are only available on American Netflix. So my question is, is there a way to "blacklist" a device from using unlocator using dd-wrt? I can always download whatever I cant get like all of my HBO shows, but thought there might be an easy way to let an ip address of a certain device pass through.
[Google Chromecast] kpiris:
That would be easy with -s option of iptables:

This would apply the redirection rule to all devices on your network, except the one with 192.168.1.321 address:

iptables -t nat -A PREROUTING ! -s 192.168.1.321 -d 8.8.8.8 -j DNAT --to-destination 50.112.186.233
iptables -t nat -A PREROUTING ! -s 192.168.1.321 -d 8.8.4.4 -j DNAT --to-destination 50.112.143.40

On the other hand, if you remove the ! before -s, then it would apply the rule only to the device with 192.168.1.321 address (say, your chromecast).

Obviously, you would need to replace 192.168.1.321 with a valid ip address that suited your needs.
[Google Chromecast] Pris0n:
I currently don't have a dd-wrt router (fritzbox user). Would it be possible to buy a dd-wrt router and use the fritzbox as primary one and the second like a hotspot with the functions in the first post?

Will this work for chromecast to access netflix outside europe?
[Google Chromecast] spam.this:
yes you can do this, if your chromecast is connected to the ddwrt, the ddwrt takes charge of changing the packets and forwards already modified packets to your main router.
[Google Chromecast] bhiga:
Just make sure the Chromecast is connected to the DD-WRT access point and is not bypassing its gateway/routing.
[Google Chromecast] ofird:
I have a tplink 1043 - where can I see its command line interface to add the routing info?
[Google Chromecast] sirdicholas:
found this after I paid hard earned money for a VPN. DAMNIT!!!! works great however. Thanks!
[Google Chromecast] zangetxu:
refund it if you regret paying hard earned money
[Google Chromecast] Pris0n:
Do you have a router in mind, which is able of doing this? It just needs this basic functions for the chromecast usage, as I don't want to spend that much money, otherwise I can just buy a new cc and route it :D
[Google Chromecast] bhiga:
Lots of routers can run DD-WRT these days. I'd just try the static route to bogus gateway first.

You could buy another Chromecast if you can find a rootable unit... It's different from a phone/tablet - only a unit with the original bootloader can be rooted, and the units shipping now are way beyond the original firmware and bootloader.
[Google Chromecast] dsteinberg:
hei, i have a fritzbox and have used the trick on post 101 and is working like a charm
[Google Chromecast] Bilbobeutlin:
Hey, could you tell me what exactly you have done? I've got a fritzbox (7312) too, but nothing works. I think you mean post 103

I made a rule for blocking TCP and UDP source:53 destiny:any, but with that rule chromecast says that there is no internet connection.

Would be great if you could help me :)

Greetz
[Google Chromecast] bhiga:
Blocking port 53 will block all DNS which is not what you want to do. :)

Try blocking the servers listed in this post:

http://xdaforums.com/showthread.php?p=49060386#post49060386

If blocking doesn't work, route those addresses to an unreachable gateway. In the post, 192.168.0.1 is unreachable as I assume their routers's subnet is 192.168.1.1 -- if your router's subnet is 192.168.0.1, use 192.168.1.1, 192.168.10.1, 192.168.99.1 or anything outside of any routed subnets but within a private IP range (otherwise you'll hit an actual outside IP address, which would be bad).
[Google Chromecast] Bilbobeutlin:
Thank you,

i've read this thread too and found this post, but when i try to make a fake gateway my router says "not part of your ipv4-network" -.-

My default gateway is 192.168.178.X

What i try is:

IP: 8.8.8.8

Subnetmask: 255.255.255.0

Gateway:192.168.0.X

Any idea? :confused:
[Google Chromecast] bhiga:
You can try two things:

Set the gateway to an unused IP *in* your subnet, like 192.168.1.220

Or...

You can change your default LAN address to the bogus subnet, add the static routes, then switch your LAN address back to normal (I used to have to do this trick on an old Netgear router).

Sent from a device with no keyboard. Please forgive typos, they may not be my own.
[Google Chromecast] Bilbobeutlin:
Nice trick, realy keept the settings ;)

So i tried both methodes:

- the unused IP: no sucess, just Netflix logo and the loading symbol

- Static Routing with fake-gateway:

The same thing, just the Netflix logo and the loading symbol. :(

I restartet router, tv and chromecast several times, no changes.

Thank you for your efforts so far, I'm going to sleep now, try it tomorrow again.
[Google Chromecast] bhiga:
Note that the bogus gateway will/should make Chromecast use your DHCP-supplied DNS server, so if your router is not providing a compatible DNS, then it probably won't work.

If you need just Chromecast to use a specific DNS (and you should have your phone/tablet use the same DNS) then you need to use the iptables redirection method.
[Google Chromecast] ofird:
Thanks guys

Worked for me with this method

The quality of the movies though isn't really HD...
[Google Chromecast] Pris0n:
Let me know if you get it working. I'll have an fritz 7390 with the same problems.
[Google Chromecast] muvisan:
I have an FB 7320 and it is working with routing the google IPs to some unused IP...

But you have to be careful how you enter the the google IPs (it should not be 8.8.8.8 and 8.8.4.4,

but should be 8.8.8.0 and 8.8.4.0 - because FB does not allow to enter netmask 255.255.255.255).

So it should look like:

IP: 8.8.8.0

Subnetmask: 255.255.255.0

Gateway:192.168.178.222 (per default you have the FB configured as GW 192.168.178.1,

so it must be in this network - and in this example .222 is an IP which is not used by any host).

And same for IP 8.8.4.0.
[Google Chromecast] Bilbobeutlin:
Thank you so much! That was my fault, i used the subnetmask 255.255.255.0 but with the full ip-Adress. With your how-to it works great! :) THANK YOU!
[Google Chromecast] DJames1:
I thought that the Chromecast never uses a DHCP-supplied DNS server, but it turns out I was wrong (see below). But if you block the Google DNS server addresses without redirecting them, the Chromecast will simply report a failure to connect to the internet.
[Google Chromecast] bhiga:
Are you sure it's the router that's doing the fallback and not Chromecast itself though? zaqh only blocked the IPs/ports (different technique but same result) and it seemed to work for them.

If I nslookup on my PC and set the server to a blocked or unreachable address, I just get a timeout - I don't get a response from my router.

EDIT: Actually... since you can't set static DNS on Chromecast, aren't the only other DNS servers known to Chromecast delivered via DHCP anyway?

EDIT2: I saw your other post. That's a pretty neat feature if your router is handling all the routed DNS requests.
[Google Chromecast] DJames1:
It's easy to simply block Google DNS on almost any router, but that doesn't seem to work - the Chromecast just says that it can't connect to the internet. But perhaps there's a difference in the response returned to the Chromecast between explicit blocking and simply directing the lookup to a non-existent gateway.

Hmmm, let's see - actually I can think of an easy test:

I set my router to use my default ISP DNS, and to redirect the Google DNS addresses to a non-existent gateway.

I turned off the DCHP server in the router and turned on a simple Windows DHCP server that I use to assign U.S. DNS addresses to my devices.

I turned on the Chromecast and my iPod Touch, and the Windows DHCP server reported that both contacted it and were assigned local IP addresses and U.S. DNS addresses.

Then I tried playing a U.S.-only Netflix video on the Chromecast. If the redirected Chromecast DNS lookups were going through the router, they would end up using the default ISP DNS. If the Chromecast was using the DNS addresses assigned via DHCP, it would use the U.S. DNS addresses.

The video played successfully, telling me that it's using the U.S. DNS addresses.

So I guess what we can conclude is:

1. The Chromecast does indeed fall back to the DHCP-assigned DNS addresses if it can't contact Google DNS because of an invalid gateway.

2. If the Google DNS addresses are being explicitly blocked by the router, the Chromecast thinks it can't contact the internet, and it won't work.

I don't know exactly what the difference in response is between these two situations. Maybe in one case there is no response, leading to a timeout, and in the other case there is a response like "too many hops", or 404 or something like that.
[Google Chromecast] bhiga:
Good test. I guess for #2 it probably depends on the individual router response - if it denies the request outright, or simply ignores it and lets it time out.
[Google Chromecast] merlin2380:
Thanks alot this worked like a charm, the topic should include "without root" .

The current main router is from my ISP so I can not even exchange the DNS server, or execute any commands.

Then thought of upgrading an old router to DD-WRT, but they were incompatible.Current main router is from my ISP so I can even exchange the DNS server, then I though maybe buying one about $25 but then remembered I have a 2nd so far unused raspberry pie into a router with a USB WIFI adapter I had lying around(TL-WN7200ND)

After searching the net for a ready made image, I noticed that my 1st raspberry pi with openelec can be turned into an AP with a few clicks.

Just changed the DNS and executed the 2 lines and everything works smooths, thanks a lot.
[Google Chromecast] aikkon:
Hi! After several hours reading about rooting chromecast and about flashing wrt firmware onto my router, getting netflix to work in chromecast was a piece of cake thanks to you....genius, man!
[Google Chromecast] vasanthtt:
I did setup unlocator. I am able to play netflix in my laptop but when I cast to chromecast, it shows netflix screen with loading.. nothing happens after. Please let me know . I have cisco router.
[Google Chromecast] ofird:
You should block Google ip address in your router

Look in this thread
[Google Chromecast] danne75:
Has anyone managed to get this working on a Asus router (DSL-N55U)? I have tried all different settings in the firewall without success..:(

I use unlocator as DNS server in WAN settings.

Any input is most welcome.
[Google Chromecast] messiah_029:
Need more clarification

Hi ,

--Can you provide the detailed steps, joseph...
[Google Chromecast] bhiga:
Post 102 in this thread.
[Google Chromecast] danne75:
Finally !!! Thanks for the help.
[Google Chromecast] DJames1:
I did some more tests on this, specifically checking what the response is to pinging 8.8.8.8 depending on the different methods of blocking Google DNS in the router. If the Google DNS addresses are blocked in the router so that any packets sent there get no reply (e.g., by using IP filtering), or if the Google DNS addresses are instead redirected to a non-existent gateway so that the router returns the response "unreachable destination", the Chromecast falls back to the DHCP DNS addresses.

But note that using Access Restrictions with a Linksys router or any other router based on the same firmware (including DD-WRT) will not work, as the flawed design Access Restrictions will not allow blocking a specific IP address. You would have to use the iptables command.
[Google Chromecast] betizad:
Can someone help me to make this work on my thomson tg784 router?

I have been able to change the prim and sec dns to unlocator and netflix works on my laptop now but I don't know how to reroute the google dns 8.8.8.8 to the unlocator ones.

I'm kind of noob on the router but I happen to have the manual of the router commands via telnet, which is almost 1000 pages.
[Google Chromecast] Kyonz:
Hi Behzadbayat,

I had a quick search and it looks like you should be able to create firewall rules in this device.

Your best option would be to set the DNS servers on your router to unlocator and then create a firewall rule to block 8.8.8.8 and one to block 8.8.4.4 which should force the chromecast to go to the DNS server you specify in the router.

Let me know if this helps, if you need further information I'm more than happy to help troubleshoot.

Regards,

Kyo
[Google Chromecast] ryohunter:
Hi,

I have set up my WR703N properly with both DNS from Unblock us and the following IPTABLES rule :

iptables -t nat -A PREROUTING -d 8.8.8.8 -j DNAT --to-destination 208.122.23.22

iptables -t nat -A PREROUTING -d 8.8.4.4 -j DNAT --to-destination 208.122.23.23

but I'm running into an odd problem.

Google services such as Google play music or movies just don't work..

Any idea what could be causing this ? If so, what do you think should I do ?

I haven't been able to figure out what's wrong, since Netflix and Hulu work fine.

Thanks a lot for your help,

RYO
[Google Chromecast] Kyonz:
Hi ryohunter,

My guess is that you need to add the following:

iptables -t nat -A POSTROUTING -j MASQUERADE

Without a masquerade rule the traffic will return looking like 208... instead of the google servers and won't be accepted. Let me know if that helps.
[Google Chromecast] ryohunter:
Thanks a lot for your help.

I'm going to try this ASAP and will keep you posted. Thanks again.
[Google Chromecast] Kyonz:
any luck?
[Google Chromecast] betizad:
I already changed the dns to the ones from unlocator and would try the firewall tonight.

Thanks.
[Google Chromecast] DJames1:
If you're going to try methods like using a firewall to block Google DNS, you need to make sure that you are blocking only IP addresses 8.8.8.8 and 8.8.4.4.

To test what your router setup actually does, try pinging Google DNS IP address 8.8.8.8 from your computer. If the ping says "Timeout" or "No response" or "Destination Unreachable", but you can still access other internet sites, you're good to go.
[Google Chromecast] Kyonz:
Thanks for that DJames1, I think that's really important and probably the best way to go about it as most routers by design should allow for the ability to add a static route (and operate in the same manner for consistencies sake).