Judge Ian Farlam is expected to make a ruling on the issue next week.
Serious doubts have been raised about the legitimacy of the police's submission to the Marikana commission of inquiry for the testimony of mystery witness Mr X to be held in camera.
Mr X was apparently part of the group of protesting Marikana miners who underwent a ritual that included two sangomas, the burning of live sheep, and the swallowing of their ashes on August 11 2012. He is expected to give evidence of how protesters planned to attack the police.
In March, police submitted an application for Mr X to testify in camera through a remote video link. They said he was under witness protection and his life would be in danger if his identity was revealed or published.
Earlier this week, advocate Dali Mpofu, who represents the injured and arrested miners, said during the course of his duties he would have to expose Mr X's identity to his clients.
He said the police had failed to prove the presence of widows of slain miners and survivors parties would endanger Mr X, or those harbouring ill feelings could otherwise be prevented from establishing his identity outside of the commission.
The South African Police Service (SAPS) wants only commissioners, lawyers and accredited media present in the auditorium when Mr X testifies. The police want the widows, public and miners prevented from attending the hearings when Mr X gives evidence, which Mpofu said was not viable.
SAPS legal counsel Ishmael Semenya argued that the police's submission fell outside of this debate of open justice, access to courts and full and effective cross-examination – as put forward by the legal counsel representing the affected parties.
He needed to ascertain whether he had made a case for Mr X's evidence to be heard in camera before dealing with the issue of the parties being present. Semenya argued that the commissions' Act gave the chair the power to exclude "any class of persons" from the place "when such evidence is to be held".
Socio-Economic Rights Institute's executive director Stuart Wilson said he could not think of a case in post-apartheid South Africa where an advocate had been told not to disclose the identity of a witness to his clients. He said this would be contrary to the principles of open justice. "It is not clear that the commission could lawfully direct this because the clients can't give instructions to their legal representatives unless they know who the witness is.
"As a consequence, cross-examination is severely restricted, the process is in danger of becoming unfair, and a miscarriage of justice becomes that much more likely.
"There are any number of reasons why someone might want to lie to the commission. You don't know if someone has a reason to lie, unless you know who he is. It is unlikely that any value can be placed on his evidence without his identity being revealed to the parties."
Gareth Newham, head of the Institute for Security Studies' crime and justice programme, said Mr X was the only witness, outside of the police, supporting their case.
"So far the police have contradicted each other and have contradicted earlier statements they had made. They have made assumptions they can’t prove, about a plan to attack the police. And the only person supporting the police is also implicating himself in crimes he's committed. He may well be under threat from the police. If he is to be trusted, it is important that his identity be known."
Judge Ian Farlam is expected to make a ruling on the issue next week.