r509-ca-http 0.1 → 0.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (34) hide show
  1. data/Rakefile +18 -18
  2. data/doc/R509/CertificateAuthority/Http/Factory/CsrFactory.html +11 -11
  3. data/doc/R509/CertificateAuthority/Http/Factory/SpkiFactory.html +11 -11
  4. data/doc/R509/CertificateAuthority/Http/Factory.html +9 -9
  5. data/doc/R509/CertificateAuthority/Http/Server.html +9 -9
  6. data/doc/R509/CertificateAuthority/Http/SubjectParser.html +22 -22
  7. data/doc/R509/CertificateAuthority/Http/ValidityPeriodConverter.html +19 -19
  8. data/doc/R509/CertificateAuthority/Http.html +11 -11
  9. data/doc/R509/CertificateAuthority.html +6 -6
  10. data/doc/R509.html +5 -5
  11. data/doc/_index.html +21 -21
  12. data/doc/class_list.html +2 -2
  13. data/doc/css/style.css +10 -0
  14. data/doc/file.README.html +7 -7
  15. data/doc/file_list.html +1 -1
  16. data/doc/frames.html +1 -1
  17. data/doc/index.html +7 -7
  18. data/doc/js/full_list.js +6 -1
  19. data/doc/method_list.html +10 -20
  20. data/doc/top-level-namespace.html +5 -5
  21. data/lib/r509/certificateauthority/http/factory.rb +12 -12
  22. data/lib/r509/certificateauthority/http/server.rb +219 -223
  23. data/lib/r509/certificateauthority/http/subjectparser.rb +27 -27
  24. data/lib/r509/certificateauthority/http/validityperiodconverter.rb +14 -14
  25. data/lib/r509/certificateauthority/http/version.rb +4 -4
  26. data/lib/r509/certificateauthority/http/views/test_issue.erb +73 -73
  27. data/lib/r509/certificateauthority/http/views/test_revoke.erb +19 -19
  28. data/lib/r509/certificateauthority/http/views/test_unrevoke.erb +14 -14
  29. data/spec/fixtures/test_config.yaml +14 -15
  30. data/spec/http_spec.rb +235 -227
  31. data/spec/spec_helper.rb +1 -1
  32. data/spec/subject_parser_spec.rb +2 -2
  33. data/spec/validity_period_converter_spec.rb +2 -2
  34. metadata +20 -20
@@ -1,84 +1,84 @@
1
1
  <html>
2
2
  <head>
3
- <title>Issue</title>
3
+ <title>Issue</title>
4
4
  </head>
5
5
  <body>
6
6
 
7
7
  <h1>Issue a certificate</h1>
8
8
 
9
9
  <form method="post" action="/1/certificate/issue/">
10
- <p>
11
- CA:
12
- <br />
13
- <input type="text" name="ca" />
14
- </p>
15
- <p>
16
- Profile:
17
- <br />
18
- <input type="text" name="profile" />
19
- </p>
20
- <p>
21
- Validity Period (in seconds):
22
- <br />
23
- <input type="text" name="validityPeriod" />
24
- </p>
25
- <p>
26
- C:
27
- <br />
28
- <input type="text" name="subject[C]" />
29
- </p>
30
- <p>
31
- ST:
32
- <br />
33
- <input type="text" name="subject[ST]" />
34
- </p>
35
- <p>
36
- L:
37
- <br />
38
- <input type="text" name="subject[L]" />
39
- </p>
40
- <p>
41
- O:
42
- <br />
43
- <input type="text" name="subject[O]" />
44
- </p>
45
- <p>
46
- OU:
47
- <br />
48
- <input type="text" name="subject[OU]" />
49
- </p>
50
- <p>
51
- CN:
52
- <br />
53
- <input type="text" name="subject[CN]" />
54
- </p>
55
- <p>
56
- emailAddress:
57
- <br />
58
- <input type="text" name="subject[emailAddress]" />
59
- </p>
60
- <p>
61
- SAN:
62
- <br />
63
- <input type="text" name="extensions[subjectAlternativeName][]" />
64
- <br />
65
- <input type="text" name="extensions[subjectAlternativeName][]" />
66
- <br />
67
- <input type="text" name="extensions[subjectAlternativeName][]" />
68
- <br />
69
- <input type="text" name="extensions[subjectAlternativeName][]" />
70
- <br />
71
- <input type="text" name="extensions[subjectAlternativeName][]" />
72
- <br />
73
- </p>
74
- <p>
75
- CSR:
76
- <br />
77
- <textarea name="csr" rows="6" cols="80"></textarea>
78
- </p>
79
- <p>
80
- <input type="submit" value="Gimme" />
81
- </p>
10
+ <p>
11
+ CA:
12
+ <br />
13
+ <input type="text" name="ca" />
14
+ </p>
15
+ <p>
16
+ Profile:
17
+ <br />
18
+ <input type="text" name="profile" />
19
+ </p>
20
+ <p>
21
+ Validity Period (in seconds):
22
+ <br />
23
+ <input type="text" name="validityPeriod" />
24
+ </p>
25
+ <p>
26
+ C:
27
+ <br />
28
+ <input type="text" name="subject[C]" />
29
+ </p>
30
+ <p>
31
+ ST:
32
+ <br />
33
+ <input type="text" name="subject[ST]" />
34
+ </p>
35
+ <p>
36
+ L:
37
+ <br />
38
+ <input type="text" name="subject[L]" />
39
+ </p>
40
+ <p>
41
+ O:
42
+ <br />
43
+ <input type="text" name="subject[O]" />
44
+ </p>
45
+ <p>
46
+ OU:
47
+ <br />
48
+ <input type="text" name="subject[OU]" />
49
+ </p>
50
+ <p>
51
+ CN:
52
+ <br />
53
+ <input type="text" name="subject[CN]" />
54
+ </p>
55
+ <p>
56
+ emailAddress:
57
+ <br />
58
+ <input type="text" name="subject[emailAddress]" />
59
+ </p>
60
+ <p>
61
+ SAN:
62
+ <br />
63
+ <input type="text" name="extensions[subjectAlternativeName][]" />
64
+ <br />
65
+ <input type="text" name="extensions[subjectAlternativeName][]" />
66
+ <br />
67
+ <input type="text" name="extensions[subjectAlternativeName][]" />
68
+ <br />
69
+ <input type="text" name="extensions[subjectAlternativeName][]" />
70
+ <br />
71
+ <input type="text" name="extensions[subjectAlternativeName][]" />
72
+ <br />
73
+ </p>
74
+ <p>
75
+ CSR:
76
+ <br />
77
+ <textarea name="csr" rows="6" cols="80"></textarea>
78
+ </p>
79
+ <p>
80
+ <input type="submit" value="Gimme" />
81
+ </p>
82
82
  </form>
