Permalink
Browse files

changing default to bcrypt, adding gem dependency

  • Loading branch information...
1 parent deabb59 commit 5c4455f9e183327fea524f297e6df174228a0603 @NoamB committed Feb 1, 2011
Showing with 7 additions and 3 deletions.
  1. +3 −0 README.rdoc
  2. +1 −1 Rakefile
  3. +1 −0 lib/sorcery/crypto_providers/bcrypt.rb
  4. +1 −1 lib/sorcery/model.rb
  5. +1 −1 spec/Gemfile
View
@@ -90,6 +90,9 @@ For example:
config.session_timeout = 10.minutes
end
+Also check the migrations in the example app to see what database fields are expected.
+
+
The configuration options vary with the modules you've chosen to use.
View
@@ -15,7 +15,7 @@ Jeweler::Tasks.new do |gem|
gem.homepage = "http://github.com/NoamB/sorcery"
gem.license = "MIT"
gem.summary = "Magical authentication for Rails 3 applications"
- gem.description = "Provides common authentication needs such as signing in/out, activating by email, resetting password and deleting accounts."
+ gem.description = "Provides common authentication needs such as signing in/out, activating by email and resetting password."
gem.email = "nbenari@gmail.com"
gem.authors = ["Noam Ben Ari"]
# Include your dependencies below. Runtime dependencies are required when using your gem,
@@ -49,6 +49,7 @@ def cost
@cost ||= 10
end
attr_writer :cost
+ alias :stretches= :cost=
# Creates a BCrypt hash for the password passed.
def encrypt(*tokens)
View
@@ -132,7 +132,7 @@ def initialize
:@email_attribute_name => :email,
:@crypted_password_attribute_name => :crypted_password,
:@encryption_algorithm => :sha256,
- :@encryption_provider => CryptoProviders::SHA256,
+ :@encryption_provider => CryptoProviders::BCrypt,
:@custom_encryption_provider => nil,
:@encryption_key => nil,
:@salt_join_token => "",
View
@@ -1,10 +1,10 @@
source 'http://rubygems.org'
gem "rails", '3.0.3'
+gem 'bcrypt-ruby', :require => 'bcrypt'
gem "sorcery", '0.1.0', :path => '../../../'
group :development do
- gem 'bcrypt-ruby', :require => 'bcrypt'
gem 'rspec'
gem 'ruby-debug19'
gem 'simplecov', '>= 0.3.8', :require => false # Will install simplecov-html as a dependency

0 comments on commit 5c4455f

Please sign in to comment.