commit 555cc197a4870b03316dff30b9b27bae8cf76ccc from: mischa date: Sun Sep 04 20:32:35 2022 UTC remove last in favor of define commit - 6fba688215ac7a3c407c4d47fb856056625e982b commit + 555cc197a4870b03316dff30b9b27bae8cf76ccc blob - c30f2e5bf70d48db4ca99d41632bcc2b788a5d28 blob + 5ecfee5f9364d5583f8e55703b2f93747d4207bd --- conf.php-sample +++ conf.php-sample @@ -1,6 +1,5 @@ blob - 81d07ee7facc18e0693e3944f70a8dd615502dde (mode 644) blob + /dev/null --- config.inc.php.sample +++ /dev/null @@ -1,127 +0,0 @@ - -// Copyright (c) 2022 High5! -// License Info: LICENSE.TXT -// -// File: config.inc.php -// -if (preg_match("/config.inc.php/", $_SERVER['SCRIPT_NAME'])) { - header("Location: login.php"); - exit; -} - -// Debug mode -// Enables PHP error output -$CONF['debug'] = 'false'; - -// Language config -// Language files are located in './languages'. -$CONF['default_language'] = 'en'; - -// Database Config -// mysqli = MySQL 4.1 -// pgsql = PostgreSQL -$CONF['database_type'] = 'mysqli'; -$CONF['database_host'] = 'localhost'; -$CONF['database_user'] = 'opensmtpdadmin'; -$CONF['database_password'] = 'RandomStringOfChars'; -$CONF['database_name'] = 'opensmtpd'; -$CONF['database_prefix'] = ''; - -// Site Admin -// Define the Site Admins email address below. -// This will be used to send emails from to create mailboxes. -$CONF['admin_email'] = 'postmaster@change-this-to-your.domain.tld'; - -// Encrypt -$CONF['encrypt'] = 'bcrypt'; - -// Generate Password -// Generate a random password for a mailbox and display it. -// If you want to automagically generate paswords set this to 'YES'. -$CONF['generate_password'] = 'NO'; - -// Page Size -// Set the number of entries that you would like to see -// in one page. -$CONF['page_size'] = '25'; - -// Default Aliases -// The default aliases that need to be created for all domains. -$CONF['default_aliases'] = array ( - 'abuse' => 'abuse@change-this-to-your.domain.tld', - 'hostmaster' => 'hostmaster@change-this-to-your.domain.tld', - 'postmaster' => 'postmaster@change-this-to-your.domain.tld', - 'webmaster' => 'webmaster@change-this-to-your.domain.tld' -); - -// Mailboxes -// If you want to store the mailboxes per domain set this to 'YES'. -// Example: /usr/local/virtual/domain.tld/username@domain.tld -$CONF['domain_path'] = 'NO'; -// If you don't want to have the domain in your mailbox set this to 'NO'. -// Example: /usr/local/virtual/domain.tld/username -$CONF['domain_in_mailbox'] = 'YES'; - -// Default Domain Values -// Specify your default values below. Quota in MB. -$CONF['aliases'] = '10'; -$CONF['mailboxes'] = '10'; -$CONF['maxquota'] = '0'; - -// Quota -// When you want to enforce quota for your mailbox users set this to 'YES'. -$CONF['quota'] = 'NO'; -// You can either use '1024000' or '1048576' -$CONF['quota_multiplier'] = '1024000'; - -// Transport -// If you want to define additional transport options for a domain set this to 'YES'. -// Read the transport file of the OpenSMTPD documentation. -$CONF['transport'] = 'NO'; - -// Virtual Vacation -// If you want to use virtual vacation for you mailbox users set this to 'YES'. -$CONF['vacation'] = 'NO'; - -// Alias Control -// OpenSMTPD Admin inserts an alias in the alias table for every mailbox it creates. -// The reason for this is that when you want catch-all and normal mailboxes -// to work you need to have the mailbox replicated in the alias table. -// If you want to take control of these aliases as well set this to 'YES'. -$CONF['alias_control'] = 'NO'; - -// Special Alias Control -// Set to 'NO' if you don't want your domain admins to change the default aliases. -$CONF['special_alias_control'] = 'YES'; - -// Logging -// If you don't want logging set this to 'NO'; -$CONF['logging'] = 'YES'; - -// Header -$CONF['show_header_text'] = 'NO'; -$CONF['header_text'] = ':: OpenSMTPD Admin ::'; - -// Footer -// Below information will be on all pages. -// If you don't want the footer information to appear set this to 'NO'. -$CONF['show_footer_text'] = 'YES'; -$CONF['footer_text'] = 'Return to change-this-to-your.domain.tld!'; -$CONF['footer_link'] = 'http://change-this-to-your.domain.tld/'; - -// Welcome Message -// This message is send to every newly created mailbox. -// Change the text between EOM. -$CONF['welcome_text'] = << blob - bdbefe497215224e0afa51213c8bc39f289ba6c3 blob + 3cb8829f4b5dd6330856ba7789651d462eebc043 --- functions.inc.php +++ functions.inc.php @@ -15,7 +15,7 @@ if(preg_match("/functions.inc.php/", $_SERVER['SCRIPT_ DEFINE("VERSION", "version 1.0.0"); DEFINE('ROOT_PATH', dirname(__FILE__) . '/'); require_once ROOT_PATH . 'conf.php'; -require_once ROOT_PATH . 'config.inc.php'; +#require_once ROOT_PATH . 'config.inc.php'; // // Check of debug is enabled or not blob - f2b6b763acd8ff27408619732061774039f73f58 blob + b4b7bcdbb2dc678bef078dd0b9969f9700812c4c --- languages/en.lang +++ languages/en.lang @@ -139,6 +139,7 @@ $LANG['Sendmail_to_text_error'] = ' OpenSMTPD Admin " . $CONF['footer_text'] . "\n"; + echo "" . FOOTER_TEXT . "\n"; } ?> blob - 8d09479d14b69af0fa1be1738f164695e15a1fb9 blob + fbd66492481ac086bde873ff90882d409908f2e2 --- templates/header.tpl +++ templates/header.tpl @@ -27,8 +27,8 @@ if (file_exists(realpath("../stylesheet.css"))) { echo "\n"; echo "\n"; } -if (($CONF['show_header_text'] == "YES") and ($CONF['header_text'])) { - echo "

