CSV parser and validation