WinZip 14.0 command line abilities

Status
Not open for further replies.

vinney1369

Distinguished
Nov 5, 2009
3
0
18,510
Thank you for taking the time to read this, I really appreciate it!

I work for a small bank, and I have been told to write a batch file that will grab a selected folder/files, zip them up, encrypt them @256bit AES, password protect the file, and place the final product in a particular location. Oh, the last piece of this is that the final product has to be a self-extracting archive.

Is this possible? I sent in a question directly to WinZip and still haven't heard back. I'm also a novice at writing batch files, so if anyone can point me in the right direction for scripting this out (given it works), I'd really appreciate it. Its been a little tough researching this since they want me to find out if this is possible before purchasing a new license for the server.

Thanks for your time!

Vin
 

vinney1369

Distinguished
Nov 5, 2009
3
0
18,510
For those of you reading this, I did find an answer to my question. WinZip was able to help me out, and once I was able to point to the program successfully, it was downhill from there.

Here is the code (sample directories only of course). It takes the files from the directory, zips them up in 256bit AES encryption, prompts the user to enter a password (password parameters are controlled by WinZip's configuration), and outputs the appropriate .zip file. It then turns that .zip into a self-extracting .exe file, and deletes the .zip it was created from.

Hope this helps someone!

/\/\/\/\/\/\/\/\/\/\/\/\/\/\ Code Below/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\

@echo off
echo.
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
echo Preparing to Zip and Secure files
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
echo.
echo Please stand by .......
c:\progra~1\winzip\wzzip HR_Backup.zip -s -jhrs -P -r -xCreate_Backup.bat -ycAES256 "C:\Documents and Settings\useraccount\My Documents\*.*"
echo.
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
echo Creating Self-Extracting Archive
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
echo.
"c:\progra~1\WinZip Self-Extractor\wzipse32" -y HR_Backup.zip
echo.
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
echo Cleaning up
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
echo.
del HR_Backup.zip
echo.
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
echo Please check that HR_Backup.exe has been created successfully
echo -If it hasn't, please contact someone in IT immediately.
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
echo.
pause
 
Status
Not open for further replies.