This is an interesting question, but quite a complex and troubling issue, which to me, leads to more questions and thoughts.
The below assumes that the sport is prohibiting the use of peds.
What should be done from a ethical/moral standpoint to the guilty party?
It seems obvious that ethically, that the doper, once found guilty, should be exposed publicly and punished accordingly to deter more doping. If a high ranked player is exposed and punished, the deterrent will be even greater, showing that every player will be subject to being exposed. A strategy of only exposing low ranked players simply makes the player seem like a scapegoat and leads to "protected player" claims.
What will probably be done because of the "damage" it could cause to the sport?
It is likely that the situation will be handled as quietly as possible. I would doubt that it will just be swept under the rug.
Instead, the player will be told to take a hiatus from the sport and attribute it to injury or health issues. Depending on the severity found, the player might be "silently banned" for a certain amount of time, or perhaps for life and asked to retire. I would hope that the punishment would be equal for all, no matter the player's rank or importance. It may be that the records will be not be changed as questions could be raised, or perhaps they may be changed much later.
Which entity should be ultimately in charge of testing and follow-up of failed tests and finally punishment?
I believe to ensure integrity, it should be a separate body from the entities that run the sport (ATP, ITF), and autonomous, but they should be in communication with those entities and agree to a certain way of handling the process.
We have an example in cycling from perhaps which we can learn something that leads to more questions.
1. When there is sufficient evidence to bring forward a legal accusation, it seems obvious that it needs to be done. However, even if the player were ultimately found to be innocent, the mere accusation and lengthy process that ensues can be just as damaging to the player and the sport. What can be done to protect the player, and the sport, while maintaining the integrity of the game?
I think in this situation there needs to be a sort of "grand jury" type of investigation/trial procedure, that is done behind
closed doors. Once out in the public domain, the damage is done. Now once the player has been found guilty, I think the proper thing to do is to make the announcement. Yes, some may say that the sport might be "damaged" to an extent, but the risk of it being covered up and found out later will make the sport lose integrity even faster.
2. There are also issues in which testimony can be trusted. Should anecdotal evidence like "I saw the dope in the refrigerator when I was over there at a party" be taken seriously? Or should evidence be limited to only that produced by testing?
I think it should start with testing, unless there is relatively clear evidence (video, taped conversations). There are too many player associations that may have axes to grind. In short, it should be legal evidence.
3. Testing technology is almost always behind the latest designer drugs. As new tests are developed old tests that were once "passed" may fail in the future. What should and can be done to a player where the failure is found and the player is found guilty?
One could attempt to get the money, if the player still has it. As others have pointed out, it would be almost impossible to redistribute it fairly to the remaining players. Perhaps whatever money is recovered could go to a charity designated by the first player who was beaten by the doper, or split among charities for all players beaten by the doper. Trophies should be returned to the tournament. The matter of points and titles being subtracted from the player's record is a tricky one, if the intent is to punish the player silently to "protect the sport", it becomes obvious that things don't add up if they are stripped. If that is not a consideration, then those things can be stripped and not re-awarded.
As I said, it is a complex issue, but it should be tackled properly. I've given some of my thoughts for whatever they are worth.
I'm sure many of you will have differing opinions. But perhaps there is already a process in use of which most of us are unaware.