Implement validate command

This is a backup file. It shouldn't be part of the commit.