BATTICALOA (Sri Lanka) - Three years ago, Vairamuttu Bavani left her home in eastern Sri Lanka to attend her cousin's wedding in the north.

She didn't make it back until September.

Trapped by the civil war, Bavani, a Tamil, lost six members of her family and both her legs to a bomb. She spent months detained in an overcrowded refugee camp. And even now, she remains under tight scrutiny by local authorities, who have visited her almost every day since her return from the northern Vanni region, she said.

"They ask me where I went in the Vanni and what I was doing there," said Bavani, 25, who spends her days seated on the floor of her sister's house, fighting boredom.

Bavani is one of tens of thousands of refugees who are struggling to rebuild their lives in post-war Sri Lanka, often under tight control from the government. During the final months of the war, nearly 300,000 mostly Tamil civilians were trapped between rebels and advancing government troops, and these refugees are now in various stages of limbo.

The quarter-century war cost 80,000 to 100,000 their lives, as the Tamil Tiger rebels fought for a separate state for Sri Lanka's Tamil minority. After the rebels finally lost in May, the government herded the remaining civilians, along with some straggling rebel fighters, to overcrowded camps.

Rights groups and Western governments decried conditions in the camps, saying they amounted to an illegal form of collective punishment. Faced with mounting international pressure and advancing monsoon rains that would have wreaked havoc at the low-lying camps, the government this week finally unlocked the camps, saying most of the remaining 127,000 refugees are free to go home once they register with authorities. The government has vowed to close the camps by the end of January.

Even those who have returned from the camps say they have been told not to travel without police permission, and security officers visit their homes to question them regularly. Many wait, painfully, for news of loved ones who vanished or were taken by the military for questioning.

Rights groups worry that the government's surveillance of refugees and its failure to provide them with better livelihoods will exacerbate the ethnic tensions that fueled the conflict.

"It's alienating the 300,000 displaced and their relatives," said Meenakshi Ganguly, a senior researcher at Human Rights Watch. "They're all going to feel like they're living in a state where they are not trusted and don't belong. That's a highly dangerous situation."

Sri Lanka's Hindu Tamil community, which comprises 18 percent of the country's 20 million people, has complained of decades of discrimination at the hands of the Buddhist Sinhalese majority. Sri Lanka's president, Mahinda Rajapaksa, promised to address the lingering tensions after the war ended. Now he says he will address them after elections, scheduled for Jan. 26.

Military spokesman Brig. Udaya Nanayakkara says refugees are not under surveillance, and that police only bring returnees in for questioning if there is reason for suspicion.

"If they have been harassed, they should have informed the authorities there," he said.

Rishard Badurdeen, Sri Lanka's resettlement minister, said refugees do get support from the government and charities.

Refugees being resettled in the north, swathes of which were flattened during the final battles, get tin sheets from India to help rebuild their homes, 25,000 rupees ($219) in cash from UNHCR and six months of dry rations from the World Food Program, said Badurdeen. Farmers get additional agriculture grants, he said.

Those sent home to the east are eligible for food rations.

Many of the refugees have already been through hell and bear deep hatred for the Tamil Tigers. They say rebels shot civilians who tried to flee the war zone and stole their children to replenish the ranks of dying fighters. UNICEF has accused the rebels of forcibly conscripting more than 6,000 children.

"Raising children in that area was like raising cattle and sending them to slaughter," said Sugadas Rajvathani, 34, who returned to her sister's house in Trincomalee, a port town in northeastern Sri Lanka, on Oct. 30.

She and her three children had spent months in flight. There was no food. One man sold his motorized three-wheeled rickshaw for two coconuts, she said.

When rebels came, she hid her children in ditches, placing a metal sheet and a cooking pot on top for camouflage. The children say it was hot and hard to breathe inside.

One night, rebels came to a tent next to theirs and shot dead a man who tried to keep them from taking his son, she said.

The boy, enraged, began to shout: "Let's teach them a lesson!" Rajvathani recalled.

The villagers gathered sticks and hoes to fight. In the commotion, Rajvathani and her family fled across a lagoon to government territory.

There was shelling coming from both sides, she said. The woman in front of her was shot and slipped beneath the water. Her husband lost his leg to a land mine in 1987, and halfway across the lagoon, his prosthesis fell off. She dragged him the rest of the way. It took three hours.

"We had to ignore bodies falling in front of us and walk on," she said. "Everyone had to save themselves."

She is delighted to be home. Surrounded by solid walls and a dozen members of her family, she can't stop grinning, a wide, white-toothed smile.

But no one has any income yet. The family is living off 30,000 rupees ($263) she got from pawning two gold bangles.

Even here in the east, where fighting ended more than two years ago, few find economic opportunities when they return, especially women. In traditional fishing villages, men go to sea, while women care for children. Women without husbands often rely on charity.

Sasikala Sivaraja and her husband left their shack in a small, sandy village outside Batticoala in 2006, traveling north in search of work. She came home on Aug. 6. Her husband didn't. Now she and her two daughters live off food rations and the largesse of her sister.

The army arrested Sivaraja's father in 1990 and he hasn't been seen since, she said. The navy arrested her cousin, who had been conscripted by rebels when she was 17, on April 21.

She doesn't know when or whether she'll see any of them again.

"I'm worried for my husband. My children ask about him all the time," Sivaraja said, her face crumpling with tears.

Like the others, Bavani has few job prospects. Her father wept when he saw her without her legs, she said.

She had planned to attend a sewing class offered by a local church the week after her cousin's wedding. Now she doesn't know what to do.

"The machines are all operated with the legs," she said. "I cannot do it."

Erika Kinetz

I am the Shanghai correspondent for the Associated Press. I write mostly about transnational criminal networks thiving in the shadows of China's rise, with specific attention to the opioid trade, counterfeiting and money laundering.