83
83
 
84
84
  </body>
@@ -1,30 +1,30 @@
1
1
  <html>
2
2
  <head>
3
- <title>Revoke</title>
3
+ <title>Revoke</title>
4
4
  </head>
5
5
  <body>
6
6
 
7
7
  <h1>Revoke a certificate</h1>
8
8
 
9
9
  <form method="post" action="/1/certificate/revoke/">
10
- <p>
11
- CA:
12
- <br />
13
- <input type="text" name="ca" />
14
- </p>
15
- <p>
16
- Serial:
17
- <br />
18
- <input type="text" name="serial" />
19
- </p>
20
- <p>
21
- Reason:
22
- <br />
23
- <input type="text" name="reason" value="0" />
24
- </p>
25
- <p>
26
- <input type="submit" value="Revoke" />
27
- </p>
10
+ <p>
11
+ CA:
12
+ <br />
13
+ <input type="text" name="ca" />
14
+ </p>
15
+ <p>
16
+ Serial:
17
+ <br />
18
+ <input type="text" name="serial" />
19
+ </p>
20
+ <p>
21
+ Reason:
22
+ <br />
23
+ <input type="text" name="reason" value="0" />
24
+ </p>
25
+ <p>
26
+ <input type="submit" value="Revoke" />
27
+ </p>
28
28
  </form>
29
29
 
30
30
  </body>
@@ -1,25 +1,25 @@
1
1
  <html>
2
2
  <head>
3
- <title>Unrevoke</title>
3
+ <title>Unrevoke</title>
4
4
  </head>
5
5
  <body>
6
6
 
7
7
  <h1>Unrevoke a certificate</h1>
8
8
 
9
9
  <form method="post" action="/1/certificate/unrevoke/">
10
- <p>
11
- CA:
12
- <br />
13
- <input type="text" name="ca" />
14
- </p>
15
- <p>
16
- Serial:
17
- <br />
18
- <input type="text" name="serial" />
19
- </p>
20
- <p>
21
- <input type="submit" value="Unrevoke" />
22
- </p>
10
+ <p>
11
+ CA:
12
+ <br />
13
+ <input type="text" name="ca" />
14
+ </p>
15
+ <p>
16
+ Serial:
17
+ <br />
18
+ <input type="text" name="serial" />
19
+ </p>
20
+ <p>
21
+ <input type="submit" value="Unrevoke" />
22
+ </p>
23
23
  </form>
24
24
 
25
25
  </body>
@@ -1,18 +1,17 @@
1
1
  certificate_authorities: {
2
- test_ca: {
3
- ca_cert: {
4
- cert: "test_ca.cer",
5
- key: "test_ca.key"
6
- },
7
- cdp_location: 'URI:http://crl.domain.com/test_ca.crl',
8
- message_digest: 'SHA1', #SHA1, SHA256, SHA512 supported. MD5 too, but you really shouldn't use that unless you have a good reason
9
- profiles: {
10
- server: {
11
- basic_constraints: "CA:FALSE",
12
- key_usage: [digitalSignature,keyEncipherment],
13
- extended_key_usage: [serverAuth],
14
- certificate_policies: [ [ "policyIdentifier=2.16.840.1.9999999999.1.2.3.4.1", "CPS.1=http://example.com/cps"] ]
15
- }
16
- }
2
+ test_ca: {
3
+ ca_cert: {
4
+ cert: "test_ca.cer",
5
+ key: "test_ca.key"
6
+ },
7
+ cdp_location: ['http://crl.domain.com/test_ca.crl'],
8
+ message_digest: 'SHA1', #SHA1, SHA256, SHA512 supported. MD5 too, but you really shouldn't use that unless you have a good reason
9
+ profiles: {
10
+ server: {
11
+ basic_constraints: { "ca" : false },
12
+ key_usage: [digitalSignature,keyEncipherment],
13
+ extended_key_usage: [serverAuth]
14
+ }
17
15
  }
16
+ }
18
17
  }