Decrypting the log file

Last Updated : Aug 09, 2019 |

About this task

If the log file is encrypted, use this procedure to decrypt the log file.

  • If you type the passphrase in the command, the passphrase is visible.

    For example, you might want the passphrase to be visible when you are not in a public environment and have no privacy concerns.

  • If you do not want the passphrase to be visible while typing the command, you can enter the passphrase later.

    For example, you are providing a demo on how to decrypt the log files, and do not want other people to view your passphrase while typing the command.

Before you begin

Open the terminal application.

Procedure

  • If you want the passphrase to appear in the command, run the following command: openssl enc -d -aes-256-ecb -md sha256 -salt -k $logpassphrase -in $logfile -out $decryptfile.

    Where, you must replace:

    • $logpassphrase with the configured passphrase.

    • $logfile with the encrypted zip path. For example, /Users/<user_name>/Desktop/encrypted.zip.

    • $decryptfile with the location where you want to place the decrypted zip. For example, /Users/<user_name>/Desktop/decrypted.zip.

  • If you do not want the passphrase to appear in the command, run the following command: openssl enc -d -aes-256-ecb -md sha256 -salt -in $logfile -out $decryptfile, and then enter the passphrase.

    Where, you must replace:

    • $logfile with the encrypted zip path. For example, /Users/<user_name>/Desktop/encrypted.zip.

    • $decryptfile with the location where you want to place the decrypted zip. For example, /Users/<user_name>/Desktop/decrypted.zip.