Indian Border Security Force (BSF) soldiers patrol over a footbridge built over a stream near the Line of Control (LoC), a ceasefire line dividing Kashmir between India and Pakistan, at Sabjiyan sector of Poonch district, August 8, 2013.Mukesh Gupta

BARAMULLA/NEW DELHI (Reuters) - Pakistan-based militants are preparing to take on India across the subcontinent once Western troops leave Afghanistan next year, several sources say, raising the risk of a dramatic spike in tensions between nuclear-armed rivals India and Pakistan.

Intelligence sources in India believe that a botched suicide bombing of an Indian consulate in Afghanistan, which was followed within days last week by a lethal cross-border ambush on Indian soldiers in disputed Kashmir, suggest that the new campaign by Islamic militants may already be underway.

Members of the Lashkar-e-Taiba (LeT) militant outfit in Pakistan, the group blamed for the 2008 commando-style raid on Mumbai that killed 166 people, told Reuters they were preparing to take the fight to India once again, this time across the region.

And a U.S. counter-terrorism official, referring to the attack in Afghanistan, said "LeT has long pursued Indian targets, so it would be natural for the group to plot against them in its own backyard".

Given the quiet backing - or at least blind eye - that many militant groups enjoy from Pakistan's shadowy intelligence services, tensions from a new militant campaign are bound to spill over. Adding to the volatility, the two nations' armies are trading mortar and gunfire across the heavily militarised frontier that divides Kashmir, and accusing each other of killing troops.

India and Pakistan have fought three wars since independence in 1947 and came close to a fourth in 1999. The tension now brewing may not escalate into open hostilities, but it could thwart efforts to forge a lasting peace and open trade between two countries that make up a quarter of the world's population.

"With the Americans leaving Afghanistan, the restraint on the Pakistani security/jihadi establishment is going too," said a former top official at India's Research and Analysis Wing (RAW), the external intelligence arm.

"We are concerned about 2014 in either scenario. If the jihadis (Islamist militants) claim success in Afghanistan, they could turn their attention to us. Equally, if they fail, they will attack in wrath."

But Pakistan, which has a border with India to the east and with Afghanistan to the west, has concerns of its own. It sees India's expansive diplomacy in Afghanistan as a ploy to disrupt it from the rear as it battles its own deadly Islamist militancy and separatist forces. Vying for influence in a post-2014 Afghanistan, it worries about India's assistance to the Afghan army, heightening a sense of encirclement.

"I'm shocked by these allegations. Pakistan has its own insurgency to deal with. It has no appetite for confrontations abroad," said a Pakistani foreign ministry official referring to the Indian charges of stirring trouble in Afghanistan and on the Kashmir border.

"If anything, we are looking at our mistakes from the past very critically. These accusations are baseless. India needs to act with more maturity and avoid this sort of propaganda."

Both U.S. Vice-President Joe Biden and Secretary of State John Kerry spoke during visits to India recently of the need for New Delhi and Islamabad to resume their stalled peace process as the region heads into a period of uncertainty.

FULL-SCALE JIHAD

At the core of that uncertainty is the pullback of militants from Afghanistan as U.S. forces head home.

Hafiz Sayeed, founder of the LeT, has left no doubt that India's side of Kashmir will become a target, telling an Indian weekly recently: "Full-scale armed Jihad (holy war) will begin soon in Kashmir after American forces withdraw from Afghanistan."

The retreat of Soviet forces from Afghanistan in 1989 brought a wave of guerrillas into Kashmir to fight India's rule there.

This time the additional risk will be the rivalry between India and Pakistan over Afghanistan itself, one that threatens to become as toxic as the 60-year dispute in Kashmir. The LeT has said it is fighting Indian forces in Afghanistan as well.

A senior LeT source in Pakistan told Reuters: "It is correct that the LeT cooperates with the Afghan Taliban (insurgents) when there is a question of attacking Indian interests."

Tensions between India and Pakistan escalated last week after five Indian soldiers were killed close to the de facto border in Kashmir. India says Pakistani special forces joined militants to ambush a night patrol, a charge Pakistan denies.

Just days earlier, three men drove an explosives-laden car towards India's consulate in the Afghan city of Jalalabad, near the border with Pakistan. The blast missed its target and killed nine civilians, six of them young Islamic scholars in a mosque.

