black-box implementation of CryptProtectData/CryptUnprotectData

Kees Cook kees at outflux.net
Mon Apr 4 11:42:25 CDT 2005


On Tue, Apr 05, 2005 at 01:07:14AM +0900, Mike McCormack wrote:
> It's probably better to keep it consistent with what the rest of Wine does.

I'd really like to push back on this.  The traces become unreadable as 
the various function names change.  I think the debugging as I have it 
is more useful than how it looks with only "TRACE" calls.  The top-level 
function spits out a "TRACE" to identify the caller, and then all the 
helper functions report the data structures.

> It seems like you need to investigate what it does on Windows and the 
> MSDN description of the function a bit more.  The description on MSDN 
> indicated that they used a per user key generated when the user logs in.

I already have, and decided it was best to avoid a more detailed 
investigation for fear of DMCA joy.  They key against at least user, 
machine, and time, since multiple calls with the same plain/entropy 
produces different ciphers.  My implementation intentionally avoids any 
encryption at all.  :)

I like to think of it as a good "first step" to getting the real 
functions.  With what I've got, a program can run normally.

I'll be sending "version 2" of my patch in a little while.  It's got 
your suggestions incorporated, and a small bug fix.

-- 
Kees Cook                                            @outflux.net



More information about the wine-devel mailing list