It didn't take long before one of the incentives offered to coax the Taliban to the negotiating table came to light: last week the Guardian carried reports of American plans to release several high-ranking Taliban leaders from Guantánamo Bay. They include Mullah Khair Khowa, a former interior minister, Noorullah Noori, a former governor in northern Afghanistan and maybe, just maybe, the former army commander Mullah Fazl Akhund – if a third country, perhaps Qatar, will accept custody of him.

It's an inevitable step in the right direction, reminiscent of the tentative early moves in the Northern Ireland peace process. It also offers a convenient, if partial, solution to the status of the 171 legal headaches still languishing in America's brutal Caribbean prison.

But it forces into light other shaming questions about the conduct of the so-called war on terror; and in particular about those thousands of men, women and children, many innocent of any crime even by the US authorities' own admission, who were "rendered" and remain trapped in prisons across the world.

Hamidullah Khan was just 13 when he disappeared from South Waziristan, in Pakistan. I met his father, Wakeel Khan, on a recent trip to Islamabad. He told me with pride that Hamidullah was a "very good-looking boy" and showed me pictures. He said his son could be quite absent-minded, but worked very hard at school: his dream was to become a doctor.

During the summer holidays in 2008, Wakeel sent Hamidullah to the family home in South Waziristan to collect some of their possessions, as Wakeel could not get the time off work to go himself. Hamidullah never returned.

Wakeel, an ex-solider, tried to retrace his son's steps. He caught the bus up to the province, and asked everyone about his son: his relatives, his old army contacts, the local Taliban. No one knew anything. He thought of going to the police, but given that they charge a 300 rupee bribe to replace an ID card, he asked himself, "how much would they charge to find a person?"

After a year, the Red Cross finally tracked down Hamidullah and passed a letter to his family saying he was being held in Bagram prison in Afghanistan. Despite American assurances that the prisoners there are treated well, fresh allegations of abuse surfaced this weekend.

No explanation has ever been offered for why a boy so young was picked up and taken hundreds of miles away, why he has never been charged, and why he has still not been released.

When Hamidullah went missing, Wakeel's wife started fasting. She kept it up for three years, until her son's letters finally persuaded her to cut down to one day a week. In that time, she developed diabetes and has lost most of her eyesight.

Theirs is just one of countless stories. Abdul Haleem Saifullah was 18 when he disappeared from the streets of Karachi, after dropping his father off at the hospital for kidney treatment. He said he'd run some errands, and would "be right back". As time passed, his family grew increasingly concerned, but were put off going to the authorities for fear of causing trouble. Once again, it only emerged a year later that he was being held in Bagram.

Saifullah's uncle insisted to me there was "no way" his nephew would have been mixed up with "bad people": he came from a poor family in Karachi, and had to work from dawn till dusk. His mother continues to ask when he is coming back, every day.

There is clear evidence that both the US and Pakistani authorities have repeatedly obfuscated – or, to put a finer point on it, lied – about Saifullah's detention. Pakistan's ministry of foreign affairs claims it only found out he was being held in Bagram in October 2010 and that, according to the Americans, he was picked up in the Zabul province of Afghanistan in May 2009. Yet his family have letters from him from Bagram dating from September 2005.

This is a pattern of confusion, or deliberate deception, repeated in countless cases of missing persons who were later tracked down to Bagram. What is clear, however, is the law on these matters.

Britain's court of appeal recently gave the British government a deadline of 18 January to secure the release of another Bagram detainee, Yunus Rahmatallah, who was captured by British forces in Iraq in 2005. If he is not released by 18 January, the UK, which took him into custody as a prisoner of war before handing him over to the Americans, will be in breach of the Geneva conventions.

Whether the US will take any notice of the ruling remains to be seen. But it is at least one step forward. Another hurdle will be persuading the authorities in Pakistan and many other countries across the world to take back the citizens they betrayed, then abandoned. The human rights charity Reprieve is petitioning on behalf of a number of these prisoners in the courts.

But, as things stand, on the 10th anniversary of the opening of Guantánamo, there remain thousands of cases like those of Hamidullah, Saifullah and Yunus that have yet to be heard. The latest estimate puts the prisoner population of Bagram at 3,000; roughly 18 times the size of Guantánamo Bay.

So while the nascent peace negotiations with the Taliban garner headlines, and result in high-profile Guantánamo releases, young men like Hamidullah, continue to wait. "I still want to be a doctor," he tells his father in his letters. "It breaks my heart that God has taken that one wish away from me."

• This article was amended on 9 January 2012. The year 2004 was changed to 2008 in the standfirst and in the fourth paragraph, which now reads: "During the summer holidays in 2008, Wakeel sent Hamidullah to the family home in South Waziristan to collect some of their possessions, as Wakeel could not get the time off work to go himself. Hamidullah never returned."

• Follow Comment is free on Twitter @commentisfree