" . $CONF['header_text'] . "

\n"; +if (SHOW_HEADER == "YES" && HEADER_TEXT) { + echo "

" . HEADER_TEXT . "

\n"; } ?> blob - a2d6ecea9013237b4d43438eecf30f8c4f859656 blob + bcacbd117d32fea90868f3381b2957061a3ce885 --- templates/list-virtual.tpl +++ templates/list-virtual.tpl @@ -13,8 +13,6 @@ if ($list_domains[$domain_key]['aliases'] == 0) $list_ if ($list_domains[$domain_key]['aliases'] < 0) $list_domains[$domain_key]['aliases'] = $LANG['Overview_disabled']; if ($list_domains[$domain_key]['mailboxes'] == 0) $list_domains[$domain_key]['mailboxes'] = $LANG['Overview_unlimited']; if ($list_domains[$domain_key]['mailboxes'] < 0) $list_domains[$domain_key]['mailboxes'] = $LANG['Overview_disabled']; -if ($list_domains[$domain_key]['maxquota'] == 0) $list_domains[$domain_key]['maxquota'] = $LANG['Overview_unlimited']; -if ($list_domains[$domain_key]['maxquota'] < 0) $list_domains[$domain_key]['maxquota'] = $LANG['Overview_disabled']; ?> blob - 5921514c836191d6c74de33655a07a01df468130 blob + fb5f0322fb844107bc5aeff83acc56ed192ce8e5 --- templates/sendmail.tpl +++ templates/sendmail.tpl @@ -22,7 +22,7 @@ - +   blob - f72f9a9b02e8736150ea6d5496d00a1a675a393b blob + 94f1907404338800183e200e858fdd1109a25c4e --- templates/users_main.tpl +++ templates/users_main.tpl @@ -4,7 +4,7 @@   - + blob - c2c604694c6a6d80465b0754a42cc7cfcc3e40f6 blob + d71d7813c82e1bcd6bebec775df0a097a6392dc1 --- templates/users_menu.tpl +++ templates/users_menu.tpl @@ -1,6 +1,6 @@