In late 2012, 60 people died in two cities in Pakistan after drinking cough syrup to get high. Tests in Pakistan revealed that the medicines seemed to contain the correct amount of active ingredient, but further tests revealed something that was not supposed to be there. Levomethorphan, a chemical five times stronger than morphine, was the contaminant that had caused the deaths.

In September 2013, 44 children in Paraguay were admitted to hospital with breathing difficulties. It turned out the children had all been given a locally made cough medicine, and investigators later found that this came from the same batch that had caused the deaths in Pakistan.

Doctors in Paraguay were able to administer an antidote and save the children. A World Health Organization alert went out listing the batches from the Indian factory that might be contaminated. By then the ingredient had been transported to multiple countries in Europe, north Africa, the Middle East and Latin America. It had already been made into cough medicines in Colombia and Peru, but these were recalled before they could reach patients. The batch that went to the Middle East could not be traced.

In this case, a blatantly poor-quality medicine was detected because its effects were conspicuous. A more discreet kind of substandard medicine -- say, an antibiotic without enough active ingredient -- probably stands a strong chance of reaching patients across the world without getting discovered.

This is a story of how the manufacture and distribution of medicines today is such a complex, globalised affair that it is often hard to track where fake or substandard medicines come from and where they go. This is a story of how these medicines could make you ill or even kill you, even if you don't take them.

Substandards and fakes

The term "poor-quality medicines" is something of a catch-all. It includes "substandards", medicines that have had inadequate quality control or that have degraded from improper storage or the passage of time. And it includes falsified medicines -- fakes -- that claim to be what they are not. These may not be made by the manufacturer whose name is on the package, and they may not contain the stated ingredients in the stated quantities.

Poor-quality medicines might not work. Like those peddled by Peter Gillespie, who was jailed for introducing 72,000 packets of falsified medicines into the UK's distribution system from 2006 to 2007. 25,000 packets reached pharmacies and were given to patients. These knock-off tablets were used to treat heart disease, pancreatic cancer and mental illnesses, and had none or only part of the active ingredient they were supposed to contain. This meant that those people's illnesses were left to take their course.

Poor-quality medicines can kill you if you take them. As happened with Thomas Rybinski, a 56-year-old autoworker from Tennessee, USA, who got an injection for his back pain in 2012. He fell ill and died because the medicine had contaminants that caused fungal meningitis. The batch of medicine, originating in a New England pharmacy with close to no quality control, ended up causing severe infections in nearly 800 people across the USA, killing 64 of them.

Poor-quality medicines can kill you even if you don't take them. Antimicrobial drugs (including antibiotics and antivirals) that have too little active ingredient are generally accepted to help disease-causing bugs evolve so that they develop resistance to treatment even with good-quality antimicrobials. And then these bugs spread.

With some drugs, like statins or arthritis drugs, the effects of poor quality are confined to those taking them. But with antimicrobials, inappropriate use reduces their effectiveness for everyone else.

The factors that speed up the development of antimicrobial resistance -- high rates of infections, the overuse and misuse of antimicrobials, poor sanitation, poor-quality medicines -- are more common in low- and middle-income countries, which means that so is resistance. But microbes know no boundaries, and they travel easily across the world, in foodstuffs being exported and in the bodies of humans. And often, resistant microbes can transfer genetic material to each other to become even more dangerous to humans.

The result: infections that were simple to cure, gonorrhoea for example, are back with a vengeance. Conditions like tuberculosis and HIV are getting harder to treat. In the future, routine surgery or cancer treatment could become risky. There is a real danger of returning to a time where any one of us, anywhere in the world, could pick up such an infection and find that medicine is powerless to save us from dying.

A global network

At a south Indian restaurant in Delhi, I meet Suresh Sati. He is a large middle-aged man, often larger-than-life in his enthusiasm, who has spent a considerable part of his working life as a private investigator exposing manufacturers of falsified medicines.

Within 15 minutes of sitting down, he has produced so many samples of fake medicines that our tumblers of coffee risk being crowded off the table. He collected them over years of investigations, from raids or from informants in fake medicine distribution networks.

India is one of the largest exporters of generic medicines in the world. Forty per cent of over-the-counter and prescription generics sold in the USA come from India. In the UK, a quarter of all generics come from India, and generics account for 80 per cent of National Health Service prescriptions.

Yet India's pharmaceutical sector is indifferently regulated, and Indian pharmaceutical companies have been pulled up by foreign trading partners for exporting substandard or contaminated medicines.

Sati points at one of the boxes in front of him, a ten-strip cardboard container of Zifi 200 -- a trade name for the antibiotic cefixime, used for throat infections, urinary tract infections and gonorrhoea. "Now the monsoons are beginning, and people are going to start falling ill. This sells the most. Every doctor is going to prescribe Zifi 200," he says. That makes it a popular target for the fakers.

I ask if I can take a photograph of the packaging. He hands me two of the Zifi 200 strips and tells me to keep them. "There'll be more coming my way," he says. The strips even include verification codes to be sent by SMS to check if the medicine is real. I make a note to buy a strip from a pharmacy to compare with the fakes.

Sati tells me how he once purchased a batch of 100,000 common painkillers from a fakes manufacturer in Sonepat. After his medicine was ready, Sati burnt the lot and had the manufacturer raided; he was told he would be shot if he was ever seen again in that town.

An important step while getting fakes made, Sati says, is a question that the manufacturer asks: "Which do you want? Full-salt, half-salt or chalk-mitti?" That is, fakes with the stated amount of active ingredient, with only some of the active ingredient, or just chalk dust. Each has a different price.

According to Sati, the practice of adding a fraction of active ingredient to fakes began to be seen in India around 15 years ago, as drug controllers and consumers began to realise that there were fake medicines in the system. Manufacturers of fakes saw it as a way to protect themselves, as the medicines might have some effect and draw less attention. And if they were caught, it allowed them to claim that it was a case of production error rather than outright fakery.

While this might work well for the manufacturers, it is bad for the patients -- who receive sub-therapuetic doses, too low to properly treat their illnesses -- and terrible from the perspective of antimicrobial resistance.

"Sub-therapeutic dosing, by definition, contributes to antimicrobial resistance," says Elizabeth Pisani, an epidemiologist and a visiting senior research fellow at the Policy Institute, King's College London. "Bugs are mutating all the time," she explains. Some of these mutations make the bugs slightly more resistant to drug treatment, but the mutants are usually at a disadvantage among non-mutants because it takes them more energy to reproduce.

Our antimicrobials work most effectively against the non-mutant versions, but a full therapeutic dose further ensures that slightly resistant versions are eliminated too. However, if you have only a fraction of the active ingredient, it's going to knock out the susceptible ones first and there might not be enough left over to knock out the slightly resistant ones. "That creates elbow room for the slightly resistant ones to reproduce because the competition has been wiped out," says Pisani "And that's how a mutant version becomes a dominant strain."

Pisani suspects that poor-quality medicines are a significant contributor to antimicrobial resistance. But while laboratory studies, modelling and common sense all point to the link between poor-quality medicine and resistance, it would be hard to study directly in humans. As Pisani puts it, "The way we would normally test those things is in a large human trial, and we can't actually give people crap medicines, right?"

Ensuring medicine quality is a global challenge. A pill might be manufactured from ingredients sourced from multiple countries, shipped via several ports, packaged and repackaged in various countries and ultimately sold via an internet pharmacy. The number of points at which fakes or substandards could enter the chain is staggering, so international coordination is essential.

A good starting point is the WHO database of substandard and falsified medical products, which helped identify the batch of cough syrup administered to children in Paraguay. But a crucial tool is regulation, the responsibility for which could be shared better. Pisani explains, "Right now, it's an entirely globalised industry that we're trying to regulate locally."

In Delhi, Suresh Sati is sceptical of the Indian government's attempts to regulate poor-quality medicines at a local level. In 2009, the health minister introduced a scheme to reward whistle-blowers who alerted regulators about quality problems. "Not a single person has come forward," Sati says. He also believes the laws and their enforcement are lax and no one really pays the price for making fake drugs.

"The margin from selling fake medicines is more than from selling heroin. With heroin you're scared of the police, but here you're not." And so those who run fake medicine operations continue to do so with relative impunity. One of them even warned Sati that if he persisted with his investigations he would be dissolved in a boiler, a threat that few are in a better position to make convincingly than the kingpin of a fake medicine racket.

Putting drugs to the test

In 2010, Indians consumed the most antibiotics per person in the world. Medicines, including antimicrobials, are easily available over the counter despite rules that forbid this. A study published in 2018 found that a large number of antibiotics were on sale without being approved either in India or in the country of the manufacturer.

To preserve the effectiveness of antimicrobials, regulators need to prevent their overuse and misuse just as they need to prevent the use of poor-quality fakes.

The fake tablets that Sati gave me, Zifi 200, should contain cefixime as their active ingredient. Cefixime is classified as a third-generation cephalosporin, which is on the WHO's list of critically important antimicrobials, and within it is categorised as "Highest Priority". Cefixime is also on a list of drugs in India called Schedule H1, a classification introduced by the government in 2014 to regulate access to drugs, specifically as a counter to the spread of antimicrobial resistance. A Schedule H1 drug can only be sold against a prescription, and the pharmacist is required to maintain a record of the sale, the prescribing doctor and contact information for the patient.

Get CNN Health's weekly newsletter Sign up here to get The Results Are In with Dr. Sanjay Gupta every Tuesday from the CNN Health team.

Some medicines, including Zifi 200, use an SMS verification service to combat fakes. Text the code and you soon get a reply to say if your medicine is genuine or not.

I sent off a text message with the code on one of the strips Sati gave me. As expected, it failed. Later, I went down to a pharmacy to see if I could buy a strip of Zifi 200. The pharmacist, with dismaying cheerfulness, handed me a strip without asking for a prescription or recording the sale. This one passed verification. There I was with two identical strips of tablets -- one that was fake and should never have been made, and one that lacked a prescription and should never have been sold.