File: add-missing-x509v3-extensions-in-spec

package info (click to toggle)
ruby-http 1.0.2-4
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 520 kB
  • ctags: 322
  • sloc: ruby: 3,934; makefile: 8
file content (23 lines) | stat: -rw-r--r-- 621 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
Index: ruby-http/spec/support/ssl_helper.rb
===================================================================
--- ruby-http.orig/spec/support/ssl_helper.rb	2016-12-05 22:51:31.319414848 -0500
+++ ruby-http/spec/support/ssl_helper.rb	2016-12-05 22:53:22.212685884 -0500
@@ -33,6 +33,8 @@
   end
 
   class ChildCertificate < ::CertificateAuthority::Certificate
+    EXTENSIONS = {"extendedKeyUsage" => {"usage" => %w(serverAuth clientAuth)}}
+
     def initialize(parent)
       super()
 
@@ -43,7 +45,8 @@
 
       self.parent = parent
 
-      sign!
+      sign!("extensions" => EXTENSIONS)
+
     end
 
     def cert