Class: Zetto::Services::Encryption::PasswordHashing

Inherits:
Object
  • Object
show all
Includes:
Modules::Crypto
Defined in:
lib/zetto/services/encryption/password_hashing.rb

Instance Method Summary collapse

Constructor Details

#initialize(password) ⇒ PasswordHashing

Returns a new instance of PasswordHashing.



6
7
8
# File 'lib/zetto/services/encryption/password_hashing.rb', line 6

def initialize(password)
  @password = password
end

Instance Method Details

#executeObject



10
11
12
13
14
15
# File 'lib/zetto/services/encryption/password_hashing.rb', line 10

def execute
  generate_hashing(Zetto::Config::Params.user_class_password_crypto, @password)
rescue Exception => e
  Zetto::Services::Info.error_message I18n.t('exseptions.unknown_error', argument: 'Zetto::Services::Encryption::PasswordHashing', current_method: __method__), e
  nil
end