Input validation and better 5.6.2 support