Slashdot Mirror


DNS Rebinding Attacks, Multi-Pin Variant

Morty writes "DNS rebinding attacks can be used by hostile websites to get browsers to attack behind firewalls, or to attack third parties. Browsers use "pinning" to prevent this, but a paper describes so-called multi-pin vulnerabilities that bypass the existing protections. Note that, from a DNS perspective, this is a "feature" rather than an implementation bug, although it's possible that DNS servers could be modified to prevent external sources from being able to point at internal resources."

18 of 84 comments (clear)

  1. We are now checking your browser... by bugnuts · · Score: 3, Insightful

    We are now checking your browser for DNS rebinding vulnerabilities. Not without Javascript you aren't!

    But it's true, most people loooove that javascript. I can't stand it, myself, and only enable it when I absolutely have to.
    1. Re:We are now checking your browser... by grcumb · · Score: 5, Informative

      We are now checking your browser for DNS rebinding vulnerabilities. Not without Javascript you aren't!

      Heh, my boy, you just summed up the Web's great affliction in a nutshell.

      This particular exploit vector is especially troublesome because turning off the ability to point a name at multiple IPs would break a large part of the Internet. But it wouldn't be an issue for web browsers if we didn't see the need for the Web to be dynamic and interactive. Dynamism and interactivity are really not built into HTTP. It would be more accurate to say that HTTP was designed to be just the opposite.

      Website designers and software makers have been trying to turn the Web into a collection of desktop applications since about the time the Web was invented. This runs counter to what Tim Berners Lee intended. HTTP is stateless for a reason. I honestly don't think he made HTTP stateless because he envisioned the havoc that malicious websites could cause, but the principle of agnosticism (i.e. providing content without knowing anything about the requester's capabilities) that's implicit in the protocol is inherently more secure than the desire of many to make websites into remotely-accessed desktop apps.

      Unfortunately, this particular horse bolted from the barn in the earliest days of the web, and there's no easy way to get it back in. A wise web developer will nonetheless read and understand the HTTP protocol. Its statelessness and agnosticism can be strengths when considered in the proper light....

      ...Yeesh, that last sentence makes me feel like Yoda counselling young Luke.... 8^/

      --
      Crumb's Corollary: Never bring a knife to a bun fight.
    2. Re:We are now checking your browser... by grcumb · · Score: 2, Interesting

      Heh, I picked a fine day to start pontificating about what the web is for....

      Happy birthday, Web. You're almost street legal now.... 8^)

      --
      Crumb's Corollary: Never bring a knife to a bun fight.
  2. Re:Ask Slashdot: Pause a running Javascript by captnitro · · Score: 3, Funny

    CPU-sucking JS animation loop.. Any ideas?


    You should probably consider upgrading from a 486.
  3. Flashback by Spazmania · · Score: 4, Insightful

    If you haven't read the article, I'll summarize it for you: its another critical vulnerability in java/javascript. The sandboxed script in the web browser alternately makes GET and POST requests the "same" server with each POST containing the contents of the prior GET... Only the IP address associated with the server's hostname keeps alternating between a server inside your firewall and the attacker's real server outside it. Oops.

    At times like these, I tell a story about 1988 when I wrote a BBS terminal emulator for the Commodore 64 which cleverly allowed the BBS to send and run new code on the caller's machine. Another gentleman who didn't much like me noticed the feature and arranged for a number of BBS systems to execute the code at location 64738: system reset.

    There is no safe way to run complex sandboxed code on a user's PC and no safe way to allow sandboxed code access to the network. Either you trust the source of the program and let it do what it needs to do, or you don't trust it and don't allow it to run on your PC at all. How many of these vulnerabilities are we going to run through before we finally figure that out?

    --
    Moderating "-1, Disagree" is simple censorship. Have the guts to post your opinion.
    1. Re:Flashback by statusbar · · Score: 2, Informative

      One point placed in the paper:

      Current versions of the JVM are not vulnerable to this attack because the Java security policy has been changed. Applets are now restricted to connecting to the IP address from which they were loaded.

      if the web browser and applet are connecting to the server via a proxy, then neither the web browser nor the applet have control over "connecting to the same IP address from which they were loaded"

      Therefore, if a proxy is involved then current versions of the JVM are still vulnerable.

      Fortunately, the paper goes into detail about this later on:

      Proxies. If a client uses an HTTP proxy to access the web, these mitigations do not prevent multi-pin attacks using Java applets. Clients using an HTTP proxy request web ob jects by URL, not by IP address.

      The irony is that many organizations use proxies to implement both content and virus filtering. The use of these proxies themselves makes their web browsers MORE susceptible to these pinning attacks.

      --jeffk++
      --
      ipv6 is my vpn
  4. Wow. Really amazing... by mcrbids · · Score: 4, Interesting

    Did you read the abstract?

    It's well written, and has lots of examples of exactly how this vulnerability can be exploited. In short, I could probably sit down and in a single afternoon, write a set of scripts for a webserver and DNS server, post it on a $30/month "virtual host" server, and take out an ad for $100, and end up with a powerful DDOS attack on my host of choice.

    All done in less than 24 hours.

    Screw the "cyber-terrorists" in Russia, this is REALLY BIG, and is one of many REALLY BIG problems that can be exploited! And the fact that we're here, reading and posting here, is demonstration of the fact that the many vulnerabilities of the Internet are NOT being exploited to anything like their real potential...

    So think about it: while we here at Slashdork might know as many as a dozen exploitable vulnerabilities like this one that would be nearly impossible to close, how many of us have actually DONE any of these?

    And that, folks, is why security will NEVER be 100% technical, and there will always be a social mechanism involved - there really is an amazing amount of security in simply knowing that if you do, really bad stuff could really happen to you.

    Not will happen, not even likely to happen. Just could happen is enough.

    Besides, there's a funny paradox at work here: those who have the skills to pull off an attack like this also have the skills to earn an income that's legitimate, without all the risks. I'm tempted from time to time to make use of my skills in a bad way when I think about how easy it is for me to wreak havoc - but the risks of doing so have always stopped me far short. I enjoy my day job, since its nature is fundamentally altruistic. So I'm harmless.

    As a case in point, I was chatting with my flight instructor and a staff member at the local FBO (an airport for small planes) and the staff member mentioned something about an annoying ex-boyfriend who kept calling her.

    Without thinking, I mentioned the possibility of writing a quick script to send him 100,000 text messages that would say "Leave me the freak alone!". I imagined a two-line script that would take all of about 10 seconds to write, and I could use the hotspot at the FBO to do it.

    100,000 isn't even a particularly big number for me - I routinely deal with datasets in the millions of records - so it didn't really occur to me right away what a blow that would be. But 100,000 times 5 cents adds up to $5,000 worth of text messages! And I'm sure that his cell company would limit the number of messages to be sent, but it's pretty certain that quite a few WOULD get through.

    It was surprising to me what a staggering blow this would be. I was actually a bit embarrassed at having mentioned it.

    Don't underestimate the power of social mechanisms to ensure our security!

    --
    I have no problem with your religion until you decide it's reason to deprive others of the truth.
  5. Seems they forgot a few things by linuxkrn · · Score: 3, Informative

    I did RTFA, and it seems to me they made an oversight in the fact that most ISP/corp sites use a caching DNS server. A repeated lookup to the same domain will return the cached result. Their POC depends on the client doing another lookup and getting a different result. This would attack would depend on the client being able to the attacker's DNS.

    Now they do say that the attacker DNS returns more then one A record for each request. But they are ignoring the fact that the serial number of the zone would have to change for a refresh to not get cached. And even if they did create a new zone record for each visit, with the target's IP (seems unlikely), all the servers back to the client would need to respect it. Again, my ISP Qwest, has a bad habit of ignoring the TTL in my zone files.

    example 1:

    target lookup (T0) -> www.attacker.com
    www.attacker.com -> 192.168.0.1

    target lookup (T1) -> www.attacker.com
    ISP/site cached reply -> 192.168.0.1 (attack failed)

    Example 2:
    target lookup (T0) -> www.attacker.com
    www.attacker.com -> 192.168.0.1

    target lookup (T1) -> www2.attacker.com
    attacker's ISP cached reply -> 192.168.0.1 (attack failed again)

    The only case I can see this working if the zone records contain an IP for some third party source that they want to try and abuse. So say www2.attacker.com points to 10.0.0.1 and that number is static in their zone record. Which appears to be much less efficient zombie scan with IP spoofing.

    And finally, this is all dependent on the attacker tricking the client into loading Flash/Java/Javascript from their box. Another win for noscript.

    1. Re:Seems they forgot a few things by BitZtream · · Score: 2, Informative

      The zone serial number has nothing to do with this. DNS cache entries, be it on the host, or in caching DNS servers, or the clients primary DNS server are controlled by the TTL setting (Time to live). If you set the TTL to 0, you effectively disable caching across the internet for your domain. You may find some caching servers that won't honor a 0, but they're sure to expire the cache entry pretty quickly and they are few and far between.

      --
      Persistent Volume manager for Kubernetes - https://github.com/dwimsey/openshift-pvmanager
    2. Re:Seems they forgot a few things by afidel · · Score: 2, Informative

      Your OS cache should not be caching 0 TTLs per RFC1034

      Meanwhile back in the real world both OSX and Windows DO ignore 0 TTL's as do many ISP's caching DNS servers. This is one of the things that makes round-robin DNS and ISP cutovers rather hard to plan in the real world. In fact I assume that some worst case ISP's will cache results for 48-72 hours despite a TTL of say 10 minutes.

      --
      There are 4 boxes to use in the defense of liberty: soap, ballot, jury, ammo. Use in that order. Starting now.
    3. Re:Seems they forgot a few things by ACMENEWSLLC · · Score: 2, Informative

      It seems that it is a given that the host name must stay the same for this to work and that TTL must be very low, per TFA.

      So if I modify my DNS cache server to ignor low TTL's and force a minimum TTL of 60 minutes, then I've defeated this issue. Of course, I've also broke external site's ability to do quick fail overs. But that can wait until a browser fix is out.

      A browser fix could defeat this by maintaining DNS entries for a period of time. If the DNS changes to RFC1918 from non RFC1918, then prompt the user with a warning about the security issue involved and advise them to not allow the change.

      This would not protect against this same attack going out against other sites on the web, though. A hacker could change the DNS to that of eBay and submit a bid through your computer, for example. Since DNS changing often with low TTL is normal, this seems like a complex issue to fully solve.

  6. Re:Ask Slashdot: Pause a running Javascript by Sigma+7 · · Score: 2, Insightful

    You should probably consider upgrading from a 486. Won't protect against the buggy Javascript in question.

    As an example, let's assume that one of those shaky "Your the 999,999th visitor" ads pins the CPU at 100%. Unless you only one web browser window/tab open (if you read /., probably not), it will be running more than once and thus cause problems. Even one 100% CPU process or thread can lock down the system - especially if it's called "Spoolsv.exe".

    Dual core systems could help... but it won't be long before an SMP process can do the 100% pinning as well.

    P.S. If you hear whooshing, you probably want to wear eye/head protection.
  7. Re:Ask Slashdot: Pause a running Javascript by cheater512 · · Score: 2, Interesting

    Firefox should kill any bad javascript automatically.
    If it hogs cpu then it will wait for a period of time then ask you what to do with it.

  8. Re:Bind9 by Morty · · Score: 3, Informative

    For now, bind9 does not support this. See the relevant thread.

  9. Re:There are far easier ways to exploit people by Morty · · Score: 2, Informative

    It still relies on the user going to a malicious website in the first place.

    If you read the original article, you will note that they generated exploit stats by utilizing an ad network. You don't need to visit a "bad" website, you just need a "bad" ad while visiting a normal website.

    And considering that I've already (after reading the article mind you) changed my DNS servers to not return results matching our internal address range for lookups resolved from external hosts, its ever less useful.
    Cool! What server do you use, and how did you configure it to do this?
  10. Re:Backup DNS Servers? by theGreater · · Score: 2, Informative

    OpenDNS ( http://www.opendns.com/ ) works pretty well. I typically go internal cache, external ISP, openDNS on my systems. Keeps Windows boxes in line, especially.

    -theGreater.

  11. caching no problem : by DrSkwid · · Score: 2, Insightful

    1) run your own nameserver
    2) use a new subdomain for every request
    3) ???
    4) profit

    --
    There are places where the networks are not touching,and there are places where they are-Boeing's Lori Gunter
  12. In about:config by Ayanami+Rei · · Score: 3, Informative

    Change dom.max_script_run_time to a smaller (or larger) number of seconds.

    --
    THIS THING CAN TURN ON A DIME, MACROSSZERO STYLE ALSO FUCK BETA, ~NYORON