1 |
brianr |
1.1 |
diff -Nur -x '*.orig' -x '*.rej' phpki/phpki-0.82/ca/main.php mezzanine_patched_phpki/phpki-0.82/ca/main.php |
2 |
|
|
--- phpki/phpki-0.82/ca/main.php 2008-12-09 09:10:50.000000000 +0100 |
3 |
|
|
+++ mezzanine_patched_phpki/phpki-0.82/ca/main.php 2008-12-09 09:09:47.000000000 +0100 |
4 |
|
|
@@ -88,6 +88,18 @@ |
5 |
|
|
print '<pre>'.dhparam_text().'</pre>'; |
6 |
|
|
break; |
7 |
|
|
|
8 |
|
|
+case 'display_root_pem': |
9 |
|
|
+ printHeader(false); |
10 |
|
|
+ |
11 |
|
|
+ ?> |
12 |
|
|
+ <center><h2>Root certificate file (PEM Encoded)</h2></center> |
13 |
|
|
+ <p> |
14 |
|
|
+ <form action=<?=$PHP_SELF?> method=post> |
15 |
|
|
+ <input type=submit name=submit value="Back to Menu"> |
16 |
|
|
+ </form> |
17 |
|
|
+ <? |
18 |
|
|
+ print '<pre>'.root_pem_text().'</pre>'; |
19 |
|
|
+ break; |
20 |
|
|
|
21 |
|
|
|
22 |
|
|
default: |
23 |
|
|
@@ -117,7 +129,8 @@ |
24 |
|
|
<a href=../help.php target=_help>Read the online help</a> to learn more about this.</td></tr> |
25 |
|
|
|
26 |
|
|
<tr><td style="text-align: center; vertical-align: middle; font-weight: bold;"> |
27 |
|
|
- <a href=<?=$PHP_SELF?>?stage=dl_root>Download the Root Certificate</a></td> |
28 |
|
|
+ <a href=<?=$PHP_SELF?>?stage=dl_root>Download the Root Certificate</a><br><br> |
29 |
|
|
+ <a href=<?=$PHP_SELF?>?stage=display_root_pem>Display the Root Certificate (PEM Encoded)</a></td> |
30 |
|
|
<td>The "Root" certificate must be installed before using any of the |
31 |
|
|
certificates issued here. <a href=../help.php target=_help>Read the online help</a> |
32 |
|
|
to learn more about this.</td></tr> |
33 |
|
|
diff -Nur -x '*.orig' -x '*.rej' phpki/phpki-0.82/include/openssl_functions.php mezzanine_patched_phpki/phpki-0.82/include/openssl_functions.php |
34 |
|
|
--- phpki/phpki-0.82/include/openssl_functions.php 2008-12-09 09:10:50.000000000 +0100 |
35 |
|
|
+++ mezzanine_patched_phpki/phpki-0.82/include/openssl_functions.php 2008-12-09 09:10:28.000000000 +0100 |
36 |
|
|
@@ -428,7 +428,11 @@ |
37 |
|
|
return(shell_exec('cat '.escshellarg($config['private_dir']).'/dhparam1024.pem 2>&1')); |
38 |
|
|
} |
39 |
|
|
|
40 |
|
|
- |
41 |
|
|
+// Returns the root CA certificate file (PEM Encoded) |
42 |
|
|
+function root_pem_text() { |
43 |
|
|
+ global $config; |
44 |
|
|
+ return(shell_exec('cat '.escshellarg($config['cacert_pem']).' 2>&1')); |
45 |
|
|
+} |
46 |
|
|
|
47 |
|
|
// |
48 |
|
|
// Returns the subject of a certificate. |