A man appointed by David Cameron to serve as his adviser inside Downing Street was today charged with possessing indecent images of children.

Patrick Rock, 63, was charged having been arrested at his home in February by the National Crime Agency.

He was a senior aide to the prime minister and had worked on policy for restricting internet pornography to protect children and previously worked with Cameron as an adviser to former Conservative home secretary Michael Howard.

The decision to charge Rock was taken by the Crown Prosecution Service. Rock has resigned his post as a Whitehall adviser.

In a statement the NCA said the charges were that Rock allegedly made "an indecent photograph of a child contrary to section 1(a) of the Protection of Children Act 1978, between 31 July 2013 and 31 August 2013", and possession of indecent images.

Judith Reed, a senior lawyer with the CPS Organised Crime Division, said: "The decision to prosecute has been taken in accordance with the Code for Crown Prosecutors. We have determined that there is sufficient evidence for a realistic prospect of conviction and that a prosecution is in the public interest.

"May I remind all concerned that Mr Rock has a right to a fair trial. It is extremely important that there should be no reporting, commentary or sharing of information online which could in any way prejudice these proceedings."

ameron declined comment when questioned about the news at the EU summit in Brussels. The prime minister said: "It would be purely a matter for the courts and it wouldn't be appropriate to comment."

Earlier this week, a judge criticised Cameron for comments he made about the conviction of his former top aide, Andy Coulson, for conspiracy to hack phones.

The PM's comments came as the Old Bailey jury were still considering another charge against Coulson, a former editor of the News of the World before he was appointed as Cameron's director of communications.