A secret system of vetting civil servants based on intelligence was in operation as recently as 2003 - and almost tumbled into public view, a declassified Government file has revealed.