On Thu, 31 Jul 2008, Szakáts Viktor wrote: Hi Viktor,
> 1) I did a quick test, but unzip doesn't seem to accept > any passwords for something zipped with myzip. Please be sure that you are using current SVN code. I made test with UNZIP in my linux box and PKUNZIP in DOS emulator and both nicely decompress password encrypted archives created by myzip.prg I was using: UnZip 5.51 of 22 May 2004, by Info-ZIP UnZip 5.52 of 28 February 2005, by Info-ZIP PKUNZIP 2.04g > Also, I've zipped something with a password using zip, > and tried to unzip it with myunzip, but it didn't > work either. Maybe I'm doing something wrong. It extracts correctly for me but as I can see in your other mail you already resolved the problem. > 2) I'm not sure I understand hb_zipfilecreate()'s new > parameter. What file's CRC32 should be passed there? hb_zipfilecreate() is used when you want to store file in ZIP archive yourself passing the data to this file directly with all other information like file data and attribute. In such case if you want to encrypt file using password and you want that other tools will be able to extract it then you have to also pass CRC32 calculated for data you will later write to ZIP file using HB_ZipFileWrite(). If this data is in constant value then use HB_CRC32() function to calculate it otherwise if it is in file then you can use HB_zipFileCRC32(). HB_ZipFileCreate() does not know data you will write so it cannot calculate it itself and because this CRC32 value is part of encryption key then it's necessary to know it at the beginning and it cannot be updated later (at least without yet another pass which will decode and encode again with new key having valid CRC32). HB_ZipStoreFile() does not need CRC32 passed by user because it calculates it from given source file. best regards, Przemek _______________________________________________ Harbour mailing list Harbour@harbour-project.org http://lists.harbour-project.org/mailman/listinfo/harbour