Class: Glib::DynamicImagesHelper::EncryptionService

Inherits:
Struct
  • Object
show all
Defined in:
app/helpers/glib/dynamic_images_helper.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#private_keyObject

Returns the value of attribute private_key

Returns:

  • (Object)

    the current value of private_key



36
37
38
# File 'app/helpers/glib/dynamic_images_helper.rb', line 36

def private_key
  @private_key
end

#saltObject

Returns the value of attribute salt

Returns:

  • (Object)

    the current value of salt



36
37
38
# File 'app/helpers/glib/dynamic_images_helper.rb', line 36

def salt
  @salt
end

Instance Method Details

#decrypt(value) ⇒ Object



41
42
43
# File 'app/helpers/glib/dynamic_images_helper.rb', line 41

def decrypt(value)
  encryptor.decrypt_and_verify(value)
end

#encrypt(value) ⇒ Object



37
38
39
# File 'app/helpers/glib/dynamic_images_helper.rb', line 37

def encrypt(value)
  encryptor.encrypt_and_sign(value)
end