keyczar_ruby 0.0.1 → 0.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/README.rdoc ADDED
@@ -0,0 +1,38 @@
1
+ A ruby interface to the keyczar crypto library. Provides basic encrypt,
2
+ decrypt, sign and verify methods.
3
+
4
+ This is just a wrapper around the c++ version of keyczar. You will need
5
+ keyczar-cpp in order to use it. Find keyczar-cpp here:
6
+
7
+ http://code.google.com/p/keyczar/downloads/list
8
+
9
+ For now, we assume that keyczar-cpp was installed with the prefix
10
+ /usr/local. You should be able to install it with these commands:
11
+
12
+ $ cd keyczar-cpp/src
13
+ $ sh ./tools/swtoolkit/hammer.sh --mode=opt-linux --compat
14
+ $ sh ./tools/swtoolkit/hammer.sh --mode=opt-linux --compat install
15
+
16
+ replace opt-linux above by opt-bsd or opt-mac depending on your system
17
+
18
+
19
+ Methods:
20
+
21
+ Keyczar::Crypter#encrypt(plaintext) #=> cryptext
22
+ Keyczar::Crypter#decrypt(cryptext) #=> plaintext
23
+ Keyczar::Signer#sign(text) #=> signature
24
+ Keyczar::Signer#verify(text,signature) #=> true or false
25
+
26
+ The first 3 return empty string on error. #encrypt and #sign results are
27
+ base64 encoded.
28
+
29
+ == Installation
30
+
31
+ Simple:
32
+
33
+ $ gem install keyczar_ruby
34
+
35
+ For bundler, add it to your Gemfile and run
36
+
37
+ $ bundle install
38
+
@@ -5,6 +5,13 @@ extension_name = 'keyczar_ruby'
5
5
  dir_config(extension_name)
6
6
  dir_config("keyczar", "/usr/local/include", "/usr/local/lib")
7
7
 
8
- have_library("keyczar") or raise
8
+ have_library("keyczar") or raise RuntimeError, <<-MSG
9
+ Could not find keyczar C++ library. Are you sure you have it installed?
10
+ **
11
+ ** Source files can be found here:
12
+ ** http://code.google.com/p/keyczar/downloads/list
13
+ **
14
+ ** see README.rdoc for more details
15
+ MSG
9
16
 
10
17
  create_makefile(extension_name)
@@ -1,3 +1,3 @@
1
1
  module Keyczar
2
- VERSION = "0.0.1"
2
+ VERSION = "0.0.2"
3
3
  end
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: keyczar_ruby
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 0.0.1
5
+ version: 0.0.2
6
6
  platform: ruby
7
7
  authors:
8
8
  - TrueCar SF Dev Team
@@ -79,7 +79,7 @@ extra_rdoc_files: []
79
79
  files:
80
80
  - .gitignore
81
81
  - Gemfile
82
- - README
82
+ - README.rdoc
83
83
  - Rakefile
84
84
  - ext/keyczar_ruby/extconf.rb
85
85
  - ext/keyczar_ruby/keyczar_ruby.cc
data/README DELETED
@@ -1,24 +0,0 @@
1
- A ruby interface to the keyczar crypto library. Provides basic encrypt,
2
- decrypt, sign and verify methods.
3
-
4
- This is just a wrapper around the c++ version of keyczar. You will need
5
- keyczar-cpp in order to use it. Find keyczar-cpp here:
6
-
7
- http://code.google.com/p/keyczar/downloads/list
8
-
9
- For now, we assume that keyczar-cpp was installed with the prefix
10
- /usr/local.
11
-
12
- Methods:
13
-
14
- Keyczar::Crypter#encrypt(plaintext) #=> cryptext
15
- Keyczar::Crypter#decrypt(cryptext) #=> plaintext
16
- Keyczar::Signer#sign(text) #=> signature
17
- Keyczar::Signer#verify(text,signature) #=> true or false
18
-
19
- The first 3 return empty string on error. #encrypt and #sign results are
20
- base64 encoded.
21
-
22
-
23
-
24
-