Arlene Foster's DUP special adviser passed a privileged legal letter to the lobbyist son of Peter Robinson, the RHI inquiry has been told.
The letter related to a controversial planning case.
The information emerged from a trawl of deleted emails sent by adviser Andrew Crawford.
Dr Crawford said he may have been asked to provide the information by either the then First Minister Peter Robinson or his then adviser Richard Bullick.
Inquiry counsel Joseph Aiken said the content of the letter may not have provided any advantage but it should not have been done.
The letter concerned BMAP, a planning strategy which was the subject of an ongoing legal challenge.
In February 2015, Dr Crawford sent an email, with the legal letter attached, to Gareth Robinson, a lobbyist and son of Peter Robinson.
Gareth Robinson ran a lobbying and public relations firm called Verbatim Communications.
Dr Crawford told the inquiry he had only meant to forward the email from the Departmental Solicitors' Office and not the attached legal letter.
The body of the email contained information on the progress of the case.
Dr Crawford said he believed Mr Robinson was interested in the timeline around a potential decision.
Dr Crawford said he should not have done what he did and described it as "clumsy".
The Environment minister had approved BMAP, which provided for only bulky goods at Sprucefield, effectively stopping the development of a John Lewis store there.
He was taken to court by Enterprise minister Arlene Foster on the grounds that as it was an issue which cut across several departments it should have been approved by the executive.
'Did not have a clear recollection of events'
The Departmental Solicitors Office was representing the Enterprise Department in the court case.
It sent the legal letter, with an upsum of proceedings to the department.
It was circulated within the department, including to Dr Crawford, who forwarded it to Gareth Robinson.
Dr Crawford said he did not have a clear recollection of the sequence of events but believed he may have been asked to provide the information by either Mr Bullick or Peter Robinson.
He said as Gareth Robinson was the son of his party leader he usually "responded to his queries quicker" than to queries from other lobbyists.
He said he did not appreciate that the letter was a privileged legal document.
Inquiry counsel Joseph Aiken said the content of the letter may not have advantaged Mr Robinson.
But he said Andrew Crawford had told the inquiry he was not in the habit of forwarding confidential government information to outside interests.
He had already conceded that he sent details of proposed changes in the RHI scheme to some family members who had poultry interests.
Mr Aiken asked if he wanted to reconsider earlier evidence to the inquiry in which he rejected suggestions that he was in the habit of circulating confidential government information.
Dr Crawford said it was not a "widespread habit" but it would be for the panel to decide on the appropriateness of it on the occasions it had occurred.
Later Gareth Robinson and his company Verbatim Communications got another mention.
In March 2015 Andrew Crawford had sent him a UK government renewables consultation.
It was for the attention of two renewables firms which were clients of Mr Robinson's, a windfarm company Gaelectric and a solar farm firm Lightsource.
Dr Crawford sent it on three days before it was made publicly available.
Inquiry counsel Joseph Aiken asked what benefit it was to Dr Crawford or to the Enterprise Department for him to work outside the rules in this way.
Dr Crawford said there was no benefit to him personally but it allowed him to build useful industry contacts who he could call on in the future around policy issues.
He said the only advantage to the two companies had been that they'd got the document a couple of days ahead of a six week consultation period.
Mr Aiken asked whether Dr Crawford was a "rogue operator" who ignored the rules or whether this was a widespread practice with many SPADS across different parties "tipping off businesses".
Dr Crawford said he did not accept the description of a rogue Spad and would be surprised if other advisers did not operate in the same way.