Skip to content

Commit

Permalink
CIL-624 Add config option DISABLE_X509 to prevent downloading of cert…
Browse files Browse the repository at this point in the history
…ificates.
  • Loading branch information
terrencegf committed Apr 25, 2020
1 parent fca0dd6 commit 36b1963
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/Service/Content.php
Original file line number Diff line number Diff line change
Expand Up @@ -403,6 +403,12 @@ class="btn btn-primary submit"
*/
public static function printGetCertificate()
{
// CIL-624 If DISABLE_X509 is true, then don't even print out the
// Get New Certificate box.
if ((defined('DISABLE_X509')) && (DISABLE_X509 === true)) {
return;
}

// Check if PKCS12 downloading is disabled. If so, print out message.
$disabledmsg = '';
$disabledbyconf = ((!defined('MYPROXY_LOGON')) || (empty(MYPROXY_LOGON)));
Expand Down Expand Up @@ -680,6 +686,12 @@ class="btn btn-primary submit"
*/
public static function printCertInfo()
{
// CIL-624 If DISABLE_X509 is true, then don't even print out the
// Certificate Information box.
if ((defined('DISABLE_X509')) && (DISABLE_X509 === true)) {
return;
}

$dn = Util::getSessionVar('distinguished_name');
static::printCollapseBegin('certinfo', 'Certificate Information');
if (strlen($dn) > 0) {
Expand Down

0 comments on commit 36b1963

Please sign in to comment.