WebDAV Buffer Overflow Attack Compromises IIS 5.0
rf0 writes "Well CERT is reporting a new overflow attack for IIS 5.0. Microsoft has released a bulletin. Better download those patches and fix another security hole." According to this CNET story, Microsoft says that this is already being exploited, at the very least since last Wednesday.
(looks at watch) its monday again... time to go patch my IIS
Well duh, "patch my IIS", it's monday isn't it?
Wax-Museum Fire Results In Hundreds Of New Danny DeVito Statues
WebDAV has been a headache for for a long time, until I decided to just disable it altogther. I realized I never had a purpose for it, personally, so I added the disabling registry key too all my servers. If you know any good that WebDAV does, I'd like to know about it.
Th
When they get a bug free Windows, they'll have to put some in just so bored /. readers have something to laugh at....
If you're happy and you know it read my blog
I don't know why anyone uses it anymore. I'm switching back to Morse Code. Who's with me?
If you listened to the Gartner Group, you stopped using IIS last year.
If you didn't, well, get with the program!
Eventually MSFT will have to deliver your "mission critical" ASP runtime for Apache, and the world will be a better place because of it.
Napster-to-go says "Fill and refill your compatible MP3 player", which is a lie. It's not MP3. It's WMA with DRM.
Cue 2,000 microsoft bashing messages...
Slashdot is not the place you want to read about things like this, if you really need / want to be on the ball. You need to subscribe to bugtraq and nanog. You'd be surprised... it's like knowing the future!
Well, if they are going to have bugs, it is not that bad of a thing as long as they are patched promptly. Then again, many admins do have a tendancy to run unpatched machines.
It looks like this was the exploit used to hack into an Army machine recently. Check out the link from MSNBC here.
Comment removed based on user account deletion
I was ready to uninstall IIS when it occured to me that Exchange 2K needs it. I was ready to uninstall Exchange 2K when I realized users would not be able to function. Whew, luckily I came to my senses...
>Why is the code that the web server has access to
>change allowed to take over the system?
Because it is "trusted".
It seems quite likely to me that that was an under-reported version of this incident reported on MSNBC, that permitted an intruder with apparent quite-hostile intent onto US Army sites.
Now, I'm no anti-any OS, I like them all, but what about the latest Sendmail vuln? Or even the one in older versions of BIND? Isn't it true to say that ALL OSes are equally as vulnerable? During the brief time I was on the Redhat Network, I got at least two or three updates a day telling me the sky was about to fall in if I didn't patch my server soon.
I treat all servers fairly, regardless of background, age or reliability :-)
Between getting rooted and being automatically subject to license agreements, I'd rather get rooted.
What's this Submit thingy do?
If CERT would just move their headquarters to the IIS devs room in redmond, that would probably save a lot of money for CERT. They should be a part of the regular IIS dev team.
It says near the bottom that IIS systems with URL scan which is part of the lockdown utility are not affected by this.
/.'s don't like microsoft and thats sad because microsoft is the driving company behind many many jobs. The arrival of windows pushed the last boom. No questions about that. Unix had been around for 20 yrs and no boom. Windows and the net and look at how things accelerated..why..because ma/pa people use windows..not *nix. Just the facts.
Why would you run a IIS server without using the lockdown utility??
We (large corporation) have been using IIS servers and without a problem. With Lockdown/urlscan there are no problems at all. The logs show people trying to get in but being rejected.
I think this story is a bit overblown. It appears that most
cheers
John
I've asked this everywhere, maybe someone will answer.
... We don't run the default config. We've customized it, as have many shops. I can't find information on _which_ aspects of URLScan provide the protection - I'd like to know if our customizations have left us out in the breeze.
The MS advisory states that a 'default' URLScan will protect against this. Well
Anyone know?
And I thought that Penguin on the Microsoft home page looked at little out of place.
/^[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,4}$/i
The exploit has been in the wild since last Wednesday. Microsoft has known about it since that time. Five days to a patch is really good for Microsoft but, the last Apache bug was fixed on the day of discovery, long before any exploits appeared.
Typically GUI config apps don't give you all the options either. They give you the most common ones. The rest are buried (in the case of Windows) in the registry. A pretty GUI just gives the _illusion_ that you're in control.
/etc/ssh/sshd_config). A bad config file will list only options that are different than the defaults or not included in the defaults.
A text file can hide options too, but not in the same way. Generally, applications have many defaults that don't need to be defined in the configuration explicitly. A good config file will list most of these anyway, even if commented out (example
That being said, there is no reason that someone putting a server on the internet should be afraid of editing a text file. Even in Windows! Notepad is just fine...
If you're playing on the public internet, you have to put up or shut up (know your shit, or accept the consequences)...
Obviously though, this issue has nothing to do with the WebDAV exploit. Even the best admin is at the mercy of the quality of his/her software (whether UNIX or Windows or $your_os).
-Ben
The best way to evaluate this bug is to consider an equivalent attack against competitors. In this case, the main competitor is Apache.
Cracking Apache in this way would not give you root. While you might be able to get root by using some other local exploit, it's not the slam-dunk that it is on Windows.
Furthermore, careful admins can run Apache in a sandbox called a "chroot". Properly set up, this means that the attacker can't get to the rest of the system; all they can play with is the Web site.
So, in summary:
Its all Microsoft's fault. Its crap software.
That's a pretty good assessment. The bug itself is a mistake lots of other people have made, but the severity of the mistake isn't.
I've mounted WebDAV filesystems with my iBook, served by a Solaris machine with Apache and subversion. Even mounts under /Volumes, so programs don't even need to be aware of it; the XP "redirector" would fill this same role. (UNIX people can think "virtual filesystem switch" when you hear "redirector".)
If you just want a DAV filesystem, see mod_dav_fs in any recent Apache. (Which DOES run on Windows, for everyone who wants to toss the OS out with the webserver. Not that I'm a fan of Windows for anything, but you can run non-MS servers on the thing.)
All seven of them? All long fixed? Page not updated since January 23, 2003? I'd LOVE to send them that. Comparing that to the long and varied string of IIS compromises/failures/destruction would be enough to get even the pointiest headed boss to make the switch. Good idea. Thanks!
Your first three paragraphs were quite good and interesting.
Your fourth is full of idiocy.
I think this story is a bit overblown. Umm, not at all. It is quite a serious incident.
It appears that most /.'s don't like microsoft
Tell me, is this the first time you noticed that? Not much analytical thought going on upstairs, is there?and thats sad because microsoft is the driving company behind many many jobs They suck a very disproportionate chunk of money out of the market, they are in a position where innovation is much too risky, they are in such a controlling position that they are even greatly profitable against the trend of the rest of the market. The IBM PC pushed the boom. DOS and Windows have ridden the wave and placed Microsoft in the position of punishing any software company and they keep expanding -- that becomes too successful in the name of feeding their monstrous appetite. DOS and Windows sucked for many years, but were small and people ignored the control that was being given such an unworthy producer.
They drive their own jobs with lots of marketing and billions to spend on research, which would be much better used in a large market of competing thriving software vendors, like we had before Microsoft used monopolistic business models to destroy them all. If you become successful, Microsoft is guaranteed to take it away from you. That is successful for Microsoft and creation of Microsoft jobs, but far from good for America or the world.
The arrival of windows pushed the last boom. No questions about that. Unix had been around for 20 yrs and no boom. Windows and the net and look at how things accelerated..why..because ma/pa people use windows..not *nix. Just the facts.
You mentioned facts? The boom came on the backs of now-defunct companies who pioneered their fields, such as word processing, networking, compilers, OO Languages, etc. none of which was pioneered by Microsoft. But Microsoft was good at using software ownership to take these things away from their innovators. And now you have come full circle to why many developers are congregated here and do not always hold Microsoft in high regard.
But you knew that, didn't you? Perhaps you are AC because your large company is Microsoft?
If you have to use IIS for some reason, put a Squid proxy running on your favorite OS in front of it. It will save you a lot of trouble.
The problem with this patch is that it wasn't found by a white hat and submitted. It was discovered by people getting hacked and calling MS asking WTF. In cases like that, 5 days isn't really that bad. In cases where an exploit, along with vulnerability code, and a description are fed to devs on a platter, open source or not, it makes the task 10x easier. When you have to figure out what is going on while under fire, and in a hurry, things get messy. That said, you can hack a lot of systems in 5 days with the right script.
-Charlie
It is a concrete fact that that no MacOS based webserver has ever been hacked into in the history of the internet.
The MacOS running WebStar and other webservers as has never been exploited or defaced, and are are unbreakable based on historical evidence.
Okay, this is ludicrous. I ran Webster and other macintosh web servers in the 94-96 time range for a significant test prep company in NYC. They are just as insecure as any other web servers. The insecurity comes from the CGIs, not the static content. But who cares...programmer level or system level insecurity has the same result.
The claim is false - i've done this myself to prove a point.
Why is is hack proof? These reasons :
1> No command shell. No shell means no way to hook or intercept the flow of control with many various shell oriented tricks found in Unix or NT. Apple uses an object model for process to process communication that is heavily typed and "pipe-less"
Sure, Pre-OSX Macs have no CLI really, but does it make a difference if you can disable, DoS or take control of the system, even? Sure, they are configuration mistakes. You can make those with Apache/*nix or IIS/win32 too. I've seen Timbuktu installed with no firewalling and simple plaintext password protection of the most trivial kind. I've seen CGIs that allow system control of various sorts, put in place by the same type of people who love the ease of use of macintoshes. Security?
2> No Root user. All Mac developers know their code is always running at root. Nothing is higher (except undocumented microkernel stuff where you pass Gary Davidians birthday into certain registers and make a special call). By always being root there is no false sense of security, and programming is done carefully.
Sure, all Macintosh programming is done carefully as a result.
By your estimation, access controls are a complete waste. I'm sorry, this doesn't hold much water. I could use the same argument to state that Wintel boxes are better web servers. We all know how that pans out.
If all Macintosh programming was so excellent, those Type 1 errors where you have no choice but to restart would be a thing of the past, right? I still see them. Though I have to admit the car crash sound is better than a blue screen.
3> Pascal strings. ANSI C Strings are the number one way people exploit Linux and Wintel boxes. The Mac avoids C strings historically in most of all of its OS. In fact even its ROMs originally used Pascal strings. As you know Pascal strings (length prefixed) are faster than C (because they have the length delimiter in the front and do not have to endlessly hunt for NULL), but the side effect is less buffer exploits. Individual 3rd party products may use C stings and bind to ANSI libraries, but many do not. In case you are not aware of what a "pascal string" is, it usually has no null byte terminator.
Pascal strings have a single length byte and can't handle anything longer than 255 characters. Many http requests are going to be longer than that. Obviously, Webster and other Mac web servers aren't using those for everything, though admittedly the system calls require them in many cases. Your argument about this preventing buffer overflows is not very convincing as a result.
#4 must be a new feature because you could do just about anything cgi-wise with a macintosh in my days of futzing with them. Swiss cheese.
#5 - Applescript. Many CGIs used to use those as a control interface and obviously resource protections don't apply. They probably still do...
#6 - I fail to see how the Mac's zoned memory structure is any more protective than the hardware segmented memory protection of Intel (see Type 1 errors above), stack return addresses be damned. I'd be interested in any proof of this.
That is why the US Army gave up on MS IIS and got a Mac for a web server.
Not at this bas
HBI's Law: Frequency of calling others Nazis is directly correlated with the likelihood of the accuser being Communist.
Incompetent sysadmins still are the weakest link.
I don't agree with that. Microsoft itself can't keep up with the patch schedules; its servers regularly get hacked. Who has more resources than Microsoft? Nobody.
The fact is that if you are running a mission critical server you must test before deploying a patch. That takes time and money that the IT group has in short supply these days.
Then there is the issue of Microsoft's marketting - they sell IIS as the easy to use 'zero maintenance' lowest TCO choice. False advertising in this case.
Sure, another MS exploit. Seems to be one almost every week, and it sucks.
/. chose to post this article, but reject an article I submitted yesterday about a very serious security hole in Opera - Opera describe it as "extremely critical".
/. displaying an unfair bias?
What I do find interesting is that
I'm not griping about having my story rejected, I've had many rejected and a few accepted, and that's the way things are, no problem. What I am questioning is the editorial bias. Here we are at a website which probably has one of the highest concentration of Opera users of any website in the world, and they chose to not post a negative story about "the good guys" (which has exploits in the wild) but did choose to post a negative story about "the bad guys".
Just more of
Read reviews of shopping cart software
This post is a lot like the "BSD is dying" troll that's just not going away. Every once in a while some idiot posts it, and a few other idiots moderate it up. Anyway, on to debunking.
The MacOS running WebStar and other webservers as has never been exploited or defaced, and are are unbreakable based on historical evidence.
Really? Is that because it crashed every time someone tried to access it? Considering that MacOS does not even have preemptive multitasking or proper memory protection, it's not that hard to imagine. MacOS has a really nice GUI, but in terms of technology it is behind even Windows 95.
In fact in the entire SecurityFocus (BugTraq) database history there has never been a Mac exploited over the internet remotely.
Hmmm, there are no exploits for DOS either. Are we to conclude that DOS is the most secure OS ever?
No command shell...
BFD! If you gain control of a process (through buffer overflow, for example) and manage to execute your own code, you still have complete control of the system. Heck, the current bug in IIS has nothing to do with exploiting shell.
No Root user.
The troll is only getting better. Ladies and gentlemen, it has come to our attention that the competitors' cars have malfunctioning seatbelts and thus cause injuries to passengers in a collision. Our MacCar has no seatbelts, therefore it is not vulnerable to collisions.
You know, IIS also runs as root (or rather LocalSystem in NT terms). By always running as root there is no false sense of security and programming is done carefully. Doesn't seem to help though...
Pascal strings.... As you know Pascal strings (length prefixed) are faster than C...but the side effect is less buffer exploits
...and they are limited to 255 bytes in length. (For those who did not program in pascal, the first character in the char array represents the length of the string. Since unsigned char's maximum value is 255, that's the maximum length of the string). Anyway, a buffer overflow occurs when you try to write more data than you can fit in the buffer. The only way a compiler could prevent that is if it inserts length checks before every write, and either truncates the string or terminates the program. It's been a loooong time since I touched pascal, so I don't remember how it handles that, but in any case it's irrelevant: is WebStar written in Pascal? In fact, besides some legacy code in MacOS, is anything at all written in Pascal these days?
Macs running Webstar have ability to only run CGI placed in correct directory location and correctly file "typed" (not mere file name extension).
Unix running Apache have ability to only run CGI placed in correct directory location and correctly file "typed" (not mere file name extension). (You can't run some random data).
Macs never run code ever merely based on how a file is named. ".exe" suffixes mean nothing!
Unix never run code ever merely based on how a file is named. ".exe" suffixes mean nothing! (You need to set executable permission first).
but the best part is that mac web programs and server tools do not create files with resource forks usually. TOTAL security.
Yeah, and when I leave the house I put my keys under the rug usually. TOTAL security. I mean who would possibly figure out how to create "resource forks" and such?
Stack return address positioned in safer location than some intel Osses.
That is the property of the hardware, not OS. Do you undestand the distinction?
7> There are less macs, though there are huge cash prizes for cracking into a MacOS based WebStar server (typically over $10,000 US). Less macs means less hacker interest
What happened to 5> and 6>? Were those argument too stupid even by your standards?
Anyway, in this paragraph you are contridicting yourself: on the one hand you are claiming that macs are safer because there is less
___
If you think big enough, you'll never have to do it.
Sure, I can't wait to hear it...
- WebDAV is *nothing* like a VPN.
A VPN provides secure access to a remote network via one or more untrusted networks, typically the Internet. Once a VPN is established, the local endpoint has access to the remote networks's resources including, but not limited to, file, mail, directory, print and web servers. Existing protocols such as IMAP, POP, HTTP, LDAP, NFS and SMB can be used over the VPN in a mostly secure and transaprent manner.
WebDAV is an extension to HTTP - The Hypertext Transport Protocol. HTTP is deisgned to transport hypertext (hence it's name) and other media over via TCP. WebDAV provides distributed authoring and publishing extensions to HTTP to allow, amongst other things, remote collaboration. Using WebDAV for a network file system is akin to using FTP for the same. It is a bad idea.
=> WebDAV is nothing like a VPN.
- "using any number of authentication schemes" does not "lock down" anything at all.
- It doesn't matter if you are running it over HTTP or HTTPS. Both are the wrong protocol to use for filesharing. Just like using SOAP over HTTP(S).
Doing everything via HTTP, whether running plain text over port 80, encrypted over port 443 or any other combination is bad practice. One of SOAP's (and WebDAV's) "features" is that it allows you to do stuff over HTTP that would usually otherwise be blocked by a firewall. Want to do RPC? Sure! Just tunnel it through port 80! Want to do file sharing? Sure! Just tunnel it through port 80! This is seriously screwed up. It defeats a primary purpose for which firewalls were invented in the first place; to limit access to dangerous services. Not to mention that using HTTP for everything is a serious architectural design flaw as well.
Putting authentication in front of HTTP and/or tunneling it over SSL does not fix these problems. This IIS exploit du-jour is a perfect example of such.
- Web applications are irrevalent to network security.
A web application should be well designed and implemented, with security in mind. It should be deployed on a network which is properly secured. It should be running on systems which are properly securied. Making a web application secure does not make a network secure (and vice versa). "Irrelevant" is probably a too strong a word, but the security of a network should never be dependent on the security of a web application.
/mike
-- "So, what's the deal with Auntie Gerschwitz et all?"