After the arrest of a National Security Agency contractor for allegedly stealing government secrets, the Justice Department's John Carlin told CNBC on Wednesday that the risk posed by contractors is "real."

"I do think it is an important practice point for those of us in government but also in the private sector, that if you are trying to protect yourself, you have to look more broadly than your own company to what those that you hire may have access to," said Carlin, who is assistant attorney general for national security.