A police inspector with responsibility for disposing of seized drugs was found with hundreds of thousands of pounds of cocaine, crack cocaine, heroin, ecstasy and cannabis in his home, a jury has heard.
Keith Boots, 55, who had been a West Yorkshire Police officer for more than 20 years, stole drugs from police stores to supply others, Leeds Crown Court was told.
Prosecutor Paul Greaney QC said: "He was stealing and storing drugs so that they could then be supplied unlawfully to others.
"In other words, the Boots operation did not just involve the theft of drugs that had been removed from the streets by the police, it also involved putting them back on to those same streets and the person principally responsible was Keith Boots, a police inspector."
Mr Greaney said the large store of drugs was found when colleagues raided Boots's home in Norman Lane, Eccleshill, Bradford, smashing down the door in December 2014.
The drugs were in different places, including his washing machine, and ammunition was also found, the court heard.
The prosecutor said: "The drugs found within the property included cocaine, crack cocaine, heroin, ecstasy and cannabis in both its resin and skunk forms.
"The total value of the drugs on the street would have been several hundred thousand pounds.
"What made it exceptional, indeed unique, was that Keith Boots, the owner of the house and the man who had been there when officers arrived, was one of their own, a serving officer with West Yorkshire Police.
"What had happened that night was that officers had found a warehouse of controlled drugs in the home of one of their own inspectors.
"What Keith Boots had been doing is as simple as it is wicked. In a gross breach of trust, he had been exploiting weaknesses in the system for the destruction of controlled drugs in order to steal them."
Mr Greaney said that in December 2014 Boots was stationed at Trafalgar House police station in the centre of Bradford.
He said the raid on Boots's home happened after a colleague noticed a quantity of cocaine missing from the station store.
Mr Greaney said Boots had become "nothing more than a criminal".
Boots went on trial on Wednesday with his son Ashley Boots and a third defendant, Ian Mitchell.
Mr Greaney said Mitchell, who was wanted for recall to prison, "strolled" into a Leeds police station and said it was him who had hidden the drugs found at Norman Lane on behalf of a unnamed dealer.
The prosecutor said Mitchell claimed his "friend" Keith Boots was "blameless".
Mr Greaney told the jury: "But all of this was lies and nonsense and his tale quickly unravelled."
Keith Boots denies four counts of theft, six counts of possession of controlled drugs with intent to supply, one count of possessing ammunition, three counts of conspiracy to supply controlled drugs, one count of conspiracy to steal and one count of conspiracy to pervert the course of justice.
Ashley Boots, 29, of Weatherhouse Terrace, Halifax, denies six counts of possession of controlled drugs with intent to supply, one count of possessing ammunition, three counts of conspiracy to supply controlled drugs, one count of conspiracy to steal and one count of conspiracy to pervert the course of justice.
Ian Mitchell, 27, of no fixed address, denies one count of conspiracy to pervert the course of justice.
The trial continues.