Not signed in (Sign In)
    • CommentAuthorpatio11
    • CommentTimeSep 28th 2007
     permalink

    Thanks for the help and suggestions earlier guys.

    As I mentioned in that thread, I’m an American expatriate and the new episode of Heroes getting released is one of the highlights of my week. Unfortunately, NBC’s site and Amazon both use an IP-to-location lookup and they won’t let you download the episodes if you’re outside of the United States. I know, you can pirate them off BitTorrent but I believe it to be wrong.

    Anyhow, time to use your VPS to make a VPN to be a VPA — Virtual Private American. Slicehost’s servers all geolocate to St. Louis. Woo-hoo. And, if you can get Apache working (and you can, with the excellent guides available — plus if you’re using Ubuntu/deprec its simple as flipping the switch on), all you need to do is a little surgery in your .conf file to make Apache into a server proxying all your outgoing connections.

    1) Locate the .conf file Apache is using. Typically, it is called httpd.conf, and common locations include /usr/local/apache2/conf/httpd.conf (that is where Ubuntu/Deprec puts it, anyhow).

    2) If you’ve got multiple sites running on Apache already (I do) I suggest doing this in a seperate file and writing

    Include relative-path-from-Apache-root-directory/your-file-name-here.conf

    . If this is your only use for Apache, you can just put the following directly in the httpd.conf file:

    —-

    ProxyRequests On
    ProxyVia On

    <Proxy *>
    Order deny,allow
    Deny from all
    Allow from Put The IP Address Of Your Home Computer Here
    </Proxy>

    —-

    3) Restart apache. Type the following at the command line, or you can just have Capistrano do it for you:

    sudo /etc/init.d/httpd restart

    4) Open up your application of choice on your home computer, go to proxy settings, and set your proxy server to your slice’s IP address (or you can do any domain name you have pointing to it) and your proxy port to be whatever the port Apache is serving on (by default, 80). You don’t need a username or password — don’t worry, you’re not running an open proxy, as the only person who can get into it is you. (That is the point of including your IP address. If you’re on a dynamic IP, you’ll have to do this every time you want to log on. Not a bad idea, anyhow.)

    5) Surf the Internet using your Virtual Private American! You can now do things like, e.g., check out American politicians’ websites (which, sadly, frequently ban foreign IPs to prevent DDOS attacks), watch the free movies at www.nbc.com, or pay Amazon for a season pass of Heroes. (The best show on American television, by the way. Do you think I would be going to these extremes if it wasn’t?)

    6) When you’re done, re-edit the Apache config file to eliminate what I told you to put their earlier, and reset Apache using the same method as above.

    As an aside, since this doesn’t significantly add to Apache’s memory overhead you can comfortably pull it off on a 256MB slice which is otherwise in use.

    Thankful People: matt, The Fox
    • CommentAuthorthrope
    • CommentTimeSep 28th 2007 edited
     permalink
    Here is a similar trick - you can use any ssh server with tunnelling enabled as a proxy.

    linux: http://ubuntu.wordpress.com/2006/12/08/ssh-tunnel-socks-proxy-forwarding-secure-browsing/
    windows: http://kimmo.suominen.com/docs/proxy-through-ssh/

    Basically you set up a dynamic tunnel on from a port on your local machine to the ssh server. Then in your browser you set it to use localhost as a proxy and all the traffic gets sent through the tunnel... so it will work for fooling the geographical check. As an extra advantage it's encrypted...

    I've used this to help a friend in china get to the bbc...

    I think this is a bit easier to set up than the apache thing, so quite handy if you find yourself in a situation with a specific site blocked but can still get onto your computer at home (or your slice - I'm still waiting for mine!)

    [EDIT: I thought I'd add I personally don't see the moral distinction between doing this to cheat their geographic check and downloading it from tvtorrents...]
    • CommentAuthorpatio11
    • CommentTimeSep 29th 2007
     permalink

    >>I thought I’d add I personally don’t see the moral distinction between doing this to cheat their geographic check and downloading it from tvtorrents…
    >>

    I’m paying Amazon $1.89 an episode, so NBC is seeing the amount of money they had agreed upon from me watching the show. I know its not 100% legitimate, because I’m techncially in violation of subpoint 137b of Amazon’s click-thru license, but “I’m paying the legitimate rights-holder for this” is enough for me to sleep at night.

    • CommentAuthorthrope
    • CommentTimeSep 29th 2007
     permalink
    Ah fair enough then - I didn't realise you were paying... I thought it was free on-demand online service and that's why it was geographically restricted (some channels run that now in the UK).
    • CommentAuthorverby
    • CommentTimeDec 1st 2007
     permalink

    We’ve been using this Virtual Private American setup for two months and everything was working perfectly. But just last night, things stopped working. We can still access our “virtual private American” but we no longer have a St. Louis IP address. Now, when we access our proxy, we end up with another IP address from our ISP. So our IP address changes, but obviously that’s not exactly what we want to happen.

    We spend a lot of time at our office in Bogota, Colombia and we use our Slice as a proxy plus OpenDNS so that when we surf, it’s like we’re in the States. This problem really isn’t the end of the world for us. I just get annoyed not being able to do what I want with our internet service(s). We did not only “lose” the ability to surf using our Slice’s IP address, but OpenDNS also stopped working for us. I’m guessing that our ISP changed something. (We’re using CableNet http://www.cable.net.co/home.asp .)
    I’m guessing that they’re forcing all DNS requests to go through their DNS servers and that they’ve also done something to mess with proxies.

    Is there anything we can do to bypass whatever our ISP is doing? Any suggestions? (We’ve already called them and they claim that nothing has changed. I don’t believe them.)

    •  
      CommentAuthorjason
    • CommentTimeDec 1st 2007
     permalink
    The easiest way to figure out what is going on is to start sniffing your traffic and see whats happening.
    • CommentAuthorSergeyD
    • CommentTimeDec 3rd 2007
     permalink
    verby,

    You can run OpenVPN. Then all your traffic would go through your slice.
    • CommentAuthorejeffrey
    • CommentTimeDec 7th 2007 edited
     permalink
    My guess is that your local settings have changed. It would be very odd for your ISP to stop proxies from working, and odder for it to not just keep you from browsing.

    Also, instead of using the proxy for everything or manually enable/disabling it, you can use a proxy auto config file with a list of hostnames that you want to proxy. You will avoid some latency that way.

    Wireshark will show you what is going on. The best way to do this is to set up a local webserver on your client and connect to it through the proxy. Then you get to see both sides of the connection to see who is tampering with it. You might also notice if anything weird is going on with your DNS, though that will be harder to see. Make sure you have your browser set up to use the proxy even for local connections.

    It is possible that your ISP is implementing its own transparent proxy, and adding a 'via' header that is tipping off the clients that you are not an American. Add 'ProxyVia Block' to your apache configuration to filter these out.

    edit: one more thing, I recommend running the proxy on a separate port (say 8080) from web traffic, I have had problems trying to use virtual hosting for proxies. Maybe it isn't even possible, though I didn't try for very long.