Plans to allow some court cases to be held in private to protect sensitive intelligence material have been watered down following a Coalition rift over the controversial measures.
Inquests will be now excluded from the proposals, judges and not ministers will have the power to order secret sessions and evidence will only be taken behind closed doors when national security is deemed to be threatened.
The controversial Justice and Security Bill will be published today after senior Tories and Liberal Democrats finally reached agreement at the weekend over its detail.
Civil liberties groups welcomed the retreat, but warned that the measure still opened the door to trials being held in secret, breaching Britain's historic commitment to open justice.
Kenneth Clarke, the Justice Secretary, had originally proposed allowing private hearings in all civil settings, including coroners' courts, if the move was considered in the public interest.
He argued the powers were necessary to ensure other countries were happy to share intelligence without fear of it being exposed in British courts.
The original plans, contained in a Green Paper, provoked a civil liberties storm and were condemned by MPs of all parties for eroding traditional freedoms. Today's Bill will contain a series of concessions designed to placate critics:
* Inquests will be excluded from the proposals following fears that suspicious deaths at the hands of police or the security services could not come to light.
* Only judges will be allowed to order a secret session. The Government had initially planned to give the power to ministers.
* Evidence will only be heard in private in exceptional cases affecting "national security" instead of the "public interest". A Ministry of Justice source conceded the original wording was a "loose term".
Last night a senior Liberal Democrat source claimed Nick Clegg had intervened to amend the proposals because he was so unhappy with their original "wide scope". He said: "Nick has worked incredibly hard within the Coalition to ensure these proposals achieve the right balance between liberty and security. He made clear he would not let security concerns erode the principle of open justice."
However, Shami Chakrabarti, the director of Liberty, said: "The oldest parliamentary trick is to start with a policy so outrageous that any crumb of comfort looks half reasonable.
"The protection of inquests is that crumb, but what if grieving families and other victims want to sue the military, intelligence or political establishment for abuses of power?"
The Bill will also shake up the rules governing the Intelligence and Security Committee of MPs and peers which oversees the intelligence services.
Its members are currently appointed by the Prime Minister and report to him. In future they will be elected by fellow parliamentarians and the committee will report to Parliament as well as Downing Street. It will also gain extra powers to force the intelligence services to hand over classified material.