ConsoleUser
Copyright (c) 2010-2023 Skaion Corporarion, www.skaion.com
This project was developed in part by numerous sponsorships from the U.S. Government. The U.S. Government is authorized to reproduce and distribute reprints of Governmental purposes notwithstanding any copyright notation thereon.
All content reflects those of the authors and should not be interpreted as necessarily representing the official policies or endorsements, either expressed or implied, of the U.S. Government or Skaion Corporation.
- class AxCrypt.AxCrypt(system, config)¶
I am the abstract class for working with AxCrypt. Subclasses will at least need to point to the correct set of images to drive AxCrypt on the platform.
Parameters:
system: a <no title> object to interact with the target host
config: a :doc:`UserConfig: object defining this user
- decrypt(passwd, path, out_path=None)¶
Decrypt the file at a given path, optionally writing to the specific path instead of accepting the default location to write.
Parameters:
passwd: the password/phrase to decrypt the file with
path: the location of the source file, as a string
out_path: optionally a string saying where to write the decrypted file
Return: False on failure, otherwise it is the expected path of the decrypted file
- decrypt_with_key(key_path, source_path, out_path=None)¶
Decrypt the file at a given path, optionally writing to the specific path instead of accepting the default location to write.
Parameters:
key_path: the key file to use to decrypt the source file
source_path: the location of the source file, as a string
out_path: optionally a string saying where to write the decrypted file
Return: False on failure, otherwise it is the expected path of the decrypted file
- encrypt(passwd, path, out_path=None)¶
Encrypt the file at a given path, optionally writing to the specific path instead of accepting the default location to write.
Parameters:
passwd: the password/phrase to encrypt the file with
path: the location of the source file, as a string
out_path: optionally a string saying where to write the encrypted file
Return: False on failure, otherwise it is the expected path of the encrypted file
- encrypt_with_key(key_path, source_path, out_path=None)¶
Encrypt the file at a given path, optionally writing to the specific path instead of accepting the default location to write.
Parameters:
key_path: the key file to use to encrypt the source file
path: the location of the source file, as a string
out_path: optionally a string saying where to write the encrypted file
Return: False on failure, otherwise it is the expected path of the encrypted file