From 1182cada25513ddd54e266a5ee3742b75a111f77 Mon Sep 17 00:00:00 2001 From: Benjamin Sonntag Date: Tue, 17 Jul 2018 18:16:56 +0200 Subject: [PATCH] [fix] now write ssl cert as ROOT, not as alterncpanel --- bureau/class/m_ssl.php | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/bureau/class/m_ssl.php b/bureau/class/m_ssl.php index de486b5b..d51de2c3 100644 --- a/bureau/class/m_ssl.php +++ b/bureau/class/m_ssl.php @@ -519,12 +519,6 @@ INSTR(CONCAT(sd.sub,IF(sd.sub!='','.',''),sd.domaine),'.')+1))=? $msg->raise("ERROR","ssl", _("Can't save the Key/Crt/Chain now. Please try later.")); return false; } - $this->write_cert_file(array( - "id"=>$id, - "sslcrt"=>$crt, - "sslkey"=>$key, - "sslchain"=>$chain - )); return $id; } @@ -668,6 +662,7 @@ SELECT ?,?,?, FROM_UNIXTIME(?), FROM_UNIXTIME(?), ?, ?, sslcsr FROM certificate $subdom["fqdn"]=$subdom["sub"].(($subdom["sub"])?".":"").$subdom["domaine"]; list($cert) = $this->get_valid_certs($subdom["fqdn"], $subdom["provider"]); + $this->write_cert_file($cert); // Edit certif_hosts: $db->query("UPDATE sub_domaines SET certificate_id=? WHERE id=?;",array($cert["id"], $subdom["id"])); }