|
| 1 | +#!/bin/bash |
| 2 | + |
| 3 | +# Hestia Control Panel upgrade script for target version 1.8.8 |
| 4 | + |
| 5 | +####################################################################################### |
| 6 | +####### Place additional commands below. ####### |
| 7 | +####################################################################################### |
| 8 | +####### upgrade_config_set_value only accepts true or false. ####### |
| 9 | +####### ####### |
| 10 | +####### Pass through information to the end user in case of a issue or problem ####### |
| 11 | +####### ####### |
| 12 | +####### Use add_upgrade_message "My message here" to include a message ####### |
| 13 | +####### in the upgrade notification email. Example: ####### |
| 14 | +####### ####### |
| 15 | +####### add_upgrade_message "My message here" ####### |
| 16 | +####### ####### |
| 17 | +####### You can use \n within the string to create new lines. ####### |
| 18 | +####################################################################################### |
| 19 | + |
| 20 | +upgrade_config_set_value 'UPGRADE_UPDATE_WEB_TEMPLATES' 'false' |
| 21 | +upgrade_config_set_value 'UPGRADE_UPDATE_DNS_TEMPLATES' 'false' |
| 22 | +upgrade_config_set_value 'UPGRADE_UPDATE_MAIL_TEMPLATES' 'false' |
| 23 | +upgrade_config_set_value 'UPGRADE_REBUILD_USERS' 'false' |
| 24 | +upgrade_config_set_value 'UPGRADE_UPDATE_FILEMANAGER_CONFIG' 'false' |
| 25 | + |
| 26 | +# Modify existing POLICY_USER directives (POLICY_USER_CHANGE_THEME, POLICY_USER_EDIT_WEB_TEMPLATES |
| 27 | +# and POLICY_USER_VIEW_LOGS) that are using value 'true' instead of the correct value 'yes' |
| 28 | + |
| 29 | +hestia_conf="$HESTIA/conf/hestia.conf" |
| 30 | +hestia_defaults_conf="$HESTIA/conf/defaults/hestia.conf" |
| 31 | + |
| 32 | +if [ -f /etc/nginx/nginx.conf ]; then |
| 33 | + echo "[ * ] Mitigate HTTP/2 Rapid Reset Attack via Nginx CVE CVE-2023-44487" |
| 34 | + sed -i -E 's/(.*keepalive_requests\s{1,})10000;/\11000;/' /etc/nginx/nginx.conf /usr/local/hestia/nginx/conf/nginx.conf |
| 35 | +fi |
0 commit comments