Charlie Sheen is on the brink of a legal fight with the people he claims shook him down for millions.

Sheen said on “Today” some of his sex partners threatened to expose his HIV status unless he paid them huge amounts of money. But several lawyers who rep some of the sex partners tell us they did not shake Charlie down at all … the settlements were all kosher and legal.

We’re told the settlements were structured in installments over a period of years. Charlie said flatly, the gravy train will stop now … he will not continue to pay.

But the lawyers for the sex partners tell us, if Charlie stops paying they will go after him with a vengeance. What’s more, we’re told under the settlements, if Charlie misses an installment the entire sum becomes due immediately.

The lawyers say their clients are victims … people who didn’t know they were having sex with someone with the HIV virus … some of whom claim the sex was unprotected.