Pages

Friday, January 17, 2020

How to Decrypt a Folder from the command line by using the cipher command


Decrypting a folder or file refers to clearing the Encrypt Contents To Secure Data check box in a folder’s or file’s Advanced Attributes dialog box, which you access from the
folder’s or file’s Properties dialog box. Once decrypted, the file remains decrypted until you select the Encrypt Contents To Secure Data Check box. The only reason you might Want to decrypt a file is if other people need access to the folder or file-for example, if you want to share the folder or make the file available across the network.

How to Control Encryption From the Command Line by Using the Cipher Command

The Cipher command provides the capability to encrypt and decrypt files and folders from a command prompt. The following example shows the available switches for the  Cipher command, which are described next

cipher [/e | /d] [/s:folder_name] [/a] [/1] [/f] [/q] [/h] [/k] [file_name [...]]

  Cipher Command Switches


Switch 
/ e
  Encrypts the specified folders. Folders are marked so any files that are added later are encrypted.
/d
Decrypts the specified folders. Folders are marked so any files that are added later are not encrypted.
/s
Performs the specified operation on files in the given folder and all subfolders. 

/a
Performs the specified operation on files as well as folders. Encrypted files could be decrypted when modified if the parent folder is not encrypted. Encrypt the me and the parent folder to avoid problems.
/i
Continues performing the specified operation even after errors have occurred. By default, Cipher stops when an error is encountered. 

/f
Forces the encryption operation on all specified files, even those that are already encrypted. Files that are already encrypted are skipped by default.
/q 
 Reports only the most essential information.
/h
Displays files with the hidden or system attributes, which are not shown by default.
 /k
Creates a new file encryption key for the user running the Cipher command, Using this option causes the Cipher command to ignore all other options.
 file_name
 
Specifies a pattern, file, or folder,



If you run the Cipher command without parameters, it displays the encryption state of the current folder and any files that it contains. You can specify multiple file names and use wildcards. You must put spaces between multiple parameters.

No comments:

Post a Comment