I was wondering about this as well. If this kind of thing is not done pursuant to a search warrant and is in violation of the site's TOS, is it legal for them to do? What happens if I put a blanket ban in the TOS on use of the site by anyone acting as an agent of any law enforcement agency? Certainly with a warrant, it would hold up , but without one, it may not.
Interesting legal question, I guess only time will tell.