lib/symmetric_encryption/cli.rb in symmetric-encryption-4.1.1 vs lib/symmetric_encryption/cli.rb in symmetric-encryption-4.1.2

- old
+ new

@@ -217,11 +217,11 @@ environments: environments, cipher_name: cipher_name } args[:key_path] = key_path if key_path args[:regions] = regions if regions && !regions.empty? - cfg = Keystore.generate_data_keys(keystore, **args) + cfg = Keystore.generate_data_keys(keystore: keystore, **args) Config.write_file(config_file_path, cfg) puts "New configuration file created at: #{config_file_path}" end def run_migrate @@ -229,10 +229,10 @@ Config.write_file(config_file_path, config) puts "Existing configuration file successfully migrated to the new format: #{config_file_path}" end def run_rotate_keys - if keystore && KEYSTORES.include?(keystore) + if keystore && !KEYSTORES.include?(keystore) puts "Invalid keystore option: #{keystore}, must be one of #{KEYSTORES.join(', ')}" exit(-3) end config = Config.read_file(config_file_path)