openvpn: do not offer external CA for selection; closes #1467

This commit is contained in:
Franco Fichtner 2017-03-12 11:08:10 +01:00
parent 0a3db65932
commit 03e59623ba
2 changed files with 4 additions and 0 deletions

View File

@ -312,6 +312,7 @@
</field>
<field>
<type>certca_selection</type>
<internal>1</internal>
<name>certca</name>
<displayname>Certificate Authority</displayname>
<bindstofield>ovpnserver->step6->authcertca</bindstofield>

View File

@ -596,6 +596,9 @@ function showchange() {
echo "<option value='" . $field['add_to_certca_selection'] . "'" . $SELECTED . ">" . $field['add_to_certca_selection'] . "</option>\n";
}
foreach($config['ca'] as $ca) {
if (!empty($field['internal']) && empty($ca['prv'])) {
continue;
}
$name = htmlspecialchars($ca['descr']);
$SELECTED = "";
if ($value == $name) $SELECTED = " selected=\"selected\"";