You'd have to be a really dedicated spy to be willing to have subjected yourself to what would be needed to pass that test.
The British explorer, Richard Burton, had himself circumcised as part of his disguise when he traveled to Mecca.
In 1853 intrepid British explorer Sir Richard Francis Burton disguised himself as an Islamic pilgrim and made the trek into the heart of Arabia visiting the holy cities of Medina and Mecca. If his true identity as a European Christian had been exposed, the penalty for his indiscretion would have been death.
http://www.eyewitnesstohistory.com/mecca.htm
http://en.wikipedia.org/wiki/Richard_Francis_Burton