"Any citizen of the United States, wherever he may be, who, without authority of the United States, directly or indirectly commences or carries on any correspondence or intercourse with any foreign government or any officer or agent thereof, with intent to influence the measures or conduct of any foreign government or of any officer or agent thereof, in relation to any disputes or controversies with the United States, or to defeat the measures of the United States, shall be fined under this title or imprisoned not more than three years, or both.
This section shall not abridge the right of a citizen to apply, himself or his agent, to any foreign government or the agents thereof for redress of any injury which he may have sustained from such government or any of its agents or subjects."
A lot of people claim that this law is blatantly unconstitutional, but we don't really know, since no one has been prosecuted for violating it since 1803. In any case, constitutional or not, it is hard to see how the recent letter to Iranian leaders from 47 Republican Senators would not constitute a violation of this law. Maybe, after 213 years, it's time to see whether treachery like that committed by these 47 Republicans is, in addition to being morally disgusting, actually illegal.