https://bugs.contribs.org/show_bug.cgi?id=10366
Bug ID: 10366
Summary: smeserver-mailsorting geekmode not honoured
Classification: Contribs
Product: SME Contribs
Version: 9.2
Hardware: ---
OS: ---
Status: CONFIRMED
Severity: normal
Priority: P3
Component: smeserver-mailsorting
Assignee: [email protected]
Reporter: [email protected]
QA Contact: [email protected]
Target Milestone: ---
This post refers:
https://forums.contribs.org/index.php/topic,53193.msg275464.html#msg275464
Here's the section where we detect geekmode:
37 if (defined $userName)
38 {
39 my $user = $accountsdb->get($userName);
40 die
41 "Account $userName is not a user account; update mailsorting
failed.\n"
42 unless ($user && $user->prop('type') eq "user" || $userName eq
"admin");
43 @users = ($user);
44 my $geekmode = $user->prop('geekmode') || 'disabled';
45 if($geekmode eq "enabled"){
46 print "User $userName in geek mode, do not update mailfilter
and procmail rules.\n";
47 exit;
48 }
49 }
50 else
That section ONLY gets triggered if $userName is defined when the script is
called say like this
signal-event mailsorting-conf john
If it is called via the panel then $userName is not defined at that point and
in the 'else' section no further check is made.
You can test that by setting geek mode enabled for a user, then
signal-event mailsorting-conf someuser
And then check the logs for
"User someuser in geek mode, do not update mailfilter and procmail rules."
There should be a geekmode check in the 'else' section I think.
I am attaching a modified file to test It's a bit of a quick hack so backup the
original file
cp /etc/e-smith/events/actions/mailsorting-update-user
/root/somewheresafe/mailsorting-update-user
Then dropped the attached file into the actions directory
Make sure it is root:root and 0554
Then try making a custom .procmail file and running
signal-event mailsorting-update (or use the panel and Save)
Let us know what happens
--
You are receiving this mail because:
You are the QA Contact for the bug._______________________________________________
Mail for each SME Contribs bug report
To unsubscribe, e-mail [email protected]
Searchable archive at https://lists.contribs.org/mailman/public/contribteam/