SharpDevelop Community

Get your problems solved!
Welcome to SharpDevelop Community Sign in | Join | Help
in Search

Encrypt Zip and Decrypt Zip

Last post 06-15-2008 9:33 PM by JohnReilly. 1 replies.
Page 1 of 1 (2 items)
Sort Posts: Previous Next
  • 04-17-2008 8:02 PM

    Encrypt Zip and Decrypt Zip

     I have 2 questions and 1 statement

     I'm using VS2005 Pro, VB.NET

    1) I know how to use a password to protect a zip file

                REM Compression Level: 0-9
                REM 0: no(Compression)
                REM 9: maximum compression
                strmZipOutputStream.SetLevel(9)
                strmZipOutputStream.Password = "passwordstring"

    How can I use Encryption on this file?

     I have Imports ICSharpCode.SharpZipLib.Encryption and Dim crypto As PkzipClassicManaged

     But I cannot figure out how to tie this Encryption class to the Zip class.

     

    2) If I have a file, "demo.zip" and I open it only in memory, How could I use 1 or more of the files directly without extracting?

     

    Statement: I have the latest build and get these warnings:

     Warning    1    Load of property 'RunPostBuildEvent' failed.      CreateZipFile

    Warning    2    Load of property 'WarningLevel' failed.      CreateZipFile

     

    Any clue why or how to rid this would be great. ;)

    ~Dave
  • 06-15-2008 9:33 PM In reply to

    Re: Encrypt Zip and Decrypt Zip

     Hi,

    No need to tie things together just set the password and it will do the job as you have already noted.  There is only one algorithm supported currently and the password drives it all.  Are you wanting to use rijndael or something else?

    Just remember that the 'classic' encryption algorithm is very weak and should only be used to hide tings from casual users.

     

    Cheers,

    John.

Page 1 of 1 (2 items)
Powered by Community Server (Commercial Edition), by Telligent Systems
Don't contact us via this (fleischfalle@alphasierrapapa.com) email address.