Welcome to the NetCologne GmbH open source mirroring service!
This machine mirrors various open-source projects.
20 Gbit/s uplink.
If there are any issues or you want another project mirrored, please contact
mirror-service -=AT=- netcologne DOT de !
bareos.util.password.Password — Bareos Documentation documentation
bareos.util.password.Password
-
class bareos.util.password.Password(password=None)[source]
Bases: object
Handle Bareos passwords.
Instead of working with plain text passwords,
Bareos often uses the MD5 hash of the password.
This class make a password available in both forms.
- Parameters:
password (str, optional) – Password as plain text.
Methods
-
md5()[source]
Get password as MD5 hash.
- Returns:
Password as MD5 hash.
- Return type:
bytes
-
plaintext()[source]
Get password as plain text.
- Returns:
Password as plain text.
- Return type:
str
-
set_md5(password)[source]
Set the MD5 form of the password.
If the password is initialized by this method,
it is only available as MD5 hash, not as plain text password.
- Parameters:
password (bytes) – Password as MD5 hash.
-
set_plaintext(password)[source]
Set new password.
- Parameters:
password (str) – Password as plain text.