There are in fact whistleblower laws. The big question at hand is how it was handled. Snowden claimed to go to his superiors first, which checks off an important box. So the question is if he did that or not. I believe he was also supposed to attempt to report to Congress before he can legally go to the media. It's definitely a gray area and if you believe it is right probably depends on how much you trust the government and moral factors.