jwk-tool 0.0.3 → 0.0.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +5 -4
  3. data/jwk-tool.gemspec +1 -1
  4. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 230b342743bd1ece240fd9f2cf27c925073d17e1
4
- data.tar.gz: 39914ac78b0791ee64e1d503166424a9b05f3d81
3
+ metadata.gz: d8783a1a354a7199f27b2c6d57d9162246e21b34
4
+ data.tar.gz: 8d4a160d20c924c1c110fe6e6f3b0ef6ce4954e1
5
5
  SHA512:
6
- metadata.gz: af620e617f8847b64dc9d53fec2e7b06ec3d77122e8e6b4de33c483143ac0c21572fd9b6b10924ba188e4a3264cc59bb2e6e96508dc3c7d70203d97fd6f5bde8
7
- data.tar.gz: 0810f01b69e43328c971cb78201d81213693e2ff3a1f37be58f1dbcdfaea6bfe8d355946c35a32f1cccfa46e1433d2bced6e64e62f3e7da7707eabbd2640890d
6
+ metadata.gz: 432e34438c4ab7c52d9ec03f3260c346a9b17d38e99f06963b6ec09a5ec03b844afe842d60eb13b274cf1d0928eb5b4609ed4de952a6ff47c244698dcd38694a
7
+ data.tar.gz: fba24d9bd4299ee7c16577acc70d447c6aa7d02c6d44749d7ddb972c4692246e5a041fb5140aff0a1993f72e6462830887a22c6a50e904092720d06323ed237e
data/README.md CHANGED
@@ -17,7 +17,7 @@ To use the keys as JSON Web Key (JSON::JWK) defined in json-jwk, just read files
17
17
 
18
18
  An encryption example at sender node using public key.
19
19
 
20
- ``ruby:sender.rb
20
+ ```ruby
21
21
  require 'json/jwk'
22
22
  # read public key from file
23
23
  jwk_pub = JSON::JWK.new(JSON.parse(open('hoge.pub').read))
@@ -31,15 +31,16 @@ jwe.alg = :RSA1_5
31
31
  jwe.encrypt!(jwk_pub.to_key)
32
32
  # output the result in JSON format
33
33
  json = jwe.as_json.to_json
34
- ``
34
+ ```
35
35
 
36
36
  A decryption example at receiver node using private key.
37
37
 
38
- ``ruby
38
+ ```ruby
39
+ require 'json/jwk'
39
40
  # read private key from file
40
41
  jwk = JSON::JWK.new(JSON.parse(open('hoge').read))
41
42
  # decrypt JSON format cipher data
42
43
  jwe_dec = JSON::JWE.decode_json_serialized(JSON.parse(json), jwk.to_key)
43
44
  # obtain the original plain text
44
45
  jwe_dec.plain_text
45
- ``
46
+ ```
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |gem|
2
2
  gem.name = "jwk-tool"
3
- gem.version = "0.0.3"
3
+ gem.version = "0.0.4"
4
4
 
5
5
  gem.authors = ["Toyokazu Akiyama"]
6
6
  gem.email = ["toyokazu@gmail.com"]
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jwk-tool
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Toyokazu Akiyama