Add validation feature to 'input' and 'rawlist'