New York mayoral candidate Anthony Weiner has admitted sending explicit messages to a woman, two years after he left Congress over a similar affair.
An unnamed woman told website The Dirty she had an online relationship with the 48-year-old last year.
Mr Weiner, who has been leading polls of Democratic mayoral candidates, said he was "very sorry".
In 2011, he said his Twitter account was hacked, but then admitted sending lewd photos to young women.
Flanked by his wife, Huma Abedin, at a press conference on Tuesday in New York, he apologised while reading from a prepared statement.
He also said he would not drop out of the city's mayoral race, which will be decided by voters in November. Three of his rivals immediately called on him to stand aside.
Mr Weiner told reporters: "This behaviour is behind me. I've apologised to my wife, Huma, and I'm grateful that she has worked through these issues with me and that I've had her forgiveness.
"I want to again say how very sorry I am to anyone who was on the receiving end of these messages and the disruption that this has caused."
He said some of the latest reports were inaccurate, but refused to go into detail.
Ms Abedin then took to the podium and said: "Our marriage, like many others, has had its ups and its downs. It took a lot of work and a whole lot of therapy to get to a place where I could forgive Anthony."
She continued: "Anthony's made some horrible mistakes, both before he resigned from Congress and after. But I do very strongly believe that it's between us and our marriage."
"I love him, I have forgiven him, I believe in him," she added.
Briefly taking questions after the statements, Mr Weiner admitted that some of the online activity in question had taken place as late as summer last year.
The woman at the centre of the latest allegations has said they began exchanging messages in July 2012 and continued for six months.
She said she was 22 years old when they made contact on the social networking website Formspring.
The woman claimed Mr Weiner had used the alias "Carlos Danger" for their racy exchanges.
"I was young and dumb," The Dirty quoted her as saying.
"I just want people to really know he's lying when he acts like he has changed."
Mr Weiner has previously said he should not have denied posting lewd photos on Twitter in 2011.
He said he only did so because he wanted to keep the truth from his then-pregnant wife, who is a former adviser to Hillary Clinton.
She gave birth to the couple's son, Jordan, later that year.
Mr Weiner will find out how damaging his latest conduct has been in September's primary elections, when Democratic voters decide if he or one of his rivals should represent their party in the mayoral race.
He is not the only disgraced politician aiming for a comeback.
Two weeks ago, former New York Governor Eliot Spitzer - who resigned in 2008 after admitting to paying for sex with prostitutes - announced his candidacy for city comptroller.