added encrypt_file method