summaryrefslogtreecommitdiffstats
path: root/usr/local/www/system_advanced_create_certs.php
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2004-11-19 18:29:51 +0000
committerScott Ullrich <sullrich@pfsense.org>2004-11-19 18:29:51 +0000
commite19a8890b772094fb2e15d5a38c277013d371476 (patch)
tree6145ce1ba71c9702144a498dad8806f0dfe1ed5a /usr/local/www/system_advanced_create_certs.php
parent340e6dca13577095b13f116e0fb2ff5e6f01820a (diff)
downloadpfsense-e19a8890b772094fb2e15d5a38c277013d371476.zip
pfsense-e19a8890b772094fb2e15d5a38c277013d371476.tar.gz
fix certificate creation
Diffstat (limited to 'usr/local/www/system_advanced_create_certs.php')
-rwxr-xr-xusr/local/www/system_advanced_create_certs.php9
1 files changed, 7 insertions, 2 deletions
diff --git a/usr/local/www/system_advanced_create_certs.php b/usr/local/www/system_advanced_create_certs.php
index 5a231e6..9254907 100755
--- a/usr/local/www/system_advanced_create_certs.php
+++ b/usr/local/www/system_advanced_create_certs.php
@@ -99,7 +99,12 @@ if ($_POST) {
<?php if ($savemsg) print_info_box($savemsg); ?>
<p>One moment please...
<?php
- mwexec("cd /tmp && openssl req -nodes -new > cert.csr && openssl rsa -in privkey.pem -out key.pem && openssl x509 -in cert.csr -out cert.pem -req -signkey key.pem -days 365");
+ //openssl genrsa -des3 -out privkey.pem 2048
+ //openssl req -new -x509 -nodes -key privkey.pem -out cacert.pem -days 100
+ mwexec("cd /tmp && openssl genrsa -passout pass:test -des3 -out privkey.pem 1024 && cat /tmp/privkey.pem");
+ mwexec("cd /tmp && openssl req -nodes -new > cert.csr");
+ mwexec("cd /tmp && openssl rsa -in privkey.pem -out key.pem");
+ mwexec("cd /tmp && openssl x509 -in cert.csr -out cert.pem -req -signkey key.pem -days 365");
$fd = fopen("/tmp/cert.pem", "r");
$cacert = fread($fd,8096);
fclose($fd);
@@ -117,7 +122,7 @@ if ($_POST) {
var cakey='<?=$cakey?>';
opener.document.forms[0].cert.value=cacert;
opener.document.forms[0].key.value=cakey;
- this.close();
+ //this.close();
-->
</script>
OpenPOWER on IntegriCloud