You could add /scripts/hackcheck and /usr/local/cpanel/scripts/hackcheck to the cPanel exclusion file:
Code:
echo "/scripts/hackcheck" >> /etc/cpanelsync.exclude
echo "/usr/local/cpanel/scripts/hackcheck" >> /etc/cpanelsync.exclude
After I added that script to the exclusion file, then I ran "/scripts/upcp --force", the hackcheck script revision I made was no longer overwritten on a forced cPanel update (prior to adding to the exclude file, it was being overwritten on forced cPanel updates). Additionally, since upcp was calling hackcheck during the run which prompted that user to be changed, it was no longer detecting any issue with the user I had created with uid 0.
Here is the line change I made to /scripts/hackcheck to bypass the uid 0 user I had created:
Code:
if ( $uid == 0 && $user ne "root" && $user ne "toor" && $user ne "cpuser0" ) {
Prior to that change and adding hackcheck to the exclude file, cpuser0 was prompting the following when I ran "/scripts/upcp --force"
Code:
[20110503.111647] [29794] Locking password for user cpuser0.
[20110503.111647] [29794] passwd: Success
[20110503.111647] [29794] uid 0 account (cpuser0) - BAD!
[20110503.111647] [29794] [hackcheck] cpuser0 has a uid 0 account
[20110503.111648] [29794] Notification => myemail@gmail.com via EMAIL [level => 1]
Of note, the reason why I've also excluded the /usr/local/cpanel/scripts/hackcheck file rather than only /scripts/hackcheck is that, in 11.29/11.30, the /scripts directory will be moved to /usr/local/cpanel/scripts location and /scripts symlinked to that location. If both are not excluded, then "/scripts/upcp --force" will not honor excluding only /scripts and will still replace hackcheck at /usr/local/cpanel/scripts location.