The director of a charity that offers advice on terrorism laws has failed in his bid to challenge his own conviction under the Terrorism Act.

Muhammad Rabbani, 37, of Bethnal Green, refused to give his mobile phone pin and laptop password to police at Heathrow Airport after being stopped and searched on his way home from a wedding in Doha in November 2016.

He was originally convicted at Westminster Magistrates’ Court last September for wilfully obstructing the search and was handed 12 month’s conditional discharge.

He subsequently challenged the ruling but his case was dismissed today by High Court judges Lord Justice Irwin and Mr Justice Foskett.

The Senior District Judge Emma Arbuthnot, who made the original ruling, “made no error in law”, it was found.

Rabbani works for Cage, which describes itself as an “independent advocacy organisation working to empower communities impacted by the War on Terror”.

When giving evidence at the magistrates’ court, Rabbani said he was carrying a large volume of documents relating to a Qatari client who was allegedly tortured in the US.

She accepted he had been “trying to protect confidential material on his devices” but said he took a “calculated risk” and “thought that as on earlier occasions the police would not take any further action”.

Lord Justice Irwin said: “Although the chief magistrate accepted that the appellant had acted as he did so as to protect the information of others, he did not say so at the time.

“On the contrary, at the time he told the examining officers that he was seeking to protect his own privacy.”

He “at no stage” mentioned the confidentiality of others or material relevant to journalism, he added, and did not bring it up until “the obstruction was complete”.

He added: “The officers never had any sight of this material to verify the assertion. Nor did the Chief Magistrate. She simply accepted the appellant’s evidence on the point, bearing in mind his good character.

“The appellant at the relevant time was not merely silent about excluded or special procedure material. He made the positive assertion that he was refusing access to protect his own privacy.”