Critical Flaw Discovered In DD-WRT
MagicM writes "A critical flaw has been discovered in DD-WRT, a Linux based alternative open source firmware for WLAN routers such as the fan-favorite Linksys WRT54GL. The flaw can give an attacker instant root access to the router merely by embedding an image with a specially crafted URL in a Web page (CSRF attack)." The linked page notes that a fix is being rolled out (build 12533) and gives firewall rules to thwart the attack if the fix is not available yet for a particular device.
Yes, there's a fix for this, but what is the likelihood of every person who owns a Wifi router fixing this flaw?
We talk about the dangers of homogeny, but this is exactly the type of thing that homogeny causes. All the routers with DD-WRT implemented to save costs, but in the end everyone is screwed.
Just because we love Linux doesn't mean that we should sacrifice the entire ecosystem to that love. We need to nurture other implementations to prevent this type of virus from wiping out our entire networking infrastructure.
I was wondering: How can this attack be carried out if the external web management is turned off? From the article:
Note: The exploit can only be used directly from outside your network over the internet if you have enabled remote Web GUI management in the Administration tab. As immediate action please disable the remote Web GUI management. But that limitation could be easily overridden by a Cross-Site Request Forgery (CSFR) where a malicious website could inject the exploit from inside the browser.
The Shashdot blurb does state "The linked page notes that a fix is being rolled out (build 12533) and gives firewall rules to thwart the attack if the fix is not available yet for a particular device." but that statement doesn't curb a lot of the "The Sky is FALLING!" reactions....
Basically, I would NEVER allow remote web management of a device if it's on the internet. I believe the default for DD-WRT is to disable it as well, so you'd have to go in and tell the device that you want to enable this feature. All in all, I think for most users, this issue is a non-issue.
Karnal
It's worse than a specially crafted image - there's a code injection flaw in the httpd server so merely accessing a URL that looks like "http://routerIP/cgi-bin/;command_to_execute" will do the trick. That URL can be put in a malicious tag on an HTML page and the user most likely won't even notice it.
See the Register article on it from a couple of days ago.
You know, as much as I used to complain about the many different distros - you've got a damn good point.
Why can't all fpga/microcontroller manufacturers just release free optimizing compilers???
my router keeps redirecting me to porn sites and scrolling "pWnD by c0d3k177y" in HTML marquee tags at the top of my browser.
Because attackers will certainly have difficulty cracking your crappy wep key in 5 minutes or less, or guessing that your username and password is "linksys"/"admin"
And it's only if you have web management enabled? who does that anyways? "Yeah I like to change my wifi password from work sometimes, or maybe forward some ports without having to log into my home machine"
Ze Atomic Device! It iz Ztolen!
Bravo to them for owning up to it and also posting the fix on the same page.
The interesting thing I've read a lot here is how vulnerable and worthless Microsoft is when it comes to security...but it seems the people that think this automatically point to Linux as being secure.
Linux is somewhat secure, but a LOT of the security of linux is due to a limited (unfortunately) market share. If Linux owned 30% or more of the market space for end-user goods, we'd see a HUGE influx of hacks, malware, adware, etc.
It flabbergasts me that people don't see this. The greatest thing Linux has going for it is the collaboration and freedom of the code. With that freedom comes the ability to exploit it. Wait til market share gets larger, it'll start to happen a lot more than the rare article here and there. The good news, though, is again, they identified the problem AND THE FIX on the same page. (Something MS has to be drug kicking and screaming along in order to do that)
Sent from your iPad.
It's a third party firmware for most wireless routers. So, it affects whatever devices YOU install it on
Your statement is exactly analogous to this one:
What the hell is a linux? Can someone find a list of actual computers that are affected by this instead of speaking in geek terms?
If you had dd-wrt, you would know.
Give me Classic Slashdot or give me death!
DD-WRT is custom firmware that supports more than 200 different devices. This page will tell you if your device is supported. Someone who wants to use DD-WRT needs to get one of those devices then install this firmware. To answer your question no, someone can not find a list of actual routers that are affect by this. It is likely though that only geeks have it installed and that means that it is more likely that they will patch it.
I have the non-wireless version of this router (BEFSR41)
Does anyone know if affects that too?
Slashdot needs Geekcode | Can anyone recommend any good SCIFI? My tastes: Foundation, Startide Rising, CITY, Ringworld,
DD-WRT just isn't compliant with the GPL on so many levels.calling it an "open source" firmware is a lie and a disgrace to the open source community.
The open source parts are OpenWRT.
... to add a firewall-rule fixing this issue.
what the hell is a DD-WRT? Can someone find a list of actual routers that are affected by this instead of speaking in geek terms?
Dude... This is Slashdot. What did you expect? :)
This should have all of the information you need:
http://www.google.com/search?source=ig&hl=en&rlz=&=&q=dd-wrt&aq=f&oq=&aqi=g10
If you don't know what is dd-wrt, then you are not affected. Those who have it installed it themselves. There are also a few companies selling routers pre-flashed with dd-wrt but again their market isn't the average joe. By the way, google is your friend.
Sorry about that.
Slashdot entertains. Windows pays the mortgage.
Greetings, I am a Linksys customers service representative. While I'm sorry to hear that you'll be leaving us, I'd like to remind you that if you have to wait for your paycheck in order to purchase a piece of home networking equipment, perhaps navigating flash based websites is the least of your worries. Have you considered going back to school?
I submitted this story more than 72 hours ago. It's been public knowledge for at least 96 hours. I know this isn't strictly a security site, but c'mon! Four days is too long for a remote exploit on one of the most widely deployed consumer router platforms.
This only affects users who enabled remote web management which is turned off by default. Remote web management is a setting that lets you access and change settings over the Internet which would be stupid to turn on in the first place except under special circumstances (i.e., router was behind other routers and you needed to change settings remotely.
FURTHERMORE, it only affects http, NOT https.. and if you are configuring network infrastructure settings or router passwords without a secure connection over the Internet, you shouldn't be managing networks.
It is a security issue, but this is way overblown... It's not going to affect 99.999% of the userbase.. I wish whoever submitted this fud would have actually read the article or understood the problem.
The bug resides in DD-WRT's hyper text transfer protocol daemon, which runs as root.
Whhaaat??? And the command looks like:
http://routerIP/cgi-bin/;command_to_execute
Whhaaat???
This is a bug even Adobe would be ashamed to admit. An http server, running as root, accepts arbitrary commands, without authentication, embedded in a URL? That's not a bug thats... that's a design flaw... no... that's... unbelievable!
Is there a legitimate reason that the http daemon runs as root? (It is for embedded devices...) Or that commands are accepted over HTTP GET like that?
Feel free to hate Linksys for any of the other reasons. I was royally pissed off for a long time by the relentless router reboots caused by poor interaction between the logging mechanism and BitTorrent; thankfully they released fixed firmware for that a few years ago. But I'm not going to drop them just because they overuse Flash.
$_ = "wftedskaebjgdpjgidbsmnjgcdwatb"; tr/a-z/oh, turtleneck Phrase Jar!/; print
NoScript actually mitigates this vulnerability. The ABE feature, in particular:
http://noscript.net/abe/
So although I added the firewall mitigation in dd-wrt, I was pleased to find that NoScript blocked the CSRF request before it even got to the router.
An easy work around for this is make the router URL IP address on the LAN side not easily predictable.
Stick it somewhere in the 10. private IP space block and any code injection not also stumbling on the correct URL and will instead get a "Server not found" error.
This will vastly reduce the chances of getting hit by any future as of yet undiscovered security problems using a URL, updated patches or not.
Comment removed based on user account deletion
Some jackass named brainslayer stole the openwrt source code, wrote a dinky (and obviously poorly written) web interface for it and branded the whole thing as "his" and probably said fuck the gpl and the golden goose it rode in on.
See: http://www.bitsum.com/about-ddwrt.htm
If you paid even a lick of attention to TFA, you'd note that this is a vulnerability in third party software. If you've got stock firmware, you don't need to update, and if you don't have stock firmware, you couldn't get the update from Linksys anyway.
$_ = "wftedskaebjgdpjgidbsmnjgcdwatb"; tr/a-z/oh, turtleneck Phrase Jar!/; print
I disagree. Security through obscurity works.
For example: in this case if you had already changed your router's IP address, it would be harder for the attackers to figure it out. For example if you use the 10.35.79.184, the same url that can exploit thousands of other dd-wrt routers (e.g. http://192.168.1.1/etcetc ), won't work on your router. So there has to be an attack specifically targeting you[1]. Which rarely happens unless you're famous or have made yourself infamous (or well-hated amongst hacker circles).
So you have more time to update your router or even have time to wait to see if the updates don't break other stuff first.
You're not as vulnerable to zero-day attacks as other people.
Same goes for putting running sshd servers on a different port. I could use port knocking or other other stuff, but so far running it on a different port works well enough for me.
I actually have my sshd server bound on an IP and port that's unreachable from outside, and my firewall has a rule to forward outside connections to it. This way if a mistake happens and my firewall rules get disabled/cleared, ssh and other crap from outside won't work.
[1] If a top hacker was targeting you specifically, they'd probably be able to pwn you.
For example:
1) I'm sure there are many zero-day browser/plugin exploits left (just look at how fast the pwn2own winners pwn stuff - they just sacrifice one of the zero-day exploits they have).
2) I doubt most ISPs have locked their BGP stuff down, so the attackers could use "BGP eavesdropping/prefix attacks" to hijack your connections.
With 1) and 2) you'd be merrily browsing your usual sites and pwned without noticing a thing- the hacker would just pass most of the traffic on, and just alter one or two connections to exploit the relevant browser bug.
I know its not a security setting, but this one bug that the DDWRT team won't admit to keeps me from using it. Here's the discussion:
http://www.dd-wrt.com/phpBB2/viewtopic.php?t=8895&postdays=0&postorder=asc&start=255
I got bit by that a few times, and reflashed to Tomato and haven't had ANY problems. Now, I now the DDWRT team claims its not a bug with their software, but rather an oddity with the hardware. Sooooo, if it ONLY happens on their build, and NEVER has happened to me on Tomato...sure sounds like it could be fixed in software....
there is no such thing as a "flaw" in Linux.
People, you're getting your kickers in a twist over a fault that only occurs, per TFA, when:
The exploit can only be used directly from outside your network over the internet if you have enabled remote Web GUI management in the Administration tab.
That is, you not only have to have installed custom firmware on your router, but you have to be sufficiently non-paranoid to have exposed its admin interface to the open Internet. Yes, people should patch it, but really... YAWN.
I went over the details one thing I am confused about is in this situation is the internal or External IP of the router that is Key here?
Power Corrupts,Absolute Power Corrupts Absolutely, leaving one person(group)in charge is absolutely corrupt.
I'm guessing you could add it to an href in a stylesheet reference, a script src, or even as a link target. I don't see why this would be limited to just images.
today is spelling optional day.
does not matter what firmware brand or version is on it, if i fucking can not check for an update then i assume it is old & obsolete and should be tossed in to the trash, or should i be happy just running a mystery box router not knowing if it needs updating or replacing or not?
Politics is Treachery, Religion is Brainwashing
DD-WRT had opensource roots, but now has been co-opted and turned into a proprietary product with a non-GPL license.
There are multiple GPL violations going on, and the funny thing is something like less than 5% of the entire codebase being offered as "DD-WRT" was written by its current owners.
Theft, pure and simple.
So a phishing scheme with CSRF will compromise the system!!! Critical?
And they did it by violating the GPL and stealing the work of thousands of others.
>Yes, there's a fix for this, but what is the likelihood of every person who owns a Wifi router fixing this flaw?
I would use your question to defeat your argument... I can't think of another user community who would be MORE security conscious regarding firmware updates. If you thought about this before posting, you would also have come up empty.
Even the dd-wrt "newbs" know to check for updates, if for nothing else than shiny new features.
>We talk about the dangers of homogeny, but this is exactly the type of thing that homogeny causes. All the routers with DD-WRT implemented to save costs, but in the end everyone is screwed.
This does not follow.
The dd-wrt flaw is caused by a STUPID programming error, and would not be mitigated by "homogeny". You might as well claim that "Windows would be more secure if there were more versions of Windows".
Firmware bugs are always nasty face-palm slaps of stupidity. It doesn't matter if you are open source or closed.
dd-wrt will have a lower ratio of developers:users compared to say Ubuntu. With fewer developers, a bug is less likely to be caught in code review, testing, or if someone walks into the error that they recognize it for what it is.
>Just because we love Linux doesn't mean that we should sacrifice the entire ecosystem to that love. We need to nurture other implementations to prevent this type of virus from wiping out our entire networking infrastructure.
Why do you think this is a "Linux" problem?
If you could take the dd-wrt code and run it on top of Windows (which you probably could..), it would STILL have the same vulnerability. Please learn what "CGI" is before conflating it with something else.
Look, the dev team obviously made some stupid design errors (httpd as root...). But also know now that dd-wrt has a huge community... folks will start looking REAL closely at the code for other security gaffes. Paid developers are starting to look at the dd-wrt code now, as some shrinkwrapped routers come with open source firmwares pre-installed.
Besides all that, you can't get any more fragmented (dd-wrt or not) than the router market.
Using this example as for why "Linux [would] sacrifice the entire ecosystem" is just rubbish, sorry to say.
It appears that recent versions of NoScript block this by default with ABE (http://noscript.net/abe/index.html)
Let's hear it for NoScript!
For you, I would recommend tossing it all in the trash.
.sig withheld by request
OK, that's funny. Well deserving of +5.
Indulge me here in a rant about spelling.
I'm sure we all agree that English spelling is hard and irrational. G.B. Shaw joked that "ghoti" is pronounced "fish": 'gh' as in "cough", 'o' as in "women", and 'ti' as in "nation". Story goes that English spelling was set in stone by the first printer who typeset an English manuscript: a dutchman who didn't speak the language.
Spanish did away with all that nonsense years ago. Words are spelled exactly as they are pronounced: "fotografia", etc.
Correct spelling is important for the following reason: it's a measure of your skill at observation. If you have been looking at the correct spelling of a word all your life, every time you read, how come you can't get it right?
When you get hired for a job, you will be expected to learn lots of things by observation; also you will be expected to pay attention to detail. Whether you can spell or not is a measure of your ability. It's a test of whether you understand the code, have had the proper upbringing.
Bad spelling means you are not able to pay attention to detail, and you're a slow learner. Does that sound like someone an employer would want to hire? Unless it's flipping burgers.
Poor spelling is like showing up at a hip venue, dressed in a 70's leisure suit: you just don't get it.
Caveat: English is not my native language (neither is Spanish), sorry for any typos.
Slashdot entertains. Windows pays the mortgage.
God, I love flashing out from under active systems. tldr: Hooray for updates that break wireless and then the whole router. Also, how moronic is it to have the default wireless config be "ddwrt" SSID with no security and no password?
I heard about this on Wednesday, but made sure I had remote admin off [why, God, why would you ever have that on unless you're doing weird voodoo with a wireless point NATting inside your internal network?] and sailed on, planning to takedown and flash sometime Saturday.
This news pushed it to the top of my cut list. People, I know this is old hat to many of you, but backup, backup, backup. I had in hand before I started:
* Settings backed up.
* A copy of the old firmware
* A copy of the new firmware
First flash seemed to go just fine, router said it was rebooting... and then didn't. Uptime still read 20 days. Issued web GUI reboot command... nothing.
Went to the closet, unplugged, replugged. Correct version confirmed, traffic flowing... wireless vanished. What the hell. Went in, redid all the wireless settings. Nope. But I do have a Linksys_SES_blahblah network in view. Nah. Couldn't be.
Unplugged the router again... nope, the SES net is still on the air. Good. Plugged the router back in... "ddwrt" net appears. Aw crap. Plugged the laptop in and changed the password and took the (unpassworded, unencrypted) net off the air. Fuck, that's a moronic default config.
To make a long story less long: flashed back to v24-sp1, reapplied my saved config, flashed the new config, it broke AGAIN. Thought for a minute, applied saved state, crossed fingers... and everything worked. Phew.
Now I have to go around unconfusing all the laptops. Desktops should be fine, since they (hopefully) didn't re-DHCP while the router was at 192.168.1.1 ...
if the answer isn't violence, neither is your silence / freedom of expression doesn't make it alright
Cmon folks, where's the milw0rm link?
http://www.milw0rm.com/exploits/9209
all you need to do is install the certificate when you connect the first time and it is no longer a problem.
If you train end users to install certificates so easily, you also train end users to install a certificate that a phishing site recommends.
Self-signed certificates are only defeated when you have no way to verify that they are who they say there are, not that the encryption is less secure.
I'm starting with the man in the middle. I'm asking him to change his ways. No message could have been any clearer: You could be communicating with a proxy.
It would be nice to know if this affects DD-WRT boxes that are not WAN-facing and are not in router mode.
I have three DD-WRT's in client bridge mode so as to provide wired connections throughout the house. They hop over WiFi to the WAN-facing router which still runs stock VxWorks. So I'd be inclined to think that my boxes are safe.
As for DD-WRT releasing a patch, gee thanks. I have two different (and old) versions of DD-WRT among the three devices and haven't touched them since installing, because upgrading requires lots of personal time with each device to reinstall and reconfigure and god knows what else and I simply don't have the time -- the whole point of setting up client bridges was to make life easier, not some sort of time-consuming exercise in obscure geek cred.
Terrorists can attack freedom, but only Congress can destroy it.
In my router, theres a option i just enabled called "Use Chuck Norris to round-house kick incoming hackers". Chuck Norris is in my router and monitoring 24/7. No one can hack my router, or even my pc. Chuck Norris is always watching.
In my setup I have my modem connected to my main machine, this runs a firewall and other machines are connected to it (from a second ethernet card). A few firewall rules fix it:
BBModem=192.168.0.1
# Direct comms with modem forbidden:
iptables -A FORWARD -d $BBModem -j DROP
# Forbid access to the modem except for pings (nagios needs this) and the modem manager user:
iptables -t nat -A OUTPUT -d $BBModem -p icmp --icmp-type echo-request -j ACCEPT
iptables -t nat -A OUTPUT -d $BBModem --match owner ! --uid-owner modemu -j DROP
The connections to the modem are forbidden except from the main machine (this is what the FORWARD rule does). Connections to the modem are only permitted from the user modemu, a user that I only ever use for the rare occasions when I need to tweak the modem.
I knew that something like this would happen and took care to avoid it.
You're doing it wrong.
zarthrag didn't ask for the points for his/her post.
i wish i could stop
This isn't on the desktop, it's on the router. What an idiot...
"attacks."
Those which target "you" and those which target "everybody."
Security through obscurity is great at insulating you from those attacks that target "everybody" (worms, etc.) because the attack is happy to exploit the common case and not bother with specificities, since that will still net it a bunch of bots/slaves/zombies/etc.
For those which target "you" specifically, security through obscurity will solve absolutely nothing.
Most pointedly (and many people on Slashdot miss this) the largest threat to the common Internet user is precisely of the former kind (the odd worm, being a part of a "net public") and not necessarily attacks that specifically want to compromise ONE machine or network somewhere that is the TARGET of the attack.
Security through obscurity is therefore a useful basic defense if you are not particularly interesting as a node.
STOP . AMERICA . NOW