Compare commits

...

6 Commits

Author SHA1 Message Date
5ef3a00a05 * Sat Jan 11 2025 Brian Read <brianr@koozali.org> 11.0.0-38.sme
- Fix password reset for admin in user panel [SME: 12655]
2025-01-11 07:04:32 +00:00
174e140a04 * Thu Jan 09 2025 Brian Read <brianr@koozali.org> 11.0.0-37.sme
- Delete userpanelaccess from base (left in incorrectly after saome testing)  [SME: 12839]
2025-01-09 19:06:51 +00:00
d77b9bd341 Update spec file changelog for 12864 2025-01-09 15:53:59 +00:00
746609ced0 Bug:12864 Correct spelling in Lex file for API 2025-01-09 15:14:10 +00:00
9380ac0264 Bug:12868 fix email settings for spamassassin status 2025-01-09 14:49:56 +00:00
a07bdf4aa5 * Tue Dec 31 2024 Jean-Philippe Pialasse <jpp@koozali.org> 11.0.0-35.sme
- fix PATH [SME: 12847]
2024-12-31 03:09:36 -05:00
8 changed files with 85 additions and 101 deletions

View File

@@ -964,7 +964,7 @@ sub change_settings_filtering {
TagLevel
RejectLevel
SortSpam
Subject
Subject
SubjectTag) )
{
$cdb->set_prop('spamassassin', $param, $c->param("Spam$param"));

View File

@@ -1,38 +0,0 @@
package SrvMngr::Controller::Userpanelaccess;
#----------------------------------------------------------------------
# heading : User management
# description : User Panel Access
# navigation : 2000 150
# menu :
#----------------------------------------------------------------------
# name : userpanelaccess, method : get, url : /userpanelaccess, ctlact : Userpanelaccess#main
#
# routes : end
#----------------------------------------------------------------------
use strict;
use warnings;
use Mojo::Base 'Mojolicious::Controller';
use Locale::gettext;
use SrvMngr::I18N;
use SrvMngr qw(theme_list init_session);
#use SrvMngr::Model::Main;
sub main {
my $c = shift;
$c->app->log->info($c->log_req);
my $title = $c->l('User panel access');
$c->stash( title => $title, modul => 'https://mailserver.bjsystems.co.uk/server-manager/cgi-bin/userpanelaccess', height => 600 );
$c->render(template => 'embedded');
}
1;

View File

@@ -1,5 +1,6 @@
#
# Generated by SM2Gen version: SM2Gen version:0.8 Chameleon version:4.5.4 On Python:3.12.3 at 2024-12-01 15:22:43
# edited by bjr 09Jan2025
#
'lets_Manage_letsencrypt-config_settings:' => 'Manage letsencrypt-config settings',
'lets_HOOKSCRIPT_STATUS' => 'Hookscript Status',
@@ -9,14 +10,14 @@
'lets_Internal_IP' => 'Internal IP',
'lets_Save' => 'Save',
'lets_Issuer' => 'Issuer',
'lets_IS_IN_CERT' => 'Is In cart',
'lets_IS_IN_CERT' => 'Is in certificate',
'lets_For_this_Server' => 'For this Server',
'lets_Loop_through_checking_the_letsencrypt' => 'Loop through checking the letsencrypt status for each configured domain',
'lets_Loop_through_checking_the_letsencrypt' => 'Loop through checking the letsencrypt status for each configured domain which is enabled',
'lets_Check_just_one_domain' => 'Check just one domain',
'lets_PARAMS_panel_action_was_successful' => 'PARAMS panel action was successful',
'lets_PARAMS_panel_action_was_successful' => 'Parameter panel action was successful',
'lets_Check_all_domains' => 'Check all domains',
'lets_LIST_panel_action_was_successful' => 'LIST panel action was successful',
'lets_LIST_panel_action_was_successful' => 'List panel action was successful',
'lets_Status_Report' => 'Status Report',
'lets_LABEL_NAMESERVERS' => 'Label timeservers',
'lets_Loop_through_and_check_the' => 'Loop through and check the letsencrypt status for a specific domain',
@@ -24,12 +25,12 @@
'lets_Error_Status_Report' => 'Error Status Report',
'lets_Not_Before' => 'Not Before',
'lets_Content' => 'Content',
'lets_CONFIG_LETSENCRYPT' => 'confirm Letsencrypt',
'lets_API_STATUS' => 'ape Status',
'lets_CONFIG_LETSENCRYPT' => 'Configure Letsencrypt',
'lets_API_STATUS' => 'API Status',
'lets_ACCEPT_TERMS_STATUS' => 'Accept Terms Status',
'lets_Check_all_enabled_domains' => 'Check all enabled domains',
'lets_All_domains_check_result' => 'All domains check result',
'lets_CHECKALLDOMAINS_panel_action_was_successful' => 'CHECKALLDOMAINS panel action was successful',
'lets_CHECKALLDOMAINS_panel_action_was_successful' => 'Check all domains panel action was successful',
'lets_Domains_name' => 'Domains name',
'lets_HOSTOVERRIDE_STATUS' => 'Hostoverride Status',
'lets_List_of_Domains_and_Hosts' => 'List of Domains and Hosts',
@@ -37,7 +38,7 @@
'lets_KEYSIZE_STATUS' => 'Keysize Status',
'lets_Domain_name_/_HOSTNAME' => 'Domain name / HOSTNAME',
'lets_Enabled_domains_check_result' => 'Enabled domains check result',
'lets_CHECKALLENABLEDDOMAINS_panel_action_was_successful' => 'CHECKALLENABLEDDOMAINS panel action was successful',
'lets_CHECKALLENABLEDDOMAINS_panel_action_was_successful' => 'Check all enabled domains panel action was successful',
'lets_Internet_IP' => 'Internet IP',
'lets_Expiry' => 'Expiry',
'lets_CHECK_ALL_DOMAINS' => 'Check All Domains',
@@ -47,8 +48,8 @@
'lets_Current_certificate_details' => 'Current certificate details',
'lets_LABEL_LECERT' => 'Label secret',
'lets_One_domain_check_result' => 'One domain check result',
'lets_CHECKONEDOMAIN_panel_action_was_successful' => 'CHECKONEDOMAIN panel action was successful',
'lets_CONFIGUREMODE_STATUS' => 'Configuremode Status',
'lets_CHECKONEDOMAIN_panel_action_was_successful' => 'Check one domain panel action was successful',
'lets_CONFIGUREMODE_STATUS' => 'Configure mode Status',
'lets_CHECK_ALL_ENABLED_DOMAINS' => 'Check All Enabled Domains',
'lets_External_Interface_IP' => 'External Interface IP',
'lets_APPLY' => 'Apply',
'lets_APPLY' => 'Apply',

View File

@@ -9,7 +9,7 @@ use esmith::util;
BEGIN
{
$0 =~ /^(.+)$/ms; $0 = $1; # Untaint script name
$ENV{'PATH'} = '/bin:/usr/bin:/usr/local/bin';
$ENV{'PATH'} = '/usr/sbin:/usr/bin:/usr/local/bin';
$ENV{'SHELL'} = '/bin/bash';
$ENV{'HOME'} = '/usr/share/smanager';
delete $ENV{'ENV'};

View File

@@ -34,8 +34,8 @@
<p><span class=label>
%=l 'mai_LABEL_SPAM_SCAN'
</span><span class=input>
% param 'SpamStatus' => $mai_datas->{spamstatus} unless param 'SpamStatus';
%= select_field 'SpamStatus' => [[(l 'DISABLED') => 'disabled'], [ (l 'ENABLED') => 'enabled']], class => 'input'
% param 'Spamstatus' => $mai_datas->{spamstatus} unless param 'Spamstatus';
%= select_field 'Spamstatus' => [[(l 'DISABLED') => 'disabled'], [ (l 'ENABLED') => 'enabled']], class => 'input'
</span></p>
<p><span class=label>
@@ -98,4 +98,4 @@
% end
</div>
%end
%end

View File

@@ -86,22 +86,24 @@
</span><span class=data2>
%= $mai_datas->{fetchmailmethod}
</span></p>
% my $smtp_mesg;
% my $smtp_mesg=l('SMTP port %u allow client to authenticate:');
% $smtp_mesg=l('SMTP port %u allow client to authenticate:');
<p><span class=label>
%= sprintf($smtp_mesg,$c->get_db_prop('qpsmtpd','TCPPort',25));
</span><span class=data2>
%= $c->get_current_smtp_auth( TRUE )
</span></p>
% my $smtp_mesg=l('SMTPS SSL/TLS auth: port %u status:');
% $smtp_mesg=l('SMTPS SSL/TLS auth: port %u status:');
<p><span class=label>
%= sprintf($smtp_mesg,$c->get_db_prop('sqpsmtpd','TCPPort',465));
</span><span class=data2>
%= $c->get_current_smtp_ssl_auth( TRUE, 's', FALSE )
</span></p>
%my $smtp_mesg=l 'Submission port %u status:';
% $smtp_mesg=l 'Submission port %u status:';
<p><span class=label>
%= sprintf($smtp_mesg,$c->get_db_prop('uqpsmtpd','TCPPort',587));
</span><span class=data2>
@@ -109,7 +111,7 @@
</span></p>
<br />
% my $btn = l('mai_DESC_STATE_RECEPTION_BUTTON');
% my $btn = l('mai_DESC_STATE_RECEPTION_BUTTON');
<div class='center'>
%= submit_button "$btn", class => 'action'
</div>

View File

@@ -66,58 +66,65 @@
%my $password_text = l("PASSWORD_RESET");
%if ($useraccounts_user_name eq 'admin') {
%$actionModify = qq{
% <a href="useraccountsd?CsrfDef=$csrf_token&trt=UPS&user=$useraccounts_user_name">
% <button type='button' class='sme-modify-button' title='$modify_text'>
% $modify_text
% </button>
% </a>
%<a href="useraccountsd?CsrfDef=$csrf_token&trt=UPS&user=$useraccounts_user_name">
% <button type='button' class='sme-modify-button' title='$modify_text'>
% $modify_text
% </button>
%</a>
%};
%$actionResetPw = qq{
%<a href="useraccountsd?CsrfDef=$csrf_token&trt=PWS&user=$useraccounts_user_name">
% <button type='button' class='sme-password-button' title='$password_text' >
% $password_text
% </button>
%</a>
%};
%} else {
%$actionModify = qq{
% <a href="useraccountsd?CsrfDef=$csrf_token&trt=UPD&user=$useraccounts_user_name">
% <button type='button' class='sme-modify-button' title='$modify_text' >
% $modify_text
% </button>
% </a>
%<a href="useraccountsd?CsrfDef=$csrf_token&trt=UPD&user=$useraccounts_user_name">
% <button type='button' class='sme-modify-button' title='$modify_text' >
% $modify_text
% </button>
%</a>
%};
%}
%if ($password_set ne 'yes') {
%$actionLock = l('ACCOUNT_LOCKED');
%$actionResetPw = qq{
% <a href="useraccountsd?CsrfDef=$csrf_token&trt=PWD&user=$useraccounts_user_name">
% <button type='button' class='sme-password-button unset' title="$password_text - currently unset" style = background:pink; >
% $password_text
% </button>
% </a>
%<a href="useraccountsd?CsrfDef=$csrf_token&trt=PWD&user=$useraccounts_user_name">
% <button type='button' class='sme-password-button unset' title="$password_text - currently unset" style = background:pink; >
% $password_text
% </button>
%</a>
%};
%} else {
%} elsif ($useraccounts_user_name ne 'admin') {
%my $lock_text = l('ACCOUNT LOCKED'); # Localized text
%my $csrf_token = "TOKEN"; # CSRF token for security
%my $useraccounts_user_name = $user->key; # useraccountss_entry name extracted from the data structure
%$actionLock = qq{
% <a href="useraccountsd?CsrfDef=$csrf_token&trt=LCK&user=$useraccounts_user_name">
% <button type='button' class='sme-lock-button' title='$lock_text' >
% $lock_text
% </button>
% </a>
%};
%<a href="useraccountsd?CsrfDef=$csrf_token&trt=LCK&user=$useraccounts_user_name">
% <button type='button' class='sme-lock-button' title='$lock_text' >
% $lock_text
% </button>
%</a>
%};
%$actionResetPw = qq{
% <a href="useraccountsd?CsrfDef=$csrf_token&trt=PWD&user=$useraccounts_user_name">
%<a href="useraccountsd?CsrfDef=$csrf_token&trt=PWD&user=$useraccounts_user_name">
% <button type='button' class='sme-password-button' title='$password_text' >
% $password_text
% </button>
% </a>
%</a>
%};
%}
%if ( $removable eq 'yes' ) {
%my $remove_text = l('REMOVE'); # Localized text
%my $csrf_token = "TOKEN"; # CSRF token for security
%$actionRemove = qq{
% <a href="useraccountsd?CsrfDef=$csrf_token&trt=DEL&user=$useraccounts_user_name">
% <button type='button' class='sme-remove-button' title='$remove_text' >
% $remove_text
% </button>
% </a>
%<a href="useraccountsd?CsrfDef=$csrf_token&trt=DEL&user=$useraccounts_user_name">
% <button type='button' class='sme-remove-button' title='$remove_text' >
% $remove_text
% </button>
%</a>
%};
%}
@@ -127,20 +134,19 @@
%my $csrf_token = "TOKEN"; # CSRF token for security
%my $useraccounts_user_name = $user->key; # useraccountss_entry name extracted from the data structure
%$actionroundcube = qq{
% <a href="roundcubepanel?CsrfDef=$csrf_token&url=https://$thisdomain/roundcube?_user=$useraccounts_user_name">
% <button type='button' class='sme-email-button' title='$roundcube_text' >
% $roundcube_text
% </button>
% </a>
%<a href="roundcubepanel?CsrfDef=$csrf_token&url=https://$thisdomain/roundcube?_user=$useraccounts_user_name">
% <button type='button' class='sme-email-button' title='$roundcube_text' >
% $roundcube_text
% </button>
%</a>
%};
<td class='sme-border' style="min-width:35em">
<%= $c->render_to_string(inline => $actionModify) %>
<%= $c->render_to_string(inline => $actionResetPw) %>
<%= $c->render_to_string(inline => $actionLock) %>
<%= $c->render_to_string(inline => $actionRemove) %>
<%= $c->render_to_string(inline => $actionroundcube) %>
</td>
<td class='sme-border' style="min-width:35em">
<%= $c->render_to_string(inline => $actionModify) %>
<%= $c->render_to_string(inline => $actionResetPw) %>
<%= $c->render_to_string(inline => $actionLock) %>
<%= $c->render_to_string(inline => $actionRemove) %>
<%= $c->render_to_string(inline => $actionroundcube) %>
</td>
</tr>
% }
</tbody>
@@ -150,4 +156,4 @@
%= hidden_field 'trt' => $usr_datas->{trt}
</div>
</div>

View File

@@ -2,7 +2,7 @@ Summary: Sme server navigation module : manager 2
%define name smeserver-manager
Name: %{name}
%define version 11.0.0
%define release 34
%define release 38
Version: %{version}
Release: %{release}%{?dist}
License: GPL
@@ -115,6 +115,19 @@ true
%defattr(-,root,root)
%changelog
* Sat Jan 11 2025 Brian Read <brianr@koozali.org> 11.0.0-38.sme
- Fix password reset for admin in user panel [SME: 12655]
* Thu Jan 09 2025 Brian Read <brianr@koozali.org> 11.0.0-37.sme
- Delete userpanelaccess from base (left in incorrectly after some testing) [SME: 12839]
* Thu Jan 09 2025 Brian Read <brianr@koozali.org> 11.0.0-36.sme
- Fix spamassassin status not coming through from email filter panel to email settings panel [SME: 12868]
- Correct spelling of API in letsencrypt panel [SME: 12864]
* Tue Dec 31 2024 Jean-Philippe Pialasse <jpp@koozali.org> 11.0.0-35.sme
- fix PATH [SME: 12847]
* Tue Dec 31 2024 Jean-Philippe Pialasse <jpp@koozali.org> 11.0.0-34.sme
- fix css warning xxcolor [SME: 12844]
- update CSP style rules [SME: 12840]