Nicola Sturgeon has said there is an “alternative explanation” to claims that her officials gave the name of a woman who had lodged a sexual harassment complaint about Alex Salmond to his former chief of staff in a significant breach of confidence. As she gave evidence to the inquiry into her government’s handling of the complaints on Wednesday morning, the former first minister’s office confirmed he has lodged a formal complaint with the Scottish government’s most senior civil servant, Leslie Evans, about the official who has been accused of – and has denied – disclosing the name of the complainer. Sturgeon is under intense pressure to answer multiple allegations that she misled parliament, after previously secret legal advice and new witness evidence released on Tuesday evening led to calls for her resignation as first minister. During four hours of evidence on Wednesday morning, Sturgeon was asked about a letter from Salmond’s lawyer, Duncan Hamilton, which stated that Salmond’s former aide Geoff Aberdein had told him in early March 2018 that the name of a complainer against Salmond had been leaked to him by one of her senior officials. This account of events was reiterated by Kevin Pringle, formerly a special adviser when Salmond was first minister. Sturgeon told MSPs: “It did not happen in the way that has been described.” Asked by the Scottish Conservative MSP Murdo Fraser who could corroborate the different version of events suggested by her senior official, Sturgeon replied: “It would be serious if the identity of a complainer was revealed, but that is not what I understand happened in the way it is being set out.” In an earlier response, she said she did not accept as fact that it had happened, and that she believed there was an “alternative explanation”. She added that, when she met Salmond at her home on 2 April 2018 – when she said she first became aware of the substance of the allegations – he knew the identity of one complainer because he had previously apologised to her for his behaviour towards her, and he had done his own investigations to find out the name of the other woman. She added that she did not recall Salmond “giving the impression he knew the identity because someone in the Scottish government told him”. Describing Salmond as “one of the closest people to me in my entire life”, she continued to deny that there was any plot against him. Salmond has alleged that there was a “malicious plan” by government and party officials close to Sturgeon, including her husband, Peter Murrell, who is the chief executive of the SNP, to destroy his reputation. She was later questioned by the Scottish Liberal Democrat committee member Alex Cole-Hamilton about when she knew about the allegations against Salmond. This is one of the key charges levelled against her by her former mentor. Salmond, supported by two other witnesses, claims she was told about them by Aberdein in her office on 29 March 2018. Sturgeon previously told Holyrood and the media she first learned of them from Salmond himself, at their meeting at her home on 2 April. She told Cole-Hamilton that she had had a “lingering suspicion” about Salmond since Sky News inquiry in November 2017 relating to his alleged behaviour at Edinburgh airport. “Ahead of 2 April I had an awareness there was a complaint, no doubt I had suspicions about what the nature of that might be, but that is what it was, a general awareness, a suspicion, that no doubt I had all sorts of theories for in my head.” At that meeting, she said, Salmond asked her to read a letter he had been sent by Evans, which detailed the accusations. “But it was reading the permanent secretary’s letter, that he showed me on 2 April, that gave me the knowledge and the detail behind that knowledge.” She was then asked by the independent MSP Andy Wightman about further evidence from Hamilton that Sturgeon had assured Salmond at that meeting that she would intervene in the inquiry on his behalf, telling him: “If it comes to it, I will.” Sturgeon told MSPs: “I believe I did make it clear that I would not intervene. I also know I was trying to let a longstanding friend and colleague down gently and maybe I did it too gently and he left with an impression I did not mean to give.” She insisted: “I had no intention of intervening and crucially I did not intervene.”