How Does Win2k's Encrypted File System Really Work?
cyberbrian asks: "At work, I administer Windows NT 4.0 and 2000 servers and I have been researching Win 2000's EFS (Encrypted File System) and I have detected some Very Odd Behavior. I am currently leaning towards using PGP Disk instead of EFS but I really want to know what is going on here. For instance, one of the tests I made is that I backed up an encrypted file and restored it to a FAT partition. The resulting file had zero bytes. For true encryption, shouldn't there be data in the file, but scrambled according to the encryption algorythem and key file? IMHO, Microsoft may not be using encryption at all, but instead perhaps the "encryption" is actually a hidden NTFS deny/allow permission that is tied to a certificate. Has anyone tested this by trying to decrypt a EFS file under Linux?
Also, I would be very interested in any URLs people could point me to where this is explained in detail."
Actually I wouldn't be surprised if it was only a flag and they didn't really encrypt the data. First, when my 2000 Pro system crashed last winter, I simply reinstalled 2000 Pro onto the same drive. The new administrator account had access to all the files on the hard drive, whether they were "encrypted" or their permissions were explicitly for another group. It seems that the actual files are simply on the disk, the installed instance of the OS is what performs access control, so there is no real alteration of data with permissions or encryption. However, the compressed files were still compressed when I installed the second time.
Thanks,
Travis
forkspoon@hotmail.com
I guess that people aren't jumping in head first into this one means that you've really asked a good "Ask Slashdot" question -- one that 80% of the guys can't answer. No one's even brave enough. Congrats! Oh yeah, looks like maybe I got 1st post
Put identity in the browser.
You might want to check out bugtraq archives or securityfocus.com for vulerabilities in the EFS system. I've seen it come up a few times in the past though because I don't use it I paid little attention to what they had to say about it. It -does- act weird, and I'm pretty sure it's a rather weak when it comes to actually protecting any data.
Justin Buist
Microsoft.com has no information that I saw on EFS that lists what level of encryption is used. It has continual references stating that it uses public key encryption. The entire thing is user based rather than key based. I wouldn't trust it, even the most dim users would be less likely to give out that key to the super-secret accounting document than 'just' thier login password.
Google wasn't much more help. Admittedly I
didn't look too hard, but there were a few hits on googlge from a newsgroup discussion of "pgpdisk vs. win2k efs" might want to find those and keep an eye on 'em.
This like on arstechnica has some information on Windows 2000 EFS:3 .h tml
http://www.arstechnica.com/paedia/n/ntfs/ntfs5-
To quote from the above article:
"EFS uses a public key crypto scheme, which uses a public and private key. Encrypting a file will cause EFS to assign that file a randomly generated FEK (file encryption key). The user that encrypts this file does so with their public key, but to decrypt that file requires the usage of their private key to authenticate past the file's randomly generated FEK. DDFs (Data Decryption Fields) and DRFs (Data Recovery Fields) exist as NTFS attributes, storing a list of FEKs. Public and private keys are stored separately from the FEKs. "
but also note this warning on www.sysinternals.com:
"Even when you encrypt files with Win2K's Encrypting File System (EFS), a file's original unencrypted file data is left on the disk after a new encrypted version of the file is created."
1. It is a public key encryption method.
2. It is linked to your SID. Therefore no other user can read your files unless they have access to your account.
3. When you encrypt a file, the file is saved in plain text, then encrypted. Therefore, there is a chance that the data is unencrypted on disk somewhere.
I've noticed strange behaviour with this file system so I don't use it often. Most of the behaviour had to do with copying files to and from an encrypted directory. I would get frequent failures (such as "file is in use"). Also, since for some reason my temp directory ended up encrypted, some installshield based programs failed to install.
I am specifically talking about Win 2000 here. I have not yet used it on XP.
Whatever the theoretical strengths and weaknesses of NT's encryption software, what really matters is how the software works in the real world. Are there bugs? Back doors? How hard is it for an unauthorized person to infiltrate back door code? Etc.
And of course we can't answer these questions, because we can't look at the source code. Someone in Redmond has presumably done that. I don't cop the usual cynical attitude towards MS, but I'm still sceptical of any system verified only by people with a vested interest in it.
Which isn't to say that OSS cryptography is necessarily any better. In theory, everybody who uses PGP encryption can either verify the source code or get fingerprinted executables from somebody who has. But how many people actually do that? Or make sure that the software isn't patched after it's installed?
In the end, the question "How strong is this encryption" is less important than "How much security do you need, and how much trouble are you willing to go to to get it?" I've seen banking web sites where they insist that the customers use browsers with 128-bit encryption -- and then use 4-digit PINs as the sole means of user verification! That's silly.
Here's a more relevent example. I have some files on my laptop I would not care for any random stranger to see. But they're not sensitive enough to require really extreme measures. They're just rather personal. If I were running NT on the laptop (I used to, but the system isn't really powerful enough), I'd have no qualms about uses NT encryption. So instead I use PGPdisk. Which is theoretically more secure than NT, but the way I use it (fairly weak passphrases, unverified software) it's not really any more secure than it would be under NT. But that's fine. If I ever become a CIA operative, I will certainly take stronger measures.
...you can make a baseless disparaging comment (refuted by a quick search, BTW) about MS without any backing and be marked 'interesting' for it. Try posting TRUE negatives about Linux, and you're modded down.
Loooooooooooove the moderation guys. Keep up the good work, pretty soon you'll silence all the reasonable voices.
The big thing that I didn't like about the encryption (implementation-wise) is that it didn't obscure the file names. I would have preferred that each user directory would be a total black box to all other users.
I didn't know that much about the algorithm (and know very little about encryption anyway_, but figured it would be better than nothing. Still, I would prefer something that works well better than something that works poorly or not at all.
I've had even less luck with Windows 2000 NTFS file system encryption. Every file I "encrypt" with my account (it has administrator privlidges) is viewable by every other user of my computer no trouble at all. Open it up, copy elsewhere, delete, modify, whatever, done with 128-bit encryption over it. Aside from the fact that those users *shouldn't have access* to the files (I used NTFS resource-level permissions to deny all except myself for this resource) it "works" in that it doesn't kill things...*frustrated rant off*
ROT13 of course!
I mean, Microsoft have used 'encryption' of that quality in the past, why improve now?
This post is not informative, and should not have been moderated as such.
It is interesting, as it talks about one person's opinion on Win2000's encryption. However, it contains no real information as such, thus should have been moderated up as interesting.
Try looking in the "Windows" section of the Reading Room from SANS website.
Specific articles of interest are:
Encrypting File System Primer , from July 6, 2001
and
Windows 2000 Encrypting File System , from July 27, 2000.
Both of these articles are heavily referenced with links to other techincal source material about Windows EFS. Most notably:
Mark Russinovich, "Inside Encrypting File System, Part 1", June 1999, Windows 2000 Magazine
Mark Russinovich, "Inside Encrypting File System, Part 2", July 1999, Windows 2000 Magazine.
This auto satisfy any questions about the limited protection offered by EFS in stand-alone and default modes, as well as provide direction for configuring EFS to operate with a very decent level of confidentiality and availability.
"Flyin' in just a sweet place,
Never been known to fail..."
Oh...right...never mind :)
Is there some way to protect my Win2000 installation in such a way that someone who steals (ok, confiscates) my computer will not be able to read the registry?