It is too early to say conclusively who was behind these and other attacks, but Indian and Afghan officials see in them the handiwork of the LeT and its allies. Such groups have doubled their attempts to cross into Indian-controlled Kashmir this year, according to Indian defence ministry statistics.

The result has been the first increase in Kashmir militant violence since a 2003 ceasefire on the border, which led to a decline in attacks, partly because Pakistan and the jihadi groups were preoccupied with Afghanistan during this time.

In the first eight months of this year, 103 casualties in militant-related violence were recorded in Indian Kashmir, compared to 57 in the same period of 2012, according to the South Asia Terrorism Portal, a think tank.

$10 MILLION BOUNTY

LeT was founded in 1990 in eastern Afghanistan by Sayeed, a Pakistani Islamic scholar whom India accuses of masterminding the rampage in Mumbai. The United States placed a $10 million bounty on his head for his alleged role in the attack, but he remains a free man in Pakistan, where he preached to thousands last week.

Although the group has global ambitions, LeT's primary aim is to end India's rule in Muslim-majority Kashmir. India and Pakistan each control a part of the heavily militarised land of lakes and orchards once known as "paradise on earth" and both assert claims over the whole Himalayan territory.

LeT has been working this year with several other Islamist outfits to train and push more Pakistani militants over the heavily guarded border into India's side, a veteran LeT fighter told Reuters in Pakistan.

"Jihad is being stimulated and various militant outfits are cooperating with each other under the platform of the United Jihad Council," said the veteran, referring to an umbrella body.

Pakistan's new prime minister, Nawaz Sharif, came to power in May vowing to improve ties with India and - until last week's flare-up along the Kashmir border - the two sides looked set to resume talks. Their prime ministers were planning to meet on the sidelines of the U.N. General Assembly in New York next month.

The trouble is, says a retired senior Pakistani diplomat, there are "spoilers" on both sides who are not interested in seeing a rapprochement. In Pakistan, these include the militant groups, which he said operate independently.

"They don't seem to be able to control other non-government actors like the LeT. So that's the biggest worry," he said.

The Pakistan military's refusal to dismantle groups such as LeT infuriates New Delhi and fuels hawkish demands for the kind of tough action that would risk escalation.

The senior LeT source in Pakistan denied the group was involved in the failed consulate strike in Afghanistan, but officials in New Delhi - citing intelligence intercepts - said they had been forewarned about LeT-trained hit squads plotting the attack.

"Jalalabad was a message from the ISI in a long line of such messages," said an Indian intelligence official, referring to Pakistan's spy agency, the Inter Services Intelligence (ISI).

TIGHT SECURITY

Further east, on the line dividing Kashmir between Pakistan and India, ceasefire violations are up 80 percent compared to last year, according to India. On Friday night, the two armies exchanged 7,000 rounds of mortar and gunfire, according to Indian media.

Anti-Indian sentiment in Kashmir provides fertile ground for groups seeking to revive the militancy that roiled the region through the 1990s, but New Delhi has two things in its favour.

First, despite the uptick, violence in the state is still close to the record low it reached last year. Second, the Indian army has to a large extent sealed the rugged, fenced and land-mined border that divides Kashmir, leaving militants with a critically small number of cadres and weapons.

"We cannot send jihadists into India in big numbers like in the past because of tight security at the Indian side," the LeT source in Pakistan said.

Speaking on the lawn of his official bungalow in the restive Indian town of Baramulla, J.P. Singh, the police chief for northern border operations, told Reuters the army and police had stopped most attempted militant crossings this year.

Still, India is preparing for an influx.

"(Pakistan's) agents and their proteges, the militants, are getting disengaged from the Afghan border and they have nowhere else to keep them and engage them, other than to push them to Kashmir," Singh said. "Their presence inside Pakistan is dangerous for the internal security of Pakistan."

Additional reporting by John Chalmers in NEW DELHI, Maria Golovnina, Mehreen Zahra-Malik in ISLAMABAD, Abu Arqam Naqash in MUZAFFARABAD, Hamid Shalizi and Jessica Donati in KABUL and Mark Hosenball in WASHINGTON; Editing by John Chalmers and Raju Gopalakrishnan