In a letter to Rouhani, Khamenei, who had the final word on the historic deal struck Tuesday with six powers led by the United States, congratulated Iran's negotiators for "their tireless efforts".
Read: Iran deal will not erase 'profound differences': Obama
Bringing the talks to a close was a "milestone", Khamenei said, but the agreement requires "careful scrutiny" before it is approved.
Rouhani "must be concerned about possible violation of commitments by the other parties and close paths to it," the leader wrote in the letter, published on his website late Wednesday.
"You are well aware that some of the six states participating in negotiations are not trustworthy at all," Khamenei said.
He did not specify which of the six countries -- Britain, China, France, Russia and the United States plus Germany -- he was referring to.
Throughout the almost two years of negotiations that culminated in the landmark agreement, Khamenei often spoke of his distrust of the United States.
US President Barack Obama on Wednesday confronted critics of the agreement, including Israel, saying they were at odds with "99 percent" of the world and had failed to offer any real alternative.
Read: Former Saudi spy chief says Iran nuclear deal will 'wreak havoc'
As the freshly-inked deal was put to members of the UN Security Council, a combative and at times testy Obama said opponents at home and abroad had offered only a path to war.
"If 99 percent of the world community and the majority of nuclear experts look at this thing and they say this will prevent Iran from getting a nuclear bomb, and you are arguing either that it does not or that even if it does, it's temporary... then you should have some alternative," Obama said.
Iran has always denied seeking an atomic weapon, insisting its nuclear programme is for peaceful energy and medical purposes only.
COMMENTS (1)
Comments are moderated and generally will be posted if they are on-topic and not abusive.
For more information, please see our Comments FAQ