validation engine implementation