forked from p15670423/monkey
island: Specify mode to open new secure file in, in encryptor.py
This commit is contained in:
parent
64ac1fe706
commit
80bfd90074
|
@ -27,7 +27,7 @@ class Encryptor:
|
|||
|
||||
def _init_key(self, password_file):
|
||||
self._cipher_key = Random.new().read(self._BLOCK_SIZE)
|
||||
with open(get_file_descriptor_for_new_secure_file(path=password_file)) as f:
|
||||
with open(get_file_descriptor_for_new_secure_file(path=password_file), "wb") as f:
|
||||
f.write(self._cipher_key)
|
||||
|
||||
def _load_existing_key(self, password_file):
|
||||
|
|
Loading…
Reference in New Issue