magento2 – Customer Name Length Validation Not Working

We’ve recently had some issue with spammers using the registration page to send spam emails. We’ve enabled the magento captcha but are still seeing the spam emails being sent.

I’ve seen others online prevent the spam emails by decreasing the length limit for the customer firstname and lastname fields which prevent the spammers from including a link. The method I’ve seen to do this online is to update the customer_eav_attribute table changing the validate_rules column for attribute_ids 5 and 7. This however does not seem to be working for me.

The value I have for these attributes are:


But I am still able to create accounts with names longer than 25 characters.

Is there something else I need to do to cause the validation to happen? Or is there a different way to limit the character length for these fields?

Any help would be greatly appreciated as spam emails are still being sent from our store.