Re: [AD] Todo?

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


Vincent PENQUERC'H <vpenquerch@xxxxxxxxxx> writes:
> this causes problems because the password system is global to all 
> packfiles. I could easily get around it, and that is what I did, but I 
> think it would be cleaner to get this done in the lib. If I recall well, 
> it would just be a matter of adding a password field in the packfile 
> structure.

Hmm, you mean so that the current password would be copied whenever a file 
was opened? That's a good idea, and not hard to do at the same time as 
making other changes to the encryption system. It would be a subtle change 
in behaviour, but would only affect programs that changed the password while 
a file was open, and that doesn't work properly at the moment in any case 
(in particular, changing to a shorter password in the middle of reading a 
file will leave you with dangling pointers that could even crash the 
program).

Fixing the encryption is trivial, too (or at least coming as close to being 
"fixed" as is possible with such a trivial XOR scheme :-) The tricky thing 
is doing it in a way that is both backward compatible with old files, and 
not grossly ugly, but hey, I'm sure that can be done given a few brain 
cycles to investigate the problem.


--
Shawn Hargreaves - shawn@xxxxxxxxxx - http://www.talula.demon.co.uk/
"A binary is barely software: it's more like hardware on a floppy disk."



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/