A method of encrypting and decompressing files under Linux

Source: Internet
Author: User
Tags openssl
Method one: Using the tar command to encrypt and decompress files

Compression:

[HTML] View plain copy
Tar-zcf-filename |openssl des3-salt-k Password | DD Of=filename.des3

This command compresses the filename file to generate FILENAME.DES3 encrypted compressed file, password encrypted password

Extract:

[HTML] View plain copy
DD If=filename.des3 |openssl des3-d-k password | Tar zxf-

Note that the "-" at the very back of the command will release all files,-K password can not, and will be prompted to enter the password when extracting

Method Two: Use the zip command to encrypt and decompress the file

Compression:

[HTML] View plain copy
Zip-re filename.zip filename Enter 2 times password

[HTML] View plain copy
ZIP-RP passwork filename.zip filename passwork is the password to be entered

Extract:

[HTML] View plain copy
Unzip Filename.zip Follow the prompts to enter the password

[HTML] View plain copy
Unzip-p passwork Filename.zip Passwork is to extract the password, this will not be prompted to enter the password operation

A method of encrypting and decompressing files under Linux

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.