It has emerged that the Department of Health solicited sensitive information about children with autism and their families who were previously involved in legal actions against the State.
This medical and educational information was used to build and maintain dossiers on the children without the knowledge and consent of their parents.
Between 1996 and 2016, over 120 cases were taken against the State seeking the provision of education for autistic children. These cases were settled at a cost of €11.2m and in more than 40 cases, services were provided once the court case was initiated.
The Department would later seek service updates from doctors, psychiatrists and social workers on 48 of the children with special needs and their families who were taking cases.
Shane Corr, a senior civil servant at the Department of Health, went public with details of the secret dossiers after he made a protected disclosure last year and was told a review had "not raised matters of concern".
Speaking to RTÉ Investigates, Mr Corr said that after seeing the sensitive information and knowing that the parents and children did not know it was being stored, he could not walk away with a clear conscience until "those parents and those children knew what I knew".
A template letter which indicated a particular approach to litigating Special Educational Needs (SENS) cases was what first raised concerns for Mr Corr.
In the letter, Mr Corr said the department contacted a doctor explaining they were in litigation with a patient and asked for information about them.
The doctor responded asking whether the patient and their parents were aware of the request and had given their consent for the information to be shared.
"The reply was 'no, we haven't informed the patient, we haven't informed the parents and we're not going to. We don't ask for consent. This is standard practice when we're running a litigation case, we ring HSE units around the country and we ask for information, any information that might be helpful to the case'," said Mr Corr.
The following day, the department was furnished with a lengthy clinical evaluation from the doctor. It detailed the patient's struggles, the impact it was having on their siblings and the parents' fears for the future.
This family's underlying legal action had been dormant for 10 years at this stage.
Data Protection Expert, Darragh O'Brien said by not informing families of the information gathering, there appeared to be a breach of domestic and EU law as well as their fundamental rights.
"That therapeutic process is grounded on the principle of trust and confidentiality. That's the reason why the transparency principle exists and it has existed under EU law and in data protection laws since the 1980s," said Mr O'Brien.
"In this context, it doesn't smell very fair, it doesn't seem clearly lawful and it most certainly isn't transparent."
The information in the dossiers was shared and gathered with the goal of aiding the Department of Health with a background legal strategy, such as in determining when it would be a good time to approach parents to settle or withdraw cases.
Mr Corr said "every type" of information on the children, their siblings and their parents were found in the dossiers.
"Everything that you wouldn't want to know about the family living beside you...it was there.
"It was drawn from speaking to doctors. It was transcribed and put into Excel sheets and shared with the Department of Education and Science, and the HSE."
According to Mr Corr, the files could be accessed, searched and viewed by anybody working within the Department's Social Care division, which deals with the likes of older people, social care and disability policies.
Of the files that Mr Corr discovered, there was one he said stood out - a video from the HSE of a child in an extremely distressed state.
He said that once he discovered the files, he couldn't let it lie especially given that the people affected were vulnerable.
"Some of them in desperate situations. Some of them in situations they couldn't handle and they had put their faith in the State and they had brought their children to see psychologists, psychiatrists, and other doctors and that faith was not rewarded.
"It was used against them."
In 2017, when the doctor raised the question about whether consent had been given by families for the sharing of their confidential medical information, an internal memo indicated there was concern among senior civil servants that the practice might have to stop.
According to RTÉ Investigates, the memo from a senior civil servant said: "were it to be determined that there are legal obstacles to requesting such information from the HSE in those circumstances, it would probably drive significant change...
"We might have to stop liaising in the background with HSE officials and providing the State's legal team and (other Departments) with information that might be useful in developing the State's defence/legal strategy."
In a statement issued on Thursday evening, the Department of Health said it commissioned an independent review into the matters raised in the documentary. It said no breach of the Data Protection Acts was identified.
The department said, "The Department of Health would like to reassure all parents, families and interested parties that the Department has never unlawfully held sensitive medical and educational information of children involved in dormant court cases.
"The Department’s mission is to improve the health and wellbeing of people in Ireland and to protect the most vulnerable in society. The Department is very conscious of the impact that these headlines will have on affected families and will engage with stakeholders on these matters in the coming days to address any concerns."
The department claimed it is "normal practice" to gather and maintain information to obtain legal advice.
"The subject matter of this specific RTÉ investigation was brought to the Department's attention last year. The Department moved quickly to investigate these matters and commissioned an independent, expert review by an external Senior Counsel. This review was completed in November 2020.
"No breach of the Data Protection Acts was identified by the review. The review found that information contained on relevant files managed by the Department is consistent with, and typical of, the sort of information which arises in such litigation.
"The examination also found no basis to suggest wrongdoing arising from the information contained."
Mr Corr has not been given access to the independent review's full findings. He said to get access he would be required to sign a confidentiality agreement that says if he disclosed any aspect of it or the records he accessed he will be guilty of misconduct.
He also said he was warned about his conduct after criticising the disclosures process.
Following the revelations from Mr Corr, Roger Murray, Partner at Callan Tansey Solicitors, who acted on behalf of a number of the families said the children - now adults - affected deserved better then and deserve better now.
"The children involved in many of these cases are now adults. Their parents had to battle with the State for years to try to level the playing field," said Mr Murray.
"To learn that information about their families was being passed in this fashion must be like hearing that one side was trying to make the slope even steeper, and will surely reopen old wounds."