A half-century ago, President John Kennedy could count on the press to be part of a conspiracy of silence when it came to his marital infidelities.

Today, as the David Petraeus case illustrates, it's a mad dash to see who can publish the latest salacious details when a famous, rich or powerful person is publicly entangled in an affair.

There's no rewinding the clock when it comes to exposing private indiscretions of public figures. But what are the ground rules these days when it comes to punishment and redemption?

For the guilty party, a scarlet letter is no longer required, but there will be sanctions. Punishment comes on a sliding scale that depends to some degree on the way the guilty handle things in the public eye.

So here's a rough guide for public figures to consider before their sexual misbehavior starts trending on Twitter.

1. Confess Before The Media Break The Story: Petraeus caught everyone by surprise when he dropped his bombshell last Friday. He's still facing saturation coverage, but this is still preferable to being uncovered by the media and, worse yet, denying the story, according to Gene Grabowski, who advises clients on crisis management at Levick, a Washington, D.C., firm.

"You have to run to the light," says Grabowski. "You don't want to create a painful drip-drip-drip for yourself, the institution and the administration. It's much better to face the tsunami and get it behind you as quickly as possible."

Denying accusations is likely to create a protracted battle over disclosure that can destroy a public career. Former senator and presidential candidate John Edwards is the poster boy for this approach.

2. If You're A Public Official, Resign Immediately: Hollywood stars and face-of-the-franchise athletes can endure embarrassing supermarket tabloid stories. Maybe it makes them into a punch line for a while, and maybe they need to hire an expensive divorce lawyer, but the career can survive.

Comedian David Letterman startled his viewers one night in 2009 when he opened his show by announcing that he'd had affairs with women who worked on his program.

"He explained what he'd done wrong, he asked his audience to understand, and it worked out pretty well for him," Grabowski says. "That's because his job doesn't depend on public trust. For the CIA director, it's 99 percent about trust."

So, for public officials, adultery often requires a new line of work.

With his storied military career, which has included tours as the top commander in both Iraq and Afghanistan, Petraeus has supporters who are asking whether the bar has been set too high.

The military has to have "higher standards because of their need to trust each other and to lead people in very dangerous circumstances," Richard Kohn, who studies civilian-military relations at the University of North Carolina, told NPR's Morning Edition. "But it's gotten to the point, I think, of being unreasonable expectations on a lot of these people."

Military analyst Tom Ricks, also speaking on Morning Edition, noted that Dwight Eisenhower, when serving as the top commander of Allied forces in Europe during World War II, allegedly carried on an affair with his female driver. No one suggested that was grounds for dismissal at such a critical time.

"Our standards have changed in a way that's not for the better," Ricks said. "We're very lax in enforcing professional standards and demanding professional competence. Yet somehow we've become very insistent about judging people's private, consenting relations with other adults."

"What I would like to have seen President Obama do is say, 'You know, Dave, you really screwed up this time. You need to go home and make amends to your wife. And then your punishment, fellow, is that you're going back to work. Because you're too important to just be thrown out,' " Ricks says.

But it's too late for that.

3. Lay Low For A While: It's extremely rare to carry on as if nothing has happened, even if it's theoretically possible. When golfer Tiger Woods held a 2010 news conference to acknowledge serial philandering, there was nothing keeping him from heading straight back out for the next tournament.

But the prospect of incessant scrutiny led him to take a prolonged break. The scandal passed and he returned to the links, though he has struggled to regain his old form.

4. You May Need To Return In A Different Role: Once tarnished in a sex scandal, government officials and military officers need to find a new career.

When they do, it's often back in the public eye. Eliot Spitzer resigned as New York's governor after a sex scandal and re-emerged only months later as the host of a CNN program.

For Petraeus, returning to a top national security job seems out of the question, but he will be in great demand in the private sector.

"This will pass quickly. Even now, Petraeus has many defenders because he was so good at cultivating the media," says Grabowski. "He's not radioactive. He won't have any difficulty landing a high-level position — but it will be in the private sector."

Copyright 2012 National Public Radio. To see more, visit http://www.npr.org/.