使用命令列進行壓縮、加密。系統環境變數加入 7zip 的安裝路徑
C:\Program Files\7-Zip\
確定後可以在 cmd 中輸入 7z 做測試,如果成功則會出現 7zip 的命令參數。

a (Add) command
Adds files to archive.

-t (set Type of archive) switch
Specifies the type of archive.

sfx (Create SFX archive) switch
Creates self extracting archive.

-mmt=4
Multi Thread

-mx=9
x=[1 | 3 | 5 | 7 | 9 ]
Sets level of compression.

compress directory
7z a -sfx E:\folder.exe -mmt=4 -mx=9 -paaa D:\flyfox
password:aaa

compress file
7z a -sfx E:\file.exe -mmt=4 -mx=9 -paaa -mhe D:\flyfox.txt
password:aaa
若密碼錯誤所有檔案皆無法解開。

7z a -sfx E:\file.exe -mmt=4 -mx=9 -paaa D:\flyfox.txt
password:aaa
可以解開檔案名稱但無內容。

arrow
arrow
    全站熱搜

    flyfox 發表在 痞客邦 留言(0) 人氣()