For four years, American forces in Afghanistan have been throwing technology at the deadliest military challenge of this generation.

As the Taliban buried more and more improvised explosive devices (IEDS), which kill more U.S. troops than any other weapon, the military built multi-million dollar trucks that deflect the impact of an explosion. The Taliban built bigger, more effective bombs. The military built sophisticated equipment to jam cell phones that triggered the bombs. The Taliban started using detonation cords or pressure plates instead of wireless signals.

Now, the U.S. has decided to go to the source of the problem, and that has led the U.S. out of Afghanistan -- to Pakistan.

"We're not going to solve the IED problem inside Afghanistan," says a senior U.S. military official who spoke on condition of anonymity. "If we don't go after the supply, we're playing defense."

The supplier is not a bombmaker, but one of the largest companies in Pakistan. Pakarab is the nation's major producer of the fertilizer calcium ammonium nitrate -- the raw ingredient for as many as 75 percent of the IEDs in Afghanistan, according to a U.S. military official. The fertilizer is completely legal in Pakistan, where a quarter of the GDP, and half of the workforce, depends on agriculture. But CAN, as the fertilizer is commonly known, is illegal in Afghanistan, and enough of it is crossing the porous border between the two countries to help create some 16,000 bombs this year, a 200 percent increase since 2008.

"We are capturing hundreds of thousands of pounds of CAN, much of it in original bags, with detonation cord, with plastic caps, with time fuses from Pakistan," says a senior U.S. military intelligence official. "You get a complete system, including CAN, to make hundreds if not thousands of IEDs… There's no doubt it's all coming from Pakistan."

But this is not just another blame-Pakistan story. In interviews with a dozen U.S. military, diplomatic, and political officials who work on stopping IEDs, not a single one blamed the flow of CAN into Afghanistan on Pakistan's military or its powerful intelligence service, though both are often accused of sheltering the insurgents who attack U.S. troops in Afghanistan.

In fact, the U.S. military officials praised Pakarab for cooperating. The officials acknowledged the use of legal fertilizer to make illegal bombs was a new concept for the Pakistanis, but said Pakistan's government must help, and they portrayed IEDs as a problem that the U.S. and Pakistan could confront together, and perhaps use to improve the strained relationship between the two countries.

The officials had agreed to speak only on the condition of anonymity because of the delicacy of the U.S.-Pakistan relationship, tested most recently when NATO helicopters killed 24 Pakistani soldiers in November.

IEDs are one of the few areas where the two countries' interests truly align: Pakistani military officials say IEDs have killed more than 1,000 Pakistani soldiers, and 2,000 Pakistanis total, since August 2010.

"The main weapon of the terrorists in [the tribal areas] is IEDs," said a senior Pakistani military official.

The U.S. also acknowledges that only about 1 percent of Pakarab's CAN is falling into the wrong hands. The U.S. has no intention of shutting down the company, which made more than $100 million in profit last year, but U.S. officials are desperate to find out how the fertilizer goes from legally produced to illegally smuggled, and in so doing find a way to stem the huge increase of IEDs in Afghanistan.

In late December, President Obama signed into a law a bill that requires the Pentagon to certify that Pakistan is trying to reduce the flow of IED materials before it can send hundreds of millions of dollars in aid to Pakistan.

"A commitment has been made to us and to others in our government that they were going to implement their counter-IED strategy," Sen. Bob Casey, D-Pennsylvania, told ABC News in a phone interview. Sen. Casey recently visited Pakistan to speak to the government and military about IEDs. "That just hasn't happened, at least not to the extent that we wanted."