Skip to content
This repository has been archived by the owner on Jun 10, 2021. It is now read-only.

clowder/encrypted-attributes

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build Status

EncryptedAttributes

Usage

Rails

Create an initializer that will configure the EncryptedAttributes module with your Key and IV.

EncryptedAttributes.setup(:key => 'YOUR RANDOM KEY', :iv => 'YOUR RANDOM INITIALIZATION VECTOR')

Encrypt your columns like.

class Deployment < ActiveRecord::Base
  extend EncryptedAttributes

  serialize :secret_config, Hash
  encrypt :secret_config
end

Running the intergration tests locally

Ensure you have a MySQL table called encrypted_attributes_test.

Running the specs for Rails 2.3.x:

export BUNDLE_GEMFILE=gemfiles/rails-2_3.gemfile
bundle install
bundle exec rspec spec/

And Rails 3.0.x:

export BUNDLE_GEMFILE=gemfiles/rails-3_2.gemfile
bundle install
bundle exec rspec spec/

Authors

Created and maintained by

Chris Lowder

Patches contributed by

Contributor List

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Added some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages