In the case of a CUA, the template would have to calculate "32" in the case of a locking. However, "64" is set for SAPUser.U_Flag.
This is a product defect (35156).
This will be fixed in a future release of the product. If you require this immediately corrected, please contact Support for a hotfix referencing the defect ID 35156.