Generic checker based on regular expressions.