Slashdot Mirror


Microsoft Attempts to Secure IIS

billmaly writes: "Yahoo has this article about trying to make IIS more secure. Among steps is to have it install in its most secure state, putting the onus on sysadmins to remove it from that state. It looks like Microsoft may be trying to do the right thing from a security standpoint, at least on paper."

4 of 392 comments (clear)

  1. Re:Heh, relying on IIS admins? by McSpew · · Score: 5, Informative

    These are the guys who have still be unable to figure out that the Buffer Overflow, etc. patches are available to them on Windows Update--or that almost all the new exploits would be fixed by getting Service Pack 2.

    Um, I think you've completely missed the point. First off, not all patches are available from WindowsUpdate. In fact, precious few are. Most of the updates from WindowsUpdate apply to IE, not IIS. Second, there are a large number of exploits that have appeared since SP2 shipped. I have personally installed nearly two dozen Post-SP2 hotfixes to one server. I average between 8 and 10 post-SP2 hotfixes per server.

    Mind you, actually keeping up-to-date on hotfixes actually became possible with the release of HFNETCHK. Before then, it was virtually impossible for any normal sysadmin to keep up with all of Microsoft's patches and apply only the ones they were supposed to. Also, before the release of QCHAIN, it was a horrible and time-consuming process to apply hotfixes to a server, even when you knew which ones to apply, because each hotfix wanted its own reboot to complete and you couldn't just apply them all and then reboot once.

    I actually use WindowsUpdate, HFNETCHK and MPSA to check and make sure I catch all possible vulnerabilities. I've found that it's not uncommon for each one to catch something the others did not.

    Even with the three tools I listed above, properly securing IIS (or any MS server) is still a royal pain. The damn things come preconfigured with their flies completely unzipped. MS's IIS Lockdown Tool won't even run if you've already taken some steps on your own to manually lock down IIS, and even if it does run, it doesn't turn off the "../" parent directory functionality that's enabled by default. You still have to go into IIS Admin and turn that damn thing off manually.

    Let's not pick on IIS admins unfairly. Many of them prefer Linux and use it at home, but have to use IIS at work because that's been mandated. Debian makes it easy to stay patched and does a half decent job of implementing default security, but MS leaves everything wide open by default, makes it damn difficult to lock any system down effectively, installs unnecessary services by default (and won't even let you uninstall some of them) and has a half-assed mechanism for rolling hotfixes and patches out to customers.

    Microsoft needs something like Symantec's LiveUpdate, which allows sysadmins to roll out tested updates to internal users on their own schedules, without physically touching every system on their networks. Yes, there are IIS admins out there who are jackasses, but there are plenty of overworked sysadmins out there who'd love to properly secure IIS, if only it weren't damn near impossible.

  2. Re:What is this? by Tackhead · · Score: 5, Informative
    > "It looks like Microsoft may be trying to do the right thing from a security standpoint"

    In other news today, Satan said to be interested in joining US Figure Skating Team. "Yes, this is a serious bid; we've already started training now!", said the Dark One, executing a perfect double axel over what was once the Ninth Plane of Hell.

  3. Re:Heh, relying on IIS admins? by Maserati · · Score: 5, Informative
    If you do that, you run a (small but real) risk of a versioning problem with DLLS touched by more than one hotfix. This can result in early patches being overwritten by later patches, which leads to live vulnerabilities on machines you thought were secure.


    In the spirit of hfnetxchk.exe there is now a tool to apply multiple hotfixes without rebooting, qchain.exe


    To use this, you write a .bat file to apply the hotfixies from the command line with the "no reboot" switch. Them qchain.exe does the cleanup and ensures that the right files end up installed before rebooting once.


    Or at least that's the theory. The hotfixes I was working with didn't all honor the "no reboot" switch. I don't have the list handy (I've since been laid off and don't have access to the network directory with the .bat file I was working on), but I had a roughly 40% fail rate. Your mileage may vary.


    The really keen thing to do, for desktops anyway, is to use hfnetchk to identify machines needing hotfixes, a script to customize the .bat file for qchain.exe, and SMS to push the file into a login profile managed by Active Directory. This wouldn't be too great for servers, since you don't want random reboots, but much of the deployment can be automated - just keep the reboots within your existing maintenance schedule. For bonus points, have every patch logged to your maintenance log (you do keep one, right ?).

    --
    Veteran, Bermuda Triangle Expeditionary Force, 1992-1951
  4. Re:Heh, relying on IIS admins? by McSpew · · Score: 5, Informative

    The problem is that parent paths aren't automatically blocked from going any higher than \InetPub\Webroot, which to me is a huge security hole. Yes, properly-secured NTFS ACLs on the filesystem will prevent any real damage from occurring, but NT and Win2k default to EVERYONE|Full Control on all filesystems, both at the NTFS ACL level and at the share level.

    Look, if it were possible to just fix your server once and then not have to go back and fix the same flaw again (and again and again...), more NT systems would be properly patched, but Microsoft seems to have gone out of its way to hose NT 4.0 customers. Win2k does finally let you patch your install folders with updates from the service packs, but NT doesn't let you do that, and there's no good reason for that. Any time you add or remove a service in NT, you end up putting the install CD in. The second you do that, you have to re-run your service pack and reapply all of your hotfixes.

    IIS 4.0 is the current version of IIS for NT 4.0. Let's say you decide you want to build an Outlook Web Access server for your organization and your company hasn't moved to Win2k Server yet, so you use NT 4.0. How do you get IIS 4.0 on that server? You use the Microsoft Option Pack 1 for NT 4.0. Guess what? That thing installs an insecure version of MDAC, an unpatched version of IIS and a host of other crap you may or may not want (such as the MS transaction server and indexing). All of it is incredibly old and almost all of it has to be patched and repatched the second you install it.

    So, here's how you build your server: You install NT 4.0 and apply the latest service pack (SP6a because SP6 had heinous bugs). You install IE 4.0 or newer. Then, if you're smart, you install a version of MDAC (2.5 or newer) that sets proper registry security and is reasonably recent and free of its own security holes. Then you install the Option Pack so you can have IIS 4.0 and which insists on trying to install MDAC 1.5--be sure to deselect RDS because that's a huge security hole that Russian hackers use to steal credit card numbers. Now, you're ready to install Outlook Web Access. Think you're finished? Ha! Not even close. Next, you run HFNETCHK to find the enormous list of hotfixes you've got to download and apply. Each hotfix is in a different place on Microsoft's website, and there isn't a convenient tool you can use to just go and download the patches you need and store them in conveniently-labeled folders. Then, you download QCHAIN so you can apply those patches without having to reboot after each one. If you're smart, you'll use WindowsUpdate and MPSA to make sure you're not missing anything.

    By the time you've finished with this minimum effort, you've spent no less than four or five hours just installing NT, IIS and the hotfixes, not to mention the hour or two it takes to install and configure OWA. Now, at this point, all you have is a product that's reasonably free of serious buffer overflow security flaws. You still don't have a product that's actually remotely secure. Now, you have to go and fix all of MS's idiotically optimistic NTFS permissions and find and disable any unnecessary services. Maybe you run MS's IIS Lockdown tool, which removes the IISamples folder and a few other obvious things.

    By now, you've probably spent at least 8-12 hours building this server, patching the holes and fixing the default security settings.

    So, you've patched the living hell out of the server and it's ready to go. You're immune to attacks, right? Almost certainly not. New holes are found in IIS every week and keeping on top of them is a huge job even if you have no other job responsibilities. Add to that the fact that any time somebody adds or removes a service from NT, you have to reapply the latest service pack and all the hotfixes (in order) and then reboot, and you've got yourself a nightmare.

    Let me be clear.

    There are enormous numbers of jackasses running IIS who can't figure out how to toast bread. However, there are plenty of overworked sysadmins who're only trying to keep their damn networks running who find it nearly impossible to keep their IIS servers patched and locked down because Microsoft makes it so damn difficult.

    Yes, matters get a little better when you're running Windows 2k server, but things don't turn into a panacea just because you can patch your install media and some hotfixes don't require reboots. Microsoft still releases at least two or three patches for Win2k and/or IIS every month (sometimes they release that many in a week). They still automatically set file and share privileges too optimistically. They still install dozens of unnecessary services by default. They still force you to have unnecessary applications installed by default that you can't remove without pliers and a blowtorch (OutlookExpress). In short, they still don't take security maintenance seriously and until they do, it'll be tough for even conscientious admins to keep up. Newbies, idiots and lazy bastards won't have a hope.