[pubcookie-dev] Security context fixup for Win32

Nathan Dors dors at cac.washington.edu
Tue Feb 17 15:49:59 PST 2004


Those mods make sense to me. (Thus, they must be minor.)


On Tue, 17 Feb 2004, Ryan Campbell wrote:

> There should only be four minor changes outside of the Win32 #ifdefs in
> security_legacy.c:
>
> ! pbc_cookie_data *libpbc_unbundle_cookie(pool *p, const security_context
> *context, char *in, const char *peer, const char use_granting)
>
> (to make definition consistant with declaration)
>
>
> !     fp = pbc_fopen(p, cryptkey, "rb");
>
> (Windows needs the b for binary files, POSIX ignores it)
>
> !     if( cb_read = fread(context->cryptkey, sizeof(char),
> PBC_DES_KEY_BUF, fp)
> != PBC_DES_KEY_BUF) {
>           pbc_log_activity(p, PBC_LOG_ERROR,
> !                       "can't read crypt key %s: short read: %d", cryptkey,
> cb_read);
>
> (cryptkey was mistakenly keyfile, added cb_read for extra debugging)
>
> !         strlcat(buf, DIR_SEP, 1024);
>
> (Windows likes backslash)
>
>
>
> Note that I've not yet implemented different security contexts for the
> filter.  I'll get on that next.
>
> I also had to lose some typchecking and typedef pool to void due to an
> include file catch-22.  I'll try to repair that as well.
>
> 	-Ryan
>
>
>
> _______________________________________________
> pubcookie-dev mailing list
> pubcookie-dev at u.washington.edu
> http://mailman.u.washington.edu/mailman/listinfo/pubcookie-dev
>


More information about the pubcookie-dev mailing list