The verdict was reached during closed-door trials held on Tuesday in the Judicial Assistance Directorate of Managua, according to the Nicaraguan Center for Human Rights (CENIDH) and the relatives of both defendants.
Nicaragua has already convicted 10 opposition leaders in recent weeks, according to human rights organizations.
The Prosecutor's Office requested an eight-year sentence for Aguirre Sacasa, his son Roberto Aguirre told CNN. The former foreign minister was arrested on July 29 for alleged crimes against national sovereignty.
On his Twitter account, Aguirre said his father has spent nearly 200 days in the Chipote prison, and refused to accept the former foreign minister had committed treason. Sentencing is scheduled for February 16.
The Nicaraguan Center for Human Rights criticized journalist Mendoza's nine-year sentence requested by the Prosecutor's Office, calling the charges "invented crimes."
"In this judicial farce he was accused of undermining national integrity, and the verdict was based on the fact that he posted messages on Twitter and retweeted representatives and congressmen of the United States," the Nicaraguan Center for Human Rights (CENIDH) reported.
"He is not a criminal; he is a journalist dedicated to the sports chronicle in a professional way and an honorable person who has endured different stages based on sacrifice," Mendoza's family said in a press conference.
Mendoza was arrested by the National Police on June 21 at his home for alleged acts against national sovereignty, authorities say.
CNN has repeatedly sought comment from the judiciary, but it does not respond to questions from independent media. The Public Ministry has not released information about either case.