Andrew McGlashan is a deputy editor at ESPNcricinfo
Tim Paine has quit as Test captain less than three weeks before the men's Ashes after the emergence of an investigation four years ago by Cricket Australia for sending explicit messages to a female co-worker.
Paine, who has been facing a race against time to be fit for the first Ashes Test on December 8, was named in a News Corp report as being at the centre of the case.
He faced media in Hobart on Friday to announce he was resigning but will remain available for selection for the Ashes. The messages date back to 2017, shortly before Paine was recalled to the Test team after a seven-year absence, and a joint Cricket Australia and Cricket Tasmania investigation cleared him at the time.
"Today, I'm announcing my decision to stand down as the captain of the Australian men's test team. It's an incredibly difficult decision, but the right one for me, my family, and cricket," Paine said as he read out a statement.
"As a background on my decision, nearly four years ago, I was involved in a text exchange with a then-colleague. At the time, the exchange was the subject of a thorough CA Integrity Unit investigation, throughout which I fully participated in and openly participated in.
"That investigation and a Cricket Tasmania HR investigation at the same time found that there had been no breach of the Cricket Australia Code of Conduct. Although exonerated, I deeply regretted this incident at the time, and still do today. I spoke to my wife and family at the time and am enormously grateful for their forgiveness and support. We thought this incident was behind us and that I could focus entirely on the team, as I have done for the last three or four years.
"However, I recently became aware that this private text exchange was going to become public. On reflection, my actions in 2017 do not meet the standard of an Australian cricket captain, or the wider community. I'm deeply sorry for the hurt and pain that I have caused to my wife, my family, and to the other party. I'm sorry for any damage that this does to the reputation of our sport.
He added that he felt resignation was his only option and apologised to team-mates and supporters.
"I believe that it is the right decision for me to stand down as captain, effective immediately," he said. I do not want this to become an unwelcome disruption to the team ahead of what is a huge Ashes series."
"It's been the greatest privilege of my sporting life to lead the Australian men's test team. I'm grateful for the support of my team-mates and proud of what we've been able to achieve together.
"To them, I ask for their understanding and forgiveness. To Australian cricket fans I'm deeply sorry that my past behaviour has impacted our game on the eve of the Ashes. For the disappointment I have caused to fans and the entire cricket community, I apologise.
"I've been blessed with a wonderful, loving and supportive family, and it breaks my heart to know how much I've let them down. They have always stood by me, been my most loyal fans, and I'm indebted to them for their support.
"I will remain a committed member of the Australian cricket team and look forward with anticipation to what is a huge Ashes tour."
A subsequent statement by Cricket Tasmania said the allegations had only been brought to their attention when theft charges were laid against the employee in mid-2018 and that no complaint had been made at the time of the messages in November 2017.
"As soon as Cricket Tasmania was made aware, it undertook an investigation that determined the interaction was consensual, private, occurred on the one occasion only, was between mature adults and was not repeated," Cricket Tasmania chairman Andrew Gaggin said.
"Cricket Tasmania clearly does not condone this type of behaviour and addressed the matter directly with Tim Paine. However, because of the consensual nature of the actions it was determined that no further action was required or appropriate."
Paine was elevated to the captaincy in March 2018 following the explosive fallout from the ball-tampering scandal in South Africa. Fast bowler Pat Cummins is Australia's current vice-captain and had been tipped to assume the role once Paine retired. If Paine was not to play the series, Alex Carey would be the frontrunner to take the gloves.
The board accepted Paine's resignation and has said that process of identifying and appointing a new Test captain will be accelerated.
"Tim felt it was in the best interests of his family and Australian cricket to take this decision to step down as captain," CA chair Richard Freudenstein said. "The Board has accepted Tim's resignation and will now work through a process with the National Selection Panel of identifying and appointing a new captain.
"While the Board acknowledges an investigation cleared Tim of any breach of the code of conduct regarding this matter some years ago, we respect his decision. CA does not condone this type of language or behaviour. Despite the mistake he made, Tim has been an exceptional leader since his appointment and the Board thanks him for his distinguished service.
"Tim will continue to be available for selection in the Test team through the Ashes summer."
AAP contributed to this report