The Court of Appeal has rejected a bid to give young people caught up in legal proceedings, including victims and witnesses, lifelong anonymity.
Three judges unanimously dismissed claims that they were legally entitled to keep their identities secret once they turned 18.
Section 39 of the Children and Young Persons Act 1933 gives under 18s in criminal proceedings in adult courts anonymity and protection from the glare of potentially harmful publicity.
Yesterday two teenagers referred to as JC and RT who appeared at the Old Bailey at the age of 17, asked the appeal court to rule that the law also allowed anonymity to be extended beyond 18.
Lord Justice Moore-Bick, vice-president of the civil appeal court, and two other judges, rejected the claim. In particular they dismissed the assertion that such a move was necessary in the interests of the rehabilitation of offenders.
The judge declared: "I am satisfied the purpose of section 39 is not to promote rehabilitation of young offenders but to protect children and young persons who are caught up in legal proceedings from the adverse effects of publicity to which they might otherwise be exposed.
"An order made under section 39 is effective only during the minority of the person in respect of whom it is made and expires automatically on his or her 18th birthday".
The judges said JC and RT could keep their anonymity while their legal teams considered whether to appeal against the appeal court's ruling to the Supreme Court.
At their trials both pleaded guilty to possession of explosives.
The Crown accepted that they did not intend to endanger life or cause serious damage to property and they were given community sentences.
A third teenager, since named as Michael Piggin, admitted similar charges but was accused of more serious offences, including under the Terrorism Act 2000.