• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Forwarded to devs [12.5.30] Event handler bug: mail account manipulation fails if username contains apostrophe

burnley

Regular Pleskian
TITLE:
[12.5.30] Event handler bug: mail account manipulation fails if username contains apostrophe
PRODUCT, VERSION, OPERATING SYSTEM, ARCHITECTURE:
Plesk 12.5.30 Update #69, CentOS Linux 7.3.1611
PROBLEM DESCRIPTION:
Tested on 12.5.30 Update #69 on CentOS 7 with "mail account created" and "mail account deleted". We've just found that we can't use the Plesk event handler if the email username contains an apostrophe, e.g. o'[email protected]. When I create such an account in Plesk the handler registered in Plesk isn't executed. If the username is [email protected] there's no issue.
I know in the past Plesk couldn't manage email usernames containing apostrophe in the local part, but it's been fixed for quite some time. We need to be able to use the event handler for such usernames.
STEPS TO REPRODUCE:
Create the following script:
# cat /usr/local/bin/eventcheck.sh
#!/bin/bash
echo "Customer account has been created. Name: ${NEW_MAILNAME}" >> /tmp/event_handler.log

Then use it for "mail account created" with the following command:
/usr/local/bin/eventcheck.sh ${NEW_MAILNAME}

Now add mail account o'[email protected] in Plesk.​
ACTUAL RESULT:
The handler isn't being executed​
EXPECTED RESULT:
The handler should be executed​
ANY ADDITIONAL INFORMATION:
YOUR EXPECTATIONS FROM PLESK SERVICE TEAM:
Help with sorting out
 
Last edited:
Ohh... Please rewrite your request with detailed info for each required point. I can forward it to developers with just links.
Thanks.
 
As temporary workaround you can try to use quotes in command:

/usr/local/bin/eventcheck.sh "${NEW_MAILNAME}"

This will not completely fix the issue (apostrophes won't be shown in log) but at least event handler will be operational.

Issue reproduced on 17.8.6. Bug confirmed.
 
Back
Top