THE AFTERMATH of the Indian Airlines hijacking presents something of a puzzle. The governments of both Afghanistan and Pakistan have condemned terrorism and publicly refused asylum to the hijackers. Yet the hijackers are thought to have escaped from Afghanistan, the scene of their piracy, and into Pakistan.

Afghanistan's ruling Taliban militia tried to use the hijacking to appear responsible, and so to soften the consensus behind U.N. sanctions imposed on their regime. To that end, they warned the hijackers that the execution of hostages would trigger an assault on the aircraft. But once the hostages were safely released, the Afghans could have done more to prevent the hijackers from escaping. They allowed them to drive off, with one Afghan official accompanying them as a hostage. That hostage has now returned, but seemingly without information about the hijackers' identity or whereabouts.

The Pakistanis, for their part, rightly refused to receive the hijackers at their consulate in Afghanistan. They protest that the terrorists may not be in Pakistan, and add that they will be arrested if they are. But Indian and Afghan officials say the hijackers have crossed into Pakistan near the city of Quetta, about two hours' drive from Kandahar. Although this is a sparsely guarded border, Pakistan had ample time to prepare for the hijackers' arrival. There is no evidence of a serious effort to capture them.

Afghanistan and Pakistan are trying to have it both ways on terrorism. They play host to terrorist groups, yet wax indignant when terrorists hijack an aircraft--or, as in the case of Osama bin Laden, resident of Afghanistan, blow up U.S. embassies. This limp ambivalence will encourage more hijackings and bombings. Both governments need to catch and deport offenders if they want their anti-terrorist rhetoric to be taken seriously.

Meanwhile, India's government must resist the temptation to exploit its neighbors' misbehavior. In the wake of the hijacking, India is denouncing Pakistan as a terrorist state and lobbing shells across the border; the Pakistanis claim five civilians were killed on Monday. The hijacking has already brought the terrorizing of more than 150 hostages, the murder of one, and the release of three of the hijackers' extremist comrades. It must not be allowed to trigger another war on the subcontinent.