einvoice-qr-encryptor 0.1.0
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.
- checksums.yaml +7 -0
- data/.gitignore +12 -0
- data/.rspec +2 -0
- data/.rubocop.yml +15 -0
- data/.simplecov +3 -0
- data/.travis.yml +10 -0
- data/Gemfile +4 -0
- data/LICENSE.txt +21 -0
- data/README.md +83 -0
- data/Rakefile +6 -0
- data/bin/console +14 -0
- data/bin/setup +8 -0
- data/einvoice-qr-encryptor.gemspec +31 -0
- data/lib/einvoice-qr-encryptor.rb +5 -0
- data/lib/einvoice-qr-encryptor/client.rb +166 -0
- data/lib/einvoice-qr-encryptor/core_ext/integer.rb +9 -0
- data/lib/einvoice-qr-encryptor/error_message.rb +14 -0
- data/lib/einvoice-qr-encryptor/version.rb +3 -0
- metadata +131 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 80fe255b1eff2143eafd740a98fe9b8609edf80e
|
4
|
+
data.tar.gz: f5812674d2cc380208ddcad647709851388975eb
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: ed9db4e706f23108c22c7f522e869de0215d9c67d1fe5f28afd6e63664ac452ac32216584ad34fbe033bd661bd85100a8dc9c39d2036a718e7bef8b06aa638a3
|
7
|
+
data.tar.gz: 47a1f41d462b43be2b8e332308732043b4331837e379cb7a995bd7d9f442777b08291f5c2fa45342b05e03ab62d0c261790e2e22cd6984f785fce8e26dcb9215
|
data/.gitignore
ADDED
data/.rspec
ADDED
data/.rubocop.yml
ADDED
@@ -0,0 +1,15 @@
|
|
1
|
+
AllCops:
|
2
|
+
TargetRubyVersion: 2.1
|
3
|
+
Exclude:
|
4
|
+
- tmp/*.rb
|
5
|
+
Metrics:
|
6
|
+
Enabled: false
|
7
|
+
Lint/UnusedMethodArgument:
|
8
|
+
Description: 'Checks for unused method arguments.'
|
9
|
+
Enabled: false
|
10
|
+
Style/AsciiComments:
|
11
|
+
Description: 'Use only ascii symbols in comments.'
|
12
|
+
Enabled: false
|
13
|
+
Style/FileName:
|
14
|
+
Description: 'Use snake_case for source file names.'
|
15
|
+
Enabled: false
|
data/.simplecov
ADDED
data/.travis.yml
ADDED
data/Gemfile
ADDED
data/LICENSE.txt
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
The MIT License (MIT)
|
2
|
+
|
3
|
+
Copyright (c) 2017 Calvert
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in
|
13
|
+
all copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
21
|
+
THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,83 @@
|
|
1
|
+
[](http://badge.fury.io/rb/einvoice-qr-encryptor)
|
2
|
+
[](https://travis-ci.org/CalvertYang/EInvoice-QR-Encryptor)
|
3
|
+

|
4
|
+
# EInvoice-QR-Encryptor
|
5
|
+
|
6
|
+
Encrypt, decrypt and generate QR code information for einvoice(Taiwan)
|
7
|
+
|
8
|
+
_Compatible with 2D barcode specification version 1.6_
|
9
|
+
|
10
|
+
## Installation
|
11
|
+
|
12
|
+
Add this line to your application's Gemfile:
|
13
|
+
|
14
|
+
```ruby
|
15
|
+
gem 'einvoice-qr-encryptor'
|
16
|
+
```
|
17
|
+
|
18
|
+
And then execute:
|
19
|
+
|
20
|
+
```bash
|
21
|
+
bundle
|
22
|
+
```
|
23
|
+
|
24
|
+
Or install it yourself as:
|
25
|
+
|
26
|
+
```bash
|
27
|
+
gem install einvoice-qr-encryptor
|
28
|
+
```
|
29
|
+
|
30
|
+
## Usage
|
31
|
+
|
32
|
+
```ruby
|
33
|
+
cipher = EInvoiceQREncryptor::Cipher.new('FE0F50D87215F625D1248F5FDAEBA37F')
|
34
|
+
```
|
35
|
+
|
36
|
+
#### Encrypt plain text
|
37
|
+
|
38
|
+
```ruby
|
39
|
+
cipher.encrypt('AA123456781234')
|
40
|
+
#=> '73UqXrAk5DsVNv2VEvIFkQ=='
|
41
|
+
```
|
42
|
+
|
43
|
+
#### Decrypt cipher text
|
44
|
+
|
45
|
+
```ruby
|
46
|
+
cipher.decrypt('73UqXrAk5DsVNv2VEvIFkQ==')
|
47
|
+
#=> 'AA123456781234'
|
48
|
+
```
|
49
|
+
|
50
|
+
#### Generate QR Code information for invoice
|
51
|
+
|
52
|
+
```ruby
|
53
|
+
cipher.gen_qrcode_information(
|
54
|
+
invoice_number: 'AA12345678',
|
55
|
+
invoice_date: '1040511',
|
56
|
+
invoice_time: '090000',
|
57
|
+
random_number: '1234',
|
58
|
+
sales_amount: 100,
|
59
|
+
tax_amount: 0,
|
60
|
+
total_amount: 100,
|
61
|
+
buyer_identifier: '00000000',
|
62
|
+
represent_identifier: '00000000',
|
63
|
+
seller_identifier: '00000000',
|
64
|
+
business_identifier: '00000000',
|
65
|
+
product_array: []
|
66
|
+
)
|
67
|
+
#=> 'AA12345678104051112340000006400000064000000000000000073UqXrAk5DsVNv2VEvIFkQ=='
|
68
|
+
```
|
69
|
+
|
70
|
+
## Development
|
71
|
+
|
72
|
+
After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
|
73
|
+
|
74
|
+
To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
|
75
|
+
|
76
|
+
## Contributing
|
77
|
+
|
78
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/CalvertYang/EInvoice-QR-Encryptor. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct.
|
79
|
+
|
80
|
+
|
81
|
+
## License
|
82
|
+
|
83
|
+
The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).
|
data/Rakefile
ADDED
data/bin/console
ADDED
@@ -0,0 +1,14 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
|
3
|
+
require 'bundler/setup'
|
4
|
+
require 'einvoice-qr-encryptor'
|
5
|
+
|
6
|
+
# You can add fixtures and/or initialization code here to make experimenting
|
7
|
+
# with your gem easier. You can also use a different console, if you like.
|
8
|
+
|
9
|
+
# (If you use this, don't forget to add pry to your Gemfile!)
|
10
|
+
# require 'pry'
|
11
|
+
# Pry.start
|
12
|
+
|
13
|
+
require 'irb'
|
14
|
+
IRB.start(__FILE__)
|
data/bin/setup
ADDED
@@ -0,0 +1,31 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
lib = File.expand_path('../lib', __FILE__)
|
3
|
+
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
|
+
require 'einvoice-qr-encryptor/version'
|
5
|
+
|
6
|
+
Gem::Specification.new do |spec|
|
7
|
+
spec.name = 'einvoice-qr-encryptor'
|
8
|
+
spec.version = EInvoiceQREncryptor::VERSION
|
9
|
+
spec.authors = ['Calvert']
|
10
|
+
spec.email = ['']
|
11
|
+
|
12
|
+
spec.summary = 'E-Invoice QR code information encryptor'
|
13
|
+
spec.description = 'Encrypt, decrypt and generate QR code information for einvoice(Taiwan)'
|
14
|
+
spec.homepage = 'https://github.com/calvertyang/EInvoice-QR-Encryptor'
|
15
|
+
spec.license = 'MIT'
|
16
|
+
|
17
|
+
spec.files = `git ls-files -z`.split("\x0").reject do |f|
|
18
|
+
f.match(%r{^(test|spec|features)/})
|
19
|
+
end
|
20
|
+
spec.bindir = 'exe'
|
21
|
+
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
22
|
+
spec.require_paths = ['lib']
|
23
|
+
|
24
|
+
spec.required_ruby_version = '>= 2.1.5'
|
25
|
+
|
26
|
+
spec.add_development_dependency 'bundler', '~> 1.7'
|
27
|
+
spec.add_development_dependency 'rake', '~> 10.0'
|
28
|
+
spec.add_development_dependency 'rspec', '~> 3.0'
|
29
|
+
spec.add_development_dependency 'rubocop', '~> 0.47.1'
|
30
|
+
spec.add_development_dependency 'simplecov', '~> 0.13.0'
|
31
|
+
end
|
@@ -0,0 +1,166 @@
|
|
1
|
+
require 'openssl'
|
2
|
+
require 'base64'
|
3
|
+
require 'einvoice-qr-encryptor/error_message'
|
4
|
+
require 'einvoice-qr-encryptor/core_ext/integer'
|
5
|
+
|
6
|
+
module EInvoiceQREncryptor
|
7
|
+
class Cipher # :nodoc:
|
8
|
+
attr_reader :aes_key
|
9
|
+
|
10
|
+
def initialize(aes_key = nil)
|
11
|
+
@aes_key = aes_key
|
12
|
+
@aes_iv = '0EDF25C93A28D7B5FF5E45DA42F8A1B8'
|
13
|
+
@cipher = OpenSSL::Cipher::AES.new(128, :CBC)
|
14
|
+
end
|
15
|
+
|
16
|
+
# Encrypt plain text
|
17
|
+
#
|
18
|
+
# @param plain_text [String] Plain text to encrypt
|
19
|
+
# @return [String] Cipher text
|
20
|
+
# @example
|
21
|
+
# encrypt('AA123456781234') #=> '73UqXrAk5DsVNv2VEvIFkQ=='
|
22
|
+
def encrypt(plain_text)
|
23
|
+
init_cipher(:encrypt)
|
24
|
+
Base64.encode64(@cipher.update(plain_text) + @cipher.final).strip
|
25
|
+
end
|
26
|
+
|
27
|
+
# Decrypt cipher text
|
28
|
+
#
|
29
|
+
# @param cipher_text [String] Cipher text to decrypt
|
30
|
+
# @return [String] Plain text
|
31
|
+
# @example
|
32
|
+
# decrypt('73UqXrAk5DsVNv2VEvIFkQ==') #=> 'AA123456781234'
|
33
|
+
def decrypt(cipher_text)
|
34
|
+
init_cipher(:decrypt)
|
35
|
+
@cipher.update(Base64.decode64(cipher_text)) + @cipher.final
|
36
|
+
end
|
37
|
+
|
38
|
+
# Generate QR code information for invoice
|
39
|
+
#
|
40
|
+
# @param invoice_number [String]
|
41
|
+
# @param invoice_date [String]
|
42
|
+
# @param invoice_time [String]
|
43
|
+
# @param random_number [String]
|
44
|
+
# @param sales_amount [Integer]
|
45
|
+
# @param tax_amount [Integer]
|
46
|
+
# @param total_amount [Integer]
|
47
|
+
# @param buyer_identifier [String]
|
48
|
+
# @param represent_identifier [String]
|
49
|
+
# @param seller_identifier [String]
|
50
|
+
# @param business_identifier [String]
|
51
|
+
# @param product_arrays [Array]
|
52
|
+
# @return [String] QR code information for invoice
|
53
|
+
# @example
|
54
|
+
# gen_qrcode_information(
|
55
|
+
# invoice_number: 'AA12345678',
|
56
|
+
# invoice_date: '1040511',
|
57
|
+
# invoice_time: '090000',
|
58
|
+
# random_number: '1234',
|
59
|
+
# sales_amount: 100,
|
60
|
+
# tax_amount: 0,
|
61
|
+
# total_amount: 100,
|
62
|
+
# buyer_identifier: '00000000',
|
63
|
+
# represent_identifier: '00000000',
|
64
|
+
# seller_identifier: '00000000',
|
65
|
+
# business_identifier: '00000000',
|
66
|
+
# product_array: []
|
67
|
+
# ) #=> 'AA12345678104051112340000006400000064000000000000000073UqXrAk5DsVNv2VEvIFkQ=='
|
68
|
+
def gen_qrcode_information(invoice_number:, invoice_date:, invoice_time:, random_number:, sales_amount:, tax_amount:, total_amount:, buyer_identifier:, represent_identifier:, seller_identifier:, business_identifier:, product_array:)
|
69
|
+
# check all arguments are valid
|
70
|
+
# 發票字軌號碼共 10 碼
|
71
|
+
raise ErrorMessage.generate(msg: :field_should_be, field: :invoice_number, data: String) unless invoice_number.is_a? String
|
72
|
+
raise ErrorMessage.generate(msg: :fixed_length, field: :invoice_number, length: 10) if invoice_number.length != 10
|
73
|
+
|
74
|
+
# 發票開立年月日(中華民國年份月份日期)共 7 碼
|
75
|
+
raise ErrorMessage.generate(msg: :field_should_be, field: :invoice_date, data: String) unless invoice_date.is_a? String
|
76
|
+
raise ErrorMessage.generate(msg: :fixed_length, field: :invoice_date, length: 7) if invoice_date.length != 7
|
77
|
+
|
78
|
+
/\d{3}(?<month>\d{2})(?<day>\d{2})/ =~ invoice_date
|
79
|
+
raise ErrorMessage.generate(msg: :field_should_be, field: 'month of invoice_date', data: 'between 01 ~ 12') unless ('01'..'12').cover? month
|
80
|
+
raise ErrorMessage.generate(msg: :field_should_be, field: 'day of invoice_date', data: 'between 01 ~ 31') unless ('01'..'31').cover? day
|
81
|
+
|
82
|
+
# 發票開立時間 (24 小時制) 共 6 碼,以時時分分秒秒方式之字串表示
|
83
|
+
# raise ErrorMessage.generate(msg: :field_should_be, field: :invoice_time, data: String) unless invoice_time.is_a? String
|
84
|
+
# raise ErrorMessage.generate(msg: :fixed_length, field: :invoice_time, length: 6) if invoice_time.length != 6
|
85
|
+
|
86
|
+
# 4 位隨機碼
|
87
|
+
raise ErrorMessage.generate(msg: :field_should_be, field: :random_number, data: String) unless random_number.is_a? String
|
88
|
+
raise ErrorMessage.generate(msg: :fixed_length, field: :random_number, length: 4) if random_number.length != 4
|
89
|
+
|
90
|
+
# 銷售額(未稅)
|
91
|
+
raise ErrorMessage.generate(msg: :field_should_be, field: :sales_amount, data: Integer) unless sales_amount.is_a? Integer
|
92
|
+
raise ErrorMessage.generate(msg: :field_should_be, field: :sales_amount, data: 'greater than or equal to 0') if sales_amount < 0
|
93
|
+
|
94
|
+
# 稅額
|
95
|
+
raise ErrorMessage.generate(msg: :field_should_be, field: :tax_amount, data: Integer) unless tax_amount.is_a? Integer
|
96
|
+
raise ErrorMessage.generate(msg: :field_should_be, field: :tax_amount, data: 'greater than or equal to 0') if tax_amount. < 0
|
97
|
+
|
98
|
+
# 總計金額(含稅)
|
99
|
+
raise ErrorMessage.generate(msg: :field_should_be, field: :total_amount, data: Integer) unless total_amount.is_a? Integer
|
100
|
+
raise ErrorMessage.generate(msg: :field_should_be, field: :total_amount, data: 'greater than or equal to 0') if total_amount. < 0
|
101
|
+
|
102
|
+
# 買受人統一編號
|
103
|
+
raise ErrorMessage.generate(msg: :field_should_be, field: :buyer_identifier, data: String) unless buyer_identifier.is_a? String
|
104
|
+
raise ErrorMessage.generate(msg: :fixed_length, field: :buyer_identifier, length: 8) if buyer_identifier.length != 8
|
105
|
+
|
106
|
+
# 代表店統一編號,目前電子發票證明聯二維條碼規格已不使用代表店
|
107
|
+
# raise ErrorMessage.generate(msg: :field_should_be, field: :represent_identifier, data: String) unless represent_identifier.is_a? String
|
108
|
+
# raise ErrorMessage.generate(msg: :fixed_length, field: :represent_identifier, length: 8) if represent_identifier.length != 8
|
109
|
+
|
110
|
+
# 銷售店統一編號
|
111
|
+
raise ErrorMessage.generate(msg: :field_should_be, field: :seller_identifier, data: String) unless seller_identifier.is_a? String
|
112
|
+
raise ErrorMessage.generate(msg: :fixed_length, field: :seller_identifier, length: 8) if seller_identifier.length != 8
|
113
|
+
|
114
|
+
# 總公司統一編號,如無總公司請填入銷售店統一編號
|
115
|
+
raise ErrorMessage.generate(msg: :field_should_be, field: :business_identifier, data: String) unless business_identifier.is_a? String
|
116
|
+
raise ErrorMessage.generate(msg: :fixed_length, field: :business_identifier, length: 8) if business_identifier.length != 8
|
117
|
+
|
118
|
+
# 商品資訊
|
119
|
+
raise ErrorMessage.generate(msg: :field_should_be, field: :product_array, data: Array) unless product_array.is_a? Array
|
120
|
+
|
121
|
+
product_array.each do |product|
|
122
|
+
# 透過條碼槍所掃出之條碼資訊
|
123
|
+
raise ErrorMessage.generate(msg: :field_should_be, field: 'product_array.product_code', data: String) unless product[:product_code].is_a? String
|
124
|
+
raise ErrorMessage.generate(msg: :cannot_be_empty, field: 'product_array.product_code') if product[:product_code].empty?
|
125
|
+
|
126
|
+
# 商品名稱
|
127
|
+
raise ErrorMessage.generate(msg: :field_should_be, field: 'product_array.product_name', data: String) unless product[:product_name].is_a? String
|
128
|
+
raise ErrorMessage.generate(msg: :cannot_be_empty, field: 'product_array.product_name') if product[:product_name].empty?
|
129
|
+
|
130
|
+
# 商品數量
|
131
|
+
raise ErrorMessage.generate(msg: :field_should_be, field: 'product_array.product_qty', data: String) unless product[:product_qty].is_a? String
|
132
|
+
raise ErrorMessage.generate(msg: :cannot_be_empty, field: 'product_array.product_qty') if product[:product_qty].empty?
|
133
|
+
|
134
|
+
# 商品銷售額(整數未稅),若無法分離稅項則記載為字串 0
|
135
|
+
raise ErrorMessage.generate(msg: :field_should_be, field: 'product_array.product_sale_amount', data: String) unless product[:product_sale_amount].is_a? String
|
136
|
+
raise ErrorMessage.generate(msg: :cannot_be_empty, field: 'product_array.product_sale_amount') if product[:product_sale_amount].empty?
|
137
|
+
|
138
|
+
# 商品稅額(整數),若無法分離稅項則記載為字串 0
|
139
|
+
raise ErrorMessage.generate(msg: :field_should_be, field: 'product_array.product_tax_amount', data: String) unless product[:product_tax_amount].is_a? String
|
140
|
+
raise ErrorMessage.generate(msg: :cannot_be_empty, field: 'product_array.product_tax_amount') if product[:product_tax_amount].empty?
|
141
|
+
|
142
|
+
# 商品金額(整數含稅)
|
143
|
+
raise ErrorMessage.generate(msg: :field_should_be, field: 'product_array.product_amount', data: String) unless product[:product_amount].is_a? String
|
144
|
+
raise ErrorMessage.generate(msg: :cannot_be_empty, field: 'product_array.product_amount') if product[:product_amount].empty?
|
145
|
+
end
|
146
|
+
|
147
|
+
# generate cipher text
|
148
|
+
cipher_text = encrypt("#{invoice_number}#{random_number}")
|
149
|
+
|
150
|
+
# return QR Code invoice information
|
151
|
+
"#{invoice_number}#{invoice_date}#{random_number}" \
|
152
|
+
"#{sales_amount.to_8bit_hex_string}#{total_amount.to_8bit_hex_string}" \
|
153
|
+
"#{buyer_identifier}#{seller_identifier}#{cipher_text}"
|
154
|
+
end
|
155
|
+
|
156
|
+
private
|
157
|
+
|
158
|
+
def init_cipher(type)
|
159
|
+
raise ErrorMessage.generate(msg: :cannot_be_empty, field: :aes_key) if @aes_key.nil? || @aes_key.empty?
|
160
|
+
|
161
|
+
@cipher.send(type)
|
162
|
+
@cipher.key = [@aes_key].pack('H*')
|
163
|
+
@cipher.iv = [@aes_iv].pack('H*')
|
164
|
+
end
|
165
|
+
end
|
166
|
+
end
|
@@ -0,0 +1,14 @@
|
|
1
|
+
module EInvoiceQREncryptor
|
2
|
+
class ErrorMessage # :nodoc:
|
3
|
+
def self.generate(params)
|
4
|
+
case params[:msg]
|
5
|
+
when :field_should_be
|
6
|
+
"The #{params[:field]} should be #{params[:data]}"
|
7
|
+
when :fixed_length
|
8
|
+
"The length for #{params[:field]} should be #{params[:length]}"
|
9
|
+
when :cannot_be_empty
|
10
|
+
"The #{params[:field]} cannot be empty"
|
11
|
+
end
|
12
|
+
end
|
13
|
+
end
|
14
|
+
end
|
metadata
ADDED
@@ -0,0 +1,131 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: einvoice-qr-encryptor
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.1.0
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Calvert
|
8
|
+
autorequire:
|
9
|
+
bindir: exe
|
10
|
+
cert_chain: []
|
11
|
+
date: 2017-03-07 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: bundler
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '1.7'
|
20
|
+
type: :development
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '1.7'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: rake
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '10.0'
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '10.0'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: rspec
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - "~>"
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '3.0'
|
48
|
+
type: :development
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - "~>"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '3.0'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: rubocop
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - "~>"
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: 0.47.1
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - "~>"
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: 0.47.1
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: simplecov
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - "~>"
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: 0.13.0
|
76
|
+
type: :development
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - "~>"
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: 0.13.0
|
83
|
+
description: Encrypt, decrypt and generate QR code information for einvoice(Taiwan)
|
84
|
+
email:
|
85
|
+
- ''
|
86
|
+
executables: []
|
87
|
+
extensions: []
|
88
|
+
extra_rdoc_files: []
|
89
|
+
files:
|
90
|
+
- ".gitignore"
|
91
|
+
- ".rspec"
|
92
|
+
- ".rubocop.yml"
|
93
|
+
- ".simplecov"
|
94
|
+
- ".travis.yml"
|
95
|
+
- Gemfile
|
96
|
+
- LICENSE.txt
|
97
|
+
- README.md
|
98
|
+
- Rakefile
|
99
|
+
- bin/console
|
100
|
+
- bin/setup
|
101
|
+
- einvoice-qr-encryptor.gemspec
|
102
|
+
- lib/einvoice-qr-encryptor.rb
|
103
|
+
- lib/einvoice-qr-encryptor/client.rb
|
104
|
+
- lib/einvoice-qr-encryptor/core_ext/integer.rb
|
105
|
+
- lib/einvoice-qr-encryptor/error_message.rb
|
106
|
+
- lib/einvoice-qr-encryptor/version.rb
|
107
|
+
homepage: https://github.com/calvertyang/EInvoice-QR-Encryptor
|
108
|
+
licenses:
|
109
|
+
- MIT
|
110
|
+
metadata: {}
|
111
|
+
post_install_message:
|
112
|
+
rdoc_options: []
|
113
|
+
require_paths:
|
114
|
+
- lib
|
115
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
116
|
+
requirements:
|
117
|
+
- - ">="
|
118
|
+
- !ruby/object:Gem::Version
|
119
|
+
version: 2.1.5
|
120
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
121
|
+
requirements:
|
122
|
+
- - ">="
|
123
|
+
- !ruby/object:Gem::Version
|
124
|
+
version: '0'
|
125
|
+
requirements: []
|
126
|
+
rubyforge_project:
|
127
|
+
rubygems_version: 2.6.10
|
128
|
+
signing_key:
|
129
|
+
specification_version: 4
|
130
|
+
summary: E-Invoice QR code information encryptor
|
131
|
+
test_files: []
|