Fixes #8414 - extracts validators from models

Also cleans up some unused validators looking for trailing whitespace
that is stripped by the StripWhitespaces concern.
Tried to make some sense from unmatching regexps and validation error
messages. Some validations might need a different regexp to check for what
they are actually supposed to validate - but atleast now messages fit
the actual validation.
hostgroups can have whitespace