Przeglądaj źródła

Merge branch 'master' of github.com:serghey-rodin/vesta

Serghey Rodin 9 lat temu
rodzic
commit
1bb6ecb2ba

+ 8 - 0
bin/v-add-sys-ip

@@ -142,6 +142,14 @@ if [ ! -z "$PROXY_SYSTEM" ]; then
         rpaf_str="$rpaf_str $ip"
         sed -i "s/.*RPAFproxy_ips.*/$rpaf_str/" $rpaf_conf
     fi
+
+    #mod_remoteip
+    remoteip_conf="/etc/$WEB_SYSTEM/mods-enabled/remoteip.conf"
+    if [ -e "$remoteip_conf" ]; then
+        if [ $( grep -ic "$ip" $remoteip_conf ) -eq 0 ]; then
+            sed -i "s/<\/IfModule>/RemoteIPInternalProxy $ip\n<\/IfModule>/g" $remoteip_conf
+        fi
+    fi
 fi
 
 

+ 6 - 0
bin/v-delete-sys-ip

@@ -99,6 +99,12 @@ if [ ! -z "$PROXY_SYSTEM" ]; then
         new_ips=$(echo "$rpaf_str" | sed "s/$ip//")
         sed -i "s/$ips/$new_ips/g" $rpaf_conf
     fi
+    
+    #mod_remoteip
+    remoteip_conf="/etc/$WEB_SYSTEM/mods-enabled/remoteip.conf"
+    if [ -e "$remoteip_conf" ]; then
+        sed -i "s/RemoteIPInternalProxy $ip//g" $remoteip_conf
+    fi
 fi
 
 

+ 4 - 1
func/main.sh

@@ -583,7 +583,10 @@ is_date_format_valid() {
 # Database user validator
 is_dbuser_format_valid() {
     exclude="[!|@|#|$|^|&|*|(|)|+|=|{|}|:|,|<|>|?|/|\|\"|'|;|%|\`| ]"
-    if [[ "$1" =~ $exclude ]] || [ 17 -le ${#1} ]; then
+    if [ 17 -le ${#1} ]; then
+		check_result $E_INVALID "mysql username can be up to 16 characters long"
+	fi
+    if [[ "$1" =~ $exclude ]]; then
         check_result $E_INVALID "invalid $2 format :: $1"
     fi
 }

+ 11 - 1
install/rhel/6/roundcube/vesta.php

@@ -42,7 +42,17 @@ class rcube_vesta_password
         $send .= PHP_EOL;
         $send .= $postdata . PHP_EOL . PHP_EOL;
 
-        $fp = fsockopen('ssl://' . $vesta_host, $vesta_port);
+        //$fp = fsockopen('ssl://' . $vesta_host, $vesta_port);
+        $errno = "";
+        $errstr = "";
+        $context = stream_context_create();
+
+        $result = stream_context_set_option($context, 'ssl', 'verify_peer', false);
+        $result = stream_context_set_option($context, 'ssl', 'verify_host', false);
+        $result = stream_context_set_option($context, 'ssl', 'allow_self_signed', true);
+
+        $fp = stream_socket_client('ssl://' . $vesta_host . ':'.$vesta_port, $errno, $errstr, 60, STREAM_CLIENT_CONNECT, $context);
+
         fputs($fp, $send);
         $result = fread($fp, 2048);
         fclose($fp);

+ 11 - 1
install/rhel/7/roundcube/vesta.php

@@ -42,7 +42,17 @@ class rcube_vesta_password
         $send .= PHP_EOL;
         $send .= $postdata . PHP_EOL . PHP_EOL;
 
-        $fp = fsockopen('ssl://' . $vesta_host, $vesta_port);
+        //$fp = fsockopen('ssl://' . $vesta_host, $vesta_port);
+        $errno = "";
+        $errstr = "";
+        $context = stream_context_create();
+
+        $result = stream_context_set_option($context, 'ssl', 'verify_peer', false);
+        $result = stream_context_set_option($context, 'ssl', 'verify_host', false);
+        $result = stream_context_set_option($context, 'ssl', 'allow_self_signed', true);
+
+        $fp = stream_socket_client('ssl://' . $vesta_host . ':'.$vesta_port, $errno, $errstr, 60, STREAM_CLIENT_CONNECT, $context);
+
         fputs($fp, $send);
         $result = fread($fp, 2048);
         fclose($fp);

+ 6 - 5
install/vst-install-rhel.sh

@@ -1159,6 +1159,7 @@ if [ "$exim" = 'yes' ] && [ "$mysql" = 'yes' ]; then
     cd /usr/share/roundcubemail/plugins/password
     wget $vestacp/roundcube/vesta.php -O drivers/vesta.php
     wget $vestacp/roundcube/config.inc.php -O config.inc.php
+    sed -i "s/localhost/$servername/g" /usr/share/roundcubemail/plugins/password/config.inc.php
     chmod a+r /etc/roundcubemail/*
     chmod -f 777 /var/log/roundcubemail
     r="$(gen_pass)"
@@ -1226,6 +1227,11 @@ $VESTA/bin/v-update-sys-ip
 # Get main ip
 ip=$(ip addr|grep 'inet '|grep global|head -n1|awk '{print $2}'|cut -f1 -d/)
 
+# Firewall configuration
+if [ "$iptables" = 'yes' ]; then
+    $VESTA/bin/v-update-firewall
+fi
+
 # Get public ip
 pub_ip=$(curl -s vestacp.com/what-is-my-ip/)
 if [ ! -z "$pub_ip" ] && [ "$pub_ip" != "$ip" ]; then
@@ -1233,11 +1239,6 @@ if [ ! -z "$pub_ip" ] && [ "$pub_ip" != "$ip" ]; then
     ip=$pub_ip
 fi
 
-# Firewall configuration
-if [ "$iptables" = 'yes' ]; then
-    $VESTA/bin/v-update-firewall
-fi
-
 # Configuring mysql host
 if [ "$mysql" = 'yes' ]; then
     $VESTA/bin/v-add-database-host mysql localhost root $vpass

+ 5 - 5
install/vst-install-ubuntu.sh

@@ -1125,6 +1125,11 @@ $VESTA/bin/v-update-sys-ip
 # Get main ip
 ip=$(ip addr|grep 'inet '|grep global|head -n1|awk '{print $2}'|cut -f1 -d/)
 
+# Firewall configuration
+if [ "$iptables" = 'yes' ]; then
+    $VESTA/bin/v-update-firewall
+fi
+
 # Get public ip
 pub_ip=$(curl -s vestacp.com/what-is-my-ip/)
 if [ ! -z "$pub_ip" ] && [ "$pub_ip" != "$ip" ]; then
@@ -1132,11 +1137,6 @@ if [ ! -z "$pub_ip" ] && [ "$pub_ip" != "$ip" ]; then
     ip=$pub_ip
 fi
 
-# Firewall configuration
-if [ "$iptables" = 'yes' ]; then
-    $VESTA/bin/v-update-firewall
-fi
-
 # Configuring mysql host
 if [ "$mysql" = 'yes' ]; then
     $VESTA/bin/v-add-database-host mysql localhost root $vpass

+ 10 - 0
web/css/styles.min.css

@@ -2623,6 +2623,15 @@ a.vst-text:active b{
   margin: 2px 6px 0 3px;
   padding: 5px;
 }
+.lets-encrypt-note {
+  color: #89a40a !important;
+  font-style: italic;
+  font-weight: normal !important;
+  height: 30px;
+  padding-top: 10px;
+  vertical-align: top;
+}
+
 .additional-control {
   margin-left: 17px;
   color: #2C9491;
@@ -2695,6 +2704,7 @@ td.hint {
   font-style: italic;
   font-weight: normal;
 }
+.ftp-path-prefix { padding-top: 7px; }
 
 .ui-button,
 .button {

+ 3 - 0
web/inc/i18n/ar.php

@@ -190,6 +190,9 @@ $LANG['ar'] = array(
     'template'  => 'نموذج',
     'SSL Support'  => 'دعم SSL',
     'SSL Home Directory'  => 'المجلد الرئيسي لـ SSL',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support'  => 'دغم بروكسي',
     'Proxy Extensions'  => 'توسعات بروكسي',
     'Web Statistics'  => 'إحصائيات الوب',

+ 3 - 0
web/inc/i18n/bs.php

@@ -190,6 +190,9 @@ $LANG['bs'] = array(
     'template'  => 'šablon',
     'SSL Support'  => 'SSL podrška',
     'SSL Home Directory'  => 'SSL direktorij',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
+    'Lets Encrypt'  => 'Lets Encrypt',
     'Proxy Support'  => 'Proxy podrška',
     'Proxy Extensions'  => 'Proxy ekstenzije',
     'Web Statistics'  => 'Web statistika',

+ 3 - 0
web/inc/i18n/cn.php

@@ -191,6 +191,9 @@ $LANG['cn'] = array(
     'template' => '模板',
     'SSL Support' => 'SSL支持',
     'SSL Home Directory' => 'SSL主目录',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support' => '代理支持',
     'Proxy Extensions' => '代理扩展名',
     'Web Statistics' => '网站统计',

+ 3 - 0
web/inc/i18n/cz.php

@@ -191,6 +191,9 @@ $LANG['cz'] = array(
     'template'  => 'šablona',
     'SSL Support'  => 'SSL podpora',
     'SSL Home Directory'  => 'SSL home adresář',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support'  => 'Proxy podpora',
     'Proxy Extensions'  => 'Proxy rozšíření',
     'Web Statistics'  => 'Webové statistiky',

+ 3 - 0
web/inc/i18n/da.php

@@ -192,6 +192,9 @@ $LANG['da'] = array(
     'template'  => 'skabelon',
     'SSL Support'  => 'SSL Support',
     'SSL Home Directory'  => 'SSL Home',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support'  => 'Proxy Support',
     'Proxy Extensions'  => 'Proxy Tilføjelser',
     'Web Statistics'  => 'Web Statistik',

+ 3 - 0
web/inc/i18n/de.php

@@ -190,6 +190,9 @@ $LANG['de'] = array(
     'template'  => 'Template',
     'SSL Support'  => 'SSL Unterstützung',
     'SSL Home Directory'  => 'SSL Homeverzeichnis',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support'  => 'Proxy Unterstützung',
     'Proxy Extensions'  => 'Proxy Erweiterungen',
     'Web Statistics'  => 'Web Statistiken',

+ 3 - 0
web/inc/i18n/el.php

@@ -191,6 +191,9 @@ $LANG['el'] = array(
     'template'  => 'template',
     'SSL Support'  => 'Υποστήριξη SSL',
     'SSL Home Directory'  => 'Αρχικός Κατάλογος SSL',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support'  => 'Υποστήριξη Proxy',
     'Proxy Extensions'  => 'Πρόσθετα Proxy',
     'Web Statistics'  => 'Στατιστικά Web',

+ 2 - 0
web/inc/i18n/en.php

@@ -190,6 +190,8 @@ $LANG['en'] = array(
     'template'  => 'template',
     'SSL Support'  => 'SSL Support',
     'SSL Home Directory'  => 'SSL Home',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
     'Proxy Support'  => 'Proxy Support',
     'Proxy Extensions'  => 'Proxy Extensions',
     'Web Statistics'  => 'Web Statistics',

+ 3 - 0
web/inc/i18n/es.php

@@ -191,6 +191,9 @@ $LANG['es'] = array(
     'template'  => 'plantilla',
     'SSL Support'  => 'Soporte SSL',
     'SSL Home Directory'  => 'SSL Del Directorio Local',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support'  => 'Soporte Proxy',
     'Proxy Extensions'  => 'Extensiones Proxy',
     'Web Statistics'  => 'Estadísticas Web',

+ 3 - 0
web/inc/i18n/fa.php

@@ -193,6 +193,9 @@ $LANG['fa'] = [
     'template' => 'قالب',
     'SSL Support' => 'پشتیبانی SSL',
     'SSL Home Directory' => 'خانه SSL',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support' => 'پشتیبانی Proxy',
     'Proxy Extensions' => 'فرمت های Proxy',
     'Web Statistics' => 'آمار هاي وب',

+ 3 - 0
web/inc/i18n/fi.php

@@ -192,6 +192,9 @@ $LANG['fi'] = array(
     'template' => 'pohjat',
     'SSL Support' => 'SSL-tuki',
     'SSL Home Directory' => 'SSL-kotihakemisto',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support' => 'Proxy-tuki',
     'Proxy Extensions' => 'Proxy-laajennukset',
     'Web Statistics' => 'Web-tilastot',

+ 3 - 0
web/inc/i18n/fr.php

@@ -190,6 +190,9 @@ $LANG['fr'] = array(
     'template'  => 'template',
     'SSL Support'  => 'Support SSL',
     'SSL Home Directory'  => 'Racine SSL',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support'  => 'Support Proxy',
     'Proxy Extensions'  => 'Extensions Proxy',
     'Web Statistics'  => 'Statistiques Web',

+ 3 - 0
web/inc/i18n/hu.php

@@ -194,6 +194,9 @@ $LANG['hu'] = array(
     'template'  => 'sablon',
     'SSL Support'  => 'SSL támogatás',
     'SSL Home Directory'  => 'SSL kezdőlap',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support'  => 'Proxy támogatás',
     'Proxy Extensions'  => 'Proxy kiterjesztések',
     'Web Statistics'  => 'Web statisztikák',

+ 3 - 0
web/inc/i18n/id.php

@@ -193,6 +193,9 @@ $LANG['id'] = array(
     'template'  => 'kerangka',
     'SSL Support'  => 'Dukungan SSL',
     'SSL Home Directory'  => 'Direktori SSL Home',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support'  => 'Dukungan Proxy',
     'Proxy Extensions'  => 'Ekstensi Proxy',
     'Web Statistics'  => 'Statistik Web',

+ 3 - 0
web/inc/i18n/it.php

@@ -191,6 +191,9 @@ $LANG['it'] = array(
     'template'  => 'template',
     'SSL Support'  => 'Supporto SSL',
     'SSL Home Directory'  => 'SSL Home',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support'  => 'Supporto Proxy',
     'Proxy Extensions'  => 'Estensioni Proxy',
     'Web Statistics'  => 'Statistiche Web',

+ 3 - 0
web/inc/i18n/ja.php

@@ -190,6 +190,9 @@ $LANG['ja'] = array(
     'template'  => 'テンプレート',
     'SSL Support'  => 'SSLのサポート',
     'SSL Home Directory'  => 'SSLホームディレクトリ',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support'  => 'プロキシのサポート',
     'Proxy Extensions'  => 'プロキシ対象拡張子',
     'Web Statistics'  => 'ウェブアクセス統計',

+ 3 - 0
web/inc/i18n/ka.php

@@ -190,6 +190,9 @@ $LANG['ka'] = array(
     'template'  => 'შაბლონი',
     'SSL Support'  => 'SSL მხარდაჭერა',
     'SSL Home Directory'  => 'SSL მთავარი დირექტორია',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support'  => 'პროქსის მხარდაჭერა',
     'Proxy Extensions'  => 'პროქსის გაფართოებები',
     'Web Statistics'  => 'ვებ სტატისტიკა',

+ 3 - 0
web/inc/i18n/nl.php

@@ -191,6 +191,9 @@ $LANG['nl'] = array(
     'template'  => 'sjabloon',
     'SSL Support'  => 'SSL Ondersteuning',
     'SSL Home Directory'  => 'SSL Map',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support'  => 'Proxy Ondersteuning',
     'Proxy Extensions'  => 'Proxy Extensies',
     'Web Statistics'  => 'Web Statistieken',

+ 3 - 0
web/inc/i18n/no.php

@@ -191,6 +191,9 @@ $LANG['no'] = array(
     'template'  => 'mal',
     'SSL Support'  => 'SSL Støtte',
     'SSL Home Directory'  => 'SSL Hjem',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support'  => 'Proxy Støtte',
     'Proxy Extensions'  => 'Proxy Utvidelser',
     'Web Statistics'  => 'Web Statistikker',

+ 3 - 0
web/inc/i18n/pl.php

@@ -190,6 +190,9 @@ $LANG['pl'] = array(
     'template'  => 'szablon',
     'SSL Support'  => 'Wsparcie dla SSL',
     'SSL Home Directory'  => 'Folder główny SSL',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support'  => 'Wsparcie dla Proxy',
     'Proxy Extensions'  => 'Rozszerzenia Proxy',
     'Web Statistics'  => 'Statystyki Web',

+ 10 - 7
web/inc/i18n/pt-BR.php

@@ -190,6 +190,9 @@ $LANG['pt-BR'] = array(
     'template'  => 'template',
     'SSL Support'  => 'Suporte SSL',
     'SSL Home Directory'  => 'Diretório Home SSL',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support'  => 'Suporte ao Proxy',
     'Proxy Extensions'  => 'Extenções do Proxy',
     'Web Statistics'  => 'Estatísticas Web',
@@ -739,13 +742,13 @@ $LANG['pt-BR'] = array(
     'PUB_KEY' => 'PUB_KEY',
     'ISSUER' => 'ISSUER',
 
-    'Use server hostname' => 'Use server hostname',
-    'Use domain hostname' => 'Use domain hostname',
-    'Use STARTTLS' => 'Use STARTTLS',
-    'Use SSL' => 'Use SSL',
-    'No encryption' => 'No encryption',
-    'Do not use encryption' => 'Do not use encryption',
+    'Use server hostname' => 'Usar hostname do servidor',
+    'Use domain hostname' => 'Usar hostname do dominio',
+    'Use STARTTLS' => 'Usar STARTTLS',
+    'Use SSL' => 'Usar SSL',
+    'No encryption' => 'Nenhuma criptografia',
+    'Do not use encryption' => 'Não usar criptografia',
 
-    'maximum characters length, including prefix' => 'maximum %s characters length, including prefix',
+    'maximum characters length, including prefix' => 'comprimento máximo de % caracteres, incluindo o prefixo',
 
 );

+ 3 - 0
web/inc/i18n/pt.php

@@ -190,6 +190,9 @@ $LANG['pt'] = array(
     'template'  => 'template',
     'SSL Support'  => 'Suporte SSL',
     'SSL Home Directory'  => 'Diretório Home SSL',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support'  => 'Suporte ao Proxy',
     'Proxy Extensions'  => 'Extenções do Proxy',
     'Web Statistics'  => 'Estatísticas Web',

+ 3 - 0
web/inc/i18n/ro.php

@@ -192,6 +192,9 @@ $LANG['ro'] = array(
     'template' => 'șablon',
     'SSL Support' => 'Support SSL',
     'SSL Home Directory' => 'Director SSL',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support' => 'Suport Proxy',
     'Proxy Extensions' => 'Extensii Proxy',
     'Web Statistics' => 'Statistici web',

+ 3 - 0
web/inc/i18n/ru.php

@@ -191,6 +191,9 @@ $LANG['ru'] = array(
     'template' => 'шаблон',
     'SSL Support' => 'Поддержка SSL',
     'SSL Home Directory' => 'Директория SSL',
+    'Lets Encrypt Support'  => 'Поддержка Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Сертификат будет автоматически создан в течении 5-ти минут',
+    'Lets Encrypt'  => 'Lets Encrypt',
     'Proxy Support' => 'Поддержка Proxy',
     'Proxy Extensions' => 'Обработка Proxy',
     'Web Statistics' => 'Статистика сайта',

+ 3 - 0
web/inc/i18n/se.php

@@ -190,6 +190,9 @@ $LANG['se'] = array(
     'template'  => 'mall',
     'SSL Support'  => 'SSL-stöd',
     'SSL Home Directory'  => 'Hemmakatalog för SSL',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support'  => 'Nginx-stöd',
     'Proxy Extensions'  => 'Nginx-tillägg',
     'Web Statistics'  => 'Webbstatistik',

+ 3 - 0
web/inc/i18n/tr.php

@@ -191,6 +191,9 @@ $LANG['tr'] = array(
     'template'  => 'template',
     'SSL Support'  => 'SSL Support',
     'SSL Home Directory'  => 'SSL Home',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support'  => 'Proxy Desteği',
     'Proxy Extensions'  => 'Proxy Uzantıları',
     'Web Statistics'  => 'Web İstatistikleri',

+ 3 - 0
web/inc/i18n/tw.php

@@ -192,6 +192,9 @@ $LANG['tw'] = array(
     'template'  => '模板',
     'SSL Support'  => 'SSL支援',
     'SSL Home Directory'  => 'SSL主目錄',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support'  => 'Nginx支援',
     'Proxy Extensions'  => 'Nginx擴充',
     'Web Statistics'  => '網站統計',

+ 3 - 0
web/inc/i18n/ua.php

@@ -191,6 +191,9 @@ $LANG['ua'] = array(
     'template' => 'шаблон',
     'SSL Support' => 'Підтримка SSL',
     'SSL Home Directory' => 'Домашня тека SSL',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support' => 'Підтримка Proxy',
     'Proxy Extensions' => 'Розширення Proxy',
     'Web Statistics' => 'Веб статистика',

+ 3 - 0
web/inc/i18n/vi.php

@@ -190,6 +190,9 @@ $LANG['vi'] = array(
     'template'  => 'mẫu',
     'SSL Support'  => 'Hỗ trợ SSL',
     'SSL Home Directory'  => 'Trang chủ SSL',
+    'Lets Encrypt Support'  => 'Lets Encrypt Support',
+    'Lets Encrypt'  => 'Lets Encrypt',
+    'Your certificate will be automatically issued in 5 minutes' => 'Your certificate will be automatically issued in 5 minutes',
     'Proxy Support'  => 'Hỗ trợ Nginx',
     'Proxy Extensions'  => 'Phần mở rộng Nginx',
     'Web Statistics'  => 'Thống kê Web',

+ 3 - 3
web/js/pages/add_mail_acc.js

@@ -134,14 +134,14 @@ $(document).ready(function() {
                 $('#td_smtp_port').html('465');
                 $('#td_smtp_encryption').html('SSL');
                 break;
-            case 'no_encription':
+            case 'no_encryption':
                 $('#td_imap_hostname').html(opt.attr('domain'));
                 $('#td_smtp_hostname').html(opt.attr('domain'));
 
                 $('#td_imap_port').html('143');
-                $('#td_imap_encryption').html(opt.attr('no_encription'));
+                $('#td_imap_encryption').html(opt.attr('no_encryption'));
                 $('#td_smtp_port').html('25');
-                $('#td_smtp_encryption').html(opt.attr('no_encription'));
+                $('#td_smtp_encryption').html(opt.attr('no_encryption'));
                 break;
         }
     });

+ 2 - 4
web/js/pages/add_web.js

@@ -154,15 +154,13 @@ App.Actions.WEB.toggle_additional_ftp_accounts = function(elm) {
 App.Actions.WEB.toggle_letsencrypt = function(elm) {
     if ($(elm).attr('checked')) {
         $('#ssltable textarea[name=v_ssl_crt],#ssltable textarea[name=v_ssl_key], #ssltable textarea[name=v_ssl_ca]').attr('disabled', 'disabled');
-//        $('input[name=v_ssl]').prop('checked', true);
-//        $('#ssltable').show();
         $('#generate-csr').hide();
+	$('.lets-encrypt-note').show();
     }
     else {
         $('#ssltable textarea[name=v_ssl_crt],#ssltable textarea[name=v_ssl_key], #ssltable textarea[name=v_ssl_ca]').removeAttr('disabled');
-//        $('input[name=v_ssl]').prop('checked', false);
-//        $('#ssltable').hide();
         $('#generate-csr').show();
+	$('.lets-encrypt-note').hide();
     }
 }
 

+ 3 - 3
web/js/pages/edit_mail_acc.js

@@ -135,14 +135,14 @@ $(document).ready(function() {
                 $('#td_smtp_port').html('465');
                 $('#td_smtp_encryption').html('SSL');
                 break;
-            case 'no_encription':
+            case 'no_encriptyon':
                 $('#td_imap_hostname').html(opt.attr('domain'));
                 $('#td_smtp_hostname').html(opt.attr('domain'));
 
                 $('#td_imap_port').html('143');
-                $('#td_imap_encryption').html(opt.attr('no_encription'));
+                $('#td_imap_encryption').html(opt.attr('no_encryption'));
                 $('#td_smtp_port').html('25');
-                $('#td_smtp_encryption').html(opt.attr('no_encription'));
+                $('#td_smtp_encryption').html(opt.attr('no_encryption'));
                 break;
         }
     });

+ 6 - 7
web/js/pages/edit_web.js

@@ -135,15 +135,15 @@ App.Actions.WEB.toggle_additional_ftp_accounts = function(elm) {
 App.Actions.WEB.toggle_letsencrypt = function(elm) {
     if ($(elm).attr('checked')) {
         $('#ssltable textarea[name=v_ssl_crt],#ssltable textarea[name=v_ssl_key], #ssltable textarea[name=v_ssl_ca]').attr('disabled', 'disabled');
-        $('input[name=v_ssl]').prop('checked', true);
-        $('#ssltable').show();
         $('#generate-csr').hide();
+	if(!$('.lets-encrypt-note').hasClass('enabled')){
+	    $('.lets-encrypt-note').show();
+	}
     }
     else {
         $('#ssltable textarea[name=v_ssl_crt],#ssltable textarea[name=v_ssl_key], #ssltable textarea[name=v_ssl_ca]').removeAttr('disabled');
-        $('input[name=v_ssl]').prop('checked', false);
-        $('#ssltable').hide();
         $('#generate-csr').show();
+	$('.lets-encrypt-note').hide();
     }
 }
 
@@ -180,9 +180,8 @@ $(function() {
         var elm = $(evt.target);
         App.Actions.WEB.passwordChanged(elm);
     });
-    if ($('input[name=v_letsencrypt]').attr('checked')) {
-        App.Actions.WEB.toggle_letsencrypt($('input[name=v_letsencrypt]'))
-    }
+    App.Actions.WEB.toggle_letsencrypt($('input[name=v_letsencrypt]'));
+
     $('select[name="v_stats"]').change(function(evt){
         var select = $(evt.target);
 

+ 1 - 1
web/templates/admin/add_mail_acc.html

@@ -140,7 +140,7 @@
                                     <option v_type="hostname" domain="<?=$v_domain?>"><?=__('Use domain hostname')?></option>
                                     <option v_type="starttls"><?=__('Use STARTTLS')?></option>
                                     <option v_type="ssl"><?=__('Use SSL')?></option>
-                                    <option v_type="no_encription" domain="<?=$v_domain?>" encription="<?=__('No encryption')?>"><?=__('No encryption')?></option>
+                                    <option v_type="no_encryption" domain="<?=$v_domain?>" encryption="<?=__('No encryption')?>"><?=__('No encryption')?></option>
                                 </select>
                             </td>
                         </tr>

+ 5 - 0
web/templates/admin/add_web.html

@@ -135,6 +135,11 @@
 				      </td>
 				  </tr>
                                   <tr>
+                                      <td class="vst-text input-label lets-encrypt-note step-left" >
+                                          <?= __('Your certificate will be automatically issued in 5 minutes')?>
+                                      </td>
+                                  </tr>
+			          <tr>
                                         <td class="vst-text input-label step-left">
                                             <?php print __('SSL Home Directory');?>
                                         </td>

+ 2 - 2
web/templates/admin/edit_mail_acc.html

@@ -149,7 +149,7 @@
                                     <option v_type="hostname" domain="<?=$v_domain?>"><?=__('Use domain hostname')?></option>
                                     <option v_type="starttls"><?=__('Use STARTTLS')?></option>
                                     <option v_type="ssl"><?=__('Use SSL')?></option>
-                                    <option v_type="no_encription" domain="<?=$v_domain?>" encription="<?=__('No encryption')?>"><?=__('No encryption')?></option>
+                                    <option v_type="no_encryption" domain="<?=$v_domain?>" encryption="<?=__('No encryption')?>"><?=__('No encryption')?></option>
                                 </select>
                             </td>
                         </tr>
@@ -187,7 +187,7 @@
                         </tr>
                         <tr>
                             <td><?=__('SMTP security')?>:</td>
-                            <td><div id="td_smtp_encription"><?=__('STARTTLS')?></div></td>
+                            <td><div id="td_smtp_encryption"><?=__('STARTTLS')?></div></td>
                         </tr>
                         <tr>
                             <td><?=__('SMTP auth method')?>:</td>

+ 5 - 0
web/templates/admin/edit_web.html

@@ -191,6 +191,11 @@
 					      <label><input type="checkbox" size="20" class="vst-checkbox" name="v_letsencrypt" <?php if($v_letencrypt == 'yes' || $v_letencrypt == 'on') echo "checked=yes" ?> onclick="App.Actions.WEB.toggle_letsencrypt(this)"> <?php print __('Lets Encrypt Support');?></label>
 					  </td>
 				      </tr>
+                                      <tr>
+                                          <td class="vst-text input-label lets-encrypt-note <? if($v_letencrypt  == 'yes' || $v_letencrypt == 'on') echo ' enabled';?>" >
+                                              <?= __('Your certificate will be automatically issued in 5 minutes')?>
+                                          </td>
+                                      </tr>
                                       <tr>
                                             <td class="vst-text input-label">
                                                 <?php print __('SSL Home Directory');?>

+ 7 - 1
web/templates/user/list_web.html

@@ -232,7 +232,13 @@ sort-bandwidth="<?=$data[$key]['U_BANDWIDTH']?>" sort-disk="<?=$data[$key]['U_DI
                     <div class="l-unit__stat-cols clearfix">
                       <div class="l-unit__stat-col l-unit__stat-col--left"><?=__('SSL Support')?>:</div>
                       <div class="l-unit__stat-col l-unit__stat-col--right">
-                        <b><?=__($data[$key]['SSL'])?></b>
+                       <b>
+                            <? if(empty($data[$key]['LETSENCRYPT'])){
+                                echo __($data[$key]['SSL']);
+                            } else {
+                                echo __('Lets Encrypt');
+                            }?>
+                        </b>
                       </div>
                     </div>
                   <? } ?>