As if America's highly-publicised "war on drugs" were not already facing a credibility gap, two US superior court judges – one in Washington, DC, another in Colorado – are raising questions about whether the federal Drug Enforcement Agency (DEA) and police departments are using "pseudo-scientific" drug identification methods to bust hundreds of thousands of suspected drug users, many of them inner-city minority kids. A flawed drug test means that innocent people are being locked up as suspects, deprived of their due process rights, and then pressured to accept plea bargains, whether they're guilty or not.

At issue in the growing controversy is whether current drug identification methods, including the widely-used "Duquenois-Levine test", can verify – and how accurately – that the substance police seize during an arrest is the one they say it is. The test, a variation on simple techniques first employed in the 1930s, exposes the suspect substance to a liquid chemical, and if it turns a certain colour – purple, in the case of marijuana – it's deemed likely to be the real thing.

But according to leading defence experts, including Heather Harris, a highly-trained chemist who's gone head-to-head with DEA lab "experts" and won, there are hundreds of legal substances, many of them readily available commercially, or in nature, that would normally turn purple under the exact same test conditions. Which means the Duquenois test, while ruling marijuana "in" as one theoretical possibility, perhaps, can't confirm its presence, either – at least, not "beyond a reasonable doubt", the legal threshold required for a conviction.

But that hasn't stopped police from using the test widely. In one recent case in Florida, police descended on a middle-aged woman bird-watcher in a public park and busted her after noticing a leafy substance in a package in her purse, which later turned out to be sage she'd purchased as incense for her home. The woman tried to inform the police about sage's medicinal and spiritual uses, and even Googled the manufacturer's website on her laptop, which matched the branding on the package. But the police busted her anyway, after the substance turned purple in a lab test. She's now planning to sue for damages.

In fact, the problem of "false positives" in drug tests isn't just limited to substances that appear to resemble marijuana. In Canada, the owners of a family-based chocolatier business were fingered as dangerous drug dealers by a Duquenois field test, and found themselves in jail.

The chocolate case may seem extreme but it's happening all across America, experts say. That's, in part, because of the pay incentives involved. Police can earn large amounts of overtime pay by conducting routine drug busts, especially after hours; they even have a name for the practice: "collars for dollars". In New York, where possession of less than an ounce of marijuana was decriminalised some years ago, marijuana drug busts have not declined; they've skyrocketed – from 5,000 to roughly 30,000 annually – in part, because police find the practice so lucrative.

Of course, Duquenois-Levine is not the only DEA-approved drug test available. A far more conclusive test, known as GC/MS, using far more advanced techniques, can also be performed, but defendants and even many lawyers are rarely aware that they can insist on such a test, or have much incentive to do so.

And, in fact, even the GC/MS test is increasingly under fire, because the DEA doesn't have standard lab protocols to govern its use, and has angered judges, including those in Washington and Colorado, by overstating the test's reliability in court. In one recent case, a Colorado superior court judge threw out all of the DEA's testimony in a drug case after its witness, under cross-examination, failed to demonstrate that the GC/MS testing conducted at one of its 18 national labs was reliable. It's a legal precedent that has the DEA reeling, experts say.

Of course, many people arrested for drug use and possession are undoubtedly guilty as charged – how many is unclear, though, because plea bargaining is so commonplace. But using manifestly flawed drug identification tests to charge defendants, or pressure them to plead guilty, is hard to square with a defendant's right to due process. And the DEA and local police, by relying on such methods, are in danger of damaging even their "good" cases, making a further mockery of the "war on drugs", while leaving ordinary citizens more at risk than ever.