ovpn-key 1.2.1 → 1.2.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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ea36e4df1c13e126e977c4d1f6f5d57937f27186009998a4fd2ce651df6a23bb
4
- data.tar.gz: ae5b036e02416bb85cf67261ae6c5c86af107f50e935137f036835cc3d1f3602
3
+ metadata.gz: 6c2cea9c7523e028a8322b96932255cc47b665c1574a69d4ae5c592f1b313c37
4
+ data.tar.gz: 4b60cb71bc357423a9a59bfddd52efe6d2639da2855c1cfc444443cd0e7febb0
5
5
  SHA512:
6
- metadata.gz: b052653a567de6cf226737f1d250c6a4fe15026e9f6026ce9de9305935a1b5515e846b4a9eaf3b3477313a948bcf543274e7285ea1934870560223d182a89bcc
7
- data.tar.gz: 909b63e709afdbb3d3874060f0867330ec8623b1fc5eab77a4286f05822d6ec44958053ecae9de28d81488b63faf0a3c0f3543f153eba4f0c474717721e109e3
6
+ metadata.gz: e388615ef5d63737934da3e4e8f295f2a463f63e86a21bfe475dd58a682a643ebc176f715134c8de51ad74cfa550235e52e9fbb044f0866a7e2e6e8af9da5541
7
+ data.tar.gz: 91cd7617f121eaafe7ac5f133f580721a99fa58d956298efeefb345d0185176886eaf4eb79965b1f83f69f0c343c4fb23088392cc32bb08f54448f9109733b13
data/bin/ovpn-key CHANGED
@@ -185,25 +185,27 @@ if File.exist? 'openssl.ini'
185
185
  warn 'WARNING: openssl.ini file is not used anymore. you can remove it'
186
186
  end
187
187
 
188
- phase_out = nil
189
- unless ENCRYPT.casecmp? 'AES256'
190
- warn "WARNING: your CA uses #{ENCRYPT}, not AES256"
191
- phase_out = true
192
- end
193
- unless DIGEST&.match?(/\Asha(384|512)\z/i)
194
- warn "WARNING: your CA uses #{DIGEST}; SHA384 or SHA512 are recommended instead"
195
- phase_out = true
196
- end
197
- if KEY_TYPE && !KEY_TYPE&.match?(/\A(secp(384|521)r1|ML-DSA-87)\z/i)
198
- warn "WARNING: your CA uses #{KEY_TYPE}, we recommend using secp384r1, secp521r1, ML-DSA-87 or RSA"
199
- phase_out = true
200
- end
201
- if !KEY_TYPE && KEY_SIZE < 3072
202
- warn "WARNING: your CA uses #{KEY_SIZE}-bit keys, 3072 is a recommended minimum"
203
- phase_out = true
204
- end
205
- if phase_out
206
- warn "WARNING: it's recommended to phase out this deployment and start afresh with better security"
188
+ unless options[:init]
189
+ phase_out = nil
190
+ unless ENCRYPT.casecmp? 'AES256'
191
+ warn "WARNING: your CA uses #{ENCRYPT}, not AES256"
192
+ phase_out = true
193
+ end
194
+ unless DIGEST&.match?(/\Asha(384|512)\z/i)
195
+ warn "WARNING: your CA uses #{DIGEST}; SHA384 or SHA512 are recommended instead"
196
+ phase_out = true
197
+ end
198
+ if KEY_TYPE && !KEY_TYPE&.match?(/\A(secp(384|521)r1|ML-DSA-87)\z/i)
199
+ warn "WARNING: your CA uses #{KEY_TYPE}, we recommend using secp384r1, secp521r1, ML-DSA-87 or RSA"
200
+ phase_out = true
201
+ end
202
+ if !KEY_TYPE && KEY_SIZE < 3072
203
+ warn "WARNING: your CA uses #{KEY_SIZE}-bit keys, 3072 is a recommended minimum"
204
+ phase_out = true
205
+ end
206
+ if phase_out
207
+ warn "WARNING: it's recommended to phase out this deployment and start afresh with better security"
208
+ end
207
209
  end
208
210
 
209
211
  if options[:generate_ca]
@@ -213,7 +215,7 @@ if options[:generate_ca]
213
215
  sign_key('ca', CN_CA, ca_pass)
214
216
  gen_crl(ca_pass)
215
217
  rescue Interrupt, SystemExit
216
- cleanup 'ca' # delete the CA it it's not complete
218
+ cleanup 'ca' # delete the CA if it's not complete
217
219
  abort_on_interrupted
218
220
  end
219
221
  end
@@ -9,7 +9,7 @@ expire: # days
9
9
  server: 3650
10
10
  client: 3650
11
11
 
12
- ca_name: Certification Authority
12
+ ca_name: Certification Authority
13
13
  x509:
14
14
  C: US
15
15
  ST: CA
data/lib/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- VERSION = '1.2.1'
3
+ VERSION = '1.2.2'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ovpn-key
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.1
4
+ version: 1.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Vasily Korytov