"Muammar Qaddafi, his regime and the officials who worked with him financed Sarkozy's election campaign in 2007," lawyer Bechir Essed told reporters in Tunis, where Mahmudi is detained, mentioning the sum of some €50 million ($65 million).
Essed's claims came after the French Mediapart website published a document on Saturday which it said showed Libya's financing of Sarkozy's campaign.
Sarkozy has angrily dismissed Mediapart's document as a deliberate forgery timed to destabilise his re-election campaign and is taking legal action against the website.
According to Essed, the deal was concluded by former Libyan intelligence chief Mussa Kussa on the instructions of Kadhafi and that "documents proving the transaction exist."
Another lawyer for Mahmudi, who is facing two demands for extradition to Tripoli, confirmed the claim, adding that his client believes Sarkozy is behind his detention in Tunisia.
"My arrest and my detention in Tunisia were instigated by the French president so that the details of the financing of his 2007 campaign are not revealed," Mahmudi said, according to his lawyer Mabrouk Kourchid.
A Tunisian court in February cleared Mahmudi of crossing illegally into Tunisia as he fled Libya last year but kept him in prison.
He remains the subject of two extradition requests from Libya, and Kourchid said he had been admitted to hospital on Wednesday after suffering a haemorrhage.
Mediapart on Saturday posted what it said was a 2006 document signed by Kussa referring to an "agreement in principle to support the 2007 campaign for the candidate for the presidential elections, Nicolas Sarkozy, for a sum equivalent to €50 million."
Sarkozy, who faces a tough second-round vote on Sunday against Socialist candidate Francois Hollande in his bid to win a second presidential term, dismissed it as a "crude forgery" and said he was taking legal action against Mediapart.
Libya's National Transitional Council (NTC), successors of Qaddafi's ousted regime, said the note was thought to be a fake, and Kussa from exile in Doha also dismissed the document.
Essid said Mahmudi was bitter at "the ingratitude of Sarkozy, who in return was the first to send NATO forces to Libya" to aid the rebellion against Qaddafi.
He refused to comment on the Mediapart report, but said the transaction was carried out by Libya's sovereign wealth fund headed by Bashir Saleh, who is currently in France.
The NTC on Wednesday urged France to extradite Saleh, who it says is the subject of a red notice by Interpol.
French officials have said Saleh was in France under a "diplomatic passport from Niger", but officials in Niger said he no longer had such a passport.
Saleh has also denied being the recipient of the letter published by Mediapart, according to his French lawyer.