Bingo. The entire NSA hearing a few days ago was NSA directors pointing out under which law they perform each action. They could do it, because according to US law it is legal.
The much more deep rooted question is "is this good?" Every aspect of law in the United States can be changed and rewritten according to the conscious of the people, though this takes a long time to do. Legality is temporary. Under ideal circumstances we would debate "right vs wrong" and change laws accordingly.