and a reseller should also be excluded if the Prevent resellers from unsuspending checkbox was selected when the account was suspended.
This was indeed the case.
Locking the suspension just creates an additional /var/cpanel/suspended/user.lock file for the suspended account. And that was present. The reseller was still able to log into the reseller account - with what best I could tell was their reseller overwrite.
Additionally, what appears to happen. When an account (entire cPanel account) is suspended the shadow files for the email accounts on all the domains for that account are changed:
localpart:*LOCKED*hash:number::::::*LOCKED*
The addition of *LOCKED* in the password hash section effectively disables the user from being able to check or authenticate that email account.
When the root/reseller overwrite is used and the individual changes the password, the shadow file gets changed to:
localpart:newhash:number::::::*LOCKED*
So the password hash section gets rewritten with a new hash. The term *LOCKED* still exists at the end of the line, indicating that it was locked at one time.
This to me just spells that this is an unintended consequence of allowing root/reseller overwrite to be used to log into suspended accounts.
I don't really know what the solution is
I'm kind of of the thinking that if an account is suspended - regardless if the reseller/root unsuspension lock file is present or not - nobody should be able to log into the cPanel of the account. I'm not sure what the point of being able to log into a suspended account would be. But I am also open to hearing what everyone else thinks.
I thought about creating a hook to immute the shadow file. But then I would have to create another hook to remove the immute flag before unsuspension and account deletions. And that seems like a hassle.
Keep in mind, I suspect that this also carries over to database user passwords. Those users are also locked in the database server on suspension, but I'm guessing a root/reseller overwrite login will be able to change these as well - although to what end, that's not immediately clear to me - it's not like the email thing.
The reseller could also log in, and remove offending files after suspension resulting in "What malicious files?"
There's really just cause for concern that anybody is even being allowed to log into a suspended account. But like I said, I'm willing to hear what others have to say.