Sha256: f981a158d743381dfc82cdce2dfc8e3ac7e1a621d0af3755ff6a1bcfbdc412e6

Contents?: true

Size: 909 Bytes

Versions: 13

Compression:

Stored size: 909 Bytes

Contents

module Clearance
  # Control how users are authenticated and how passwords are stored.
  #
  # The default password strategy is {Clearance::PasswordStrategies::BCrypt},
  # but this can be overridden in {Clearance::Configuration}.
  #
  # You can supply your own password strategy by implementing a module that
  # responds to the proper interface methods. Once this module is configured as
  # your password strategy, Clearance will mix it into your Clearance User
  # class. Thus, your module can access any methods or attributes on User.
  #
  # Password strategies need to respond to `authenticated?(password)` and
  # `password=(new_password)`. For an example of how to implement these methods,
  # see {Clearance::PasswordStrategies::BCrypt}.
  module PasswordStrategies
    autoload :BCrypt, "clearance/password_strategies/bcrypt"
    autoload :Argon2, "clearance/password_strategies/argon2"
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
clearance-2.9.2 lib/clearance/password_strategies.rb
clearance-2.9.1 lib/clearance/password_strategies.rb
clearance-2.9.0 lib/clearance/password_strategies.rb
clearance-2.8.0 lib/clearance/password_strategies.rb
clearance-2.7.2 lib/clearance/password_strategies.rb
clearance-2.7.0 lib/clearance/password_strategies.rb
clearance-2.6.2 lib/clearance/password_strategies.rb
clearance-2.6.1 lib/clearance/password_strategies.rb
clearance-2.6.0 lib/clearance/password_strategies.rb
clearance-2.5.0 lib/clearance/password_strategies.rb
clearance-2.4.0 lib/clearance/password_strategies.rb
clearance-2.3.1 lib/clearance/password_strategies.rb
clearance-2.3.0 lib/clearance/password_strategies.rb