modified hash check regex