validate index