VATICAN CITY -- Pope Francis on Tuesday freed a Vatican monsignor convicted of leaking confidential documents to journalists, granting him a Christmas-time clemency and ending an embarrassing episode for the Holy See.

Francis granted “conditional freedom” to Spanish Monsignor Lucio Vallejo Balda after he served half of his 18-month sentence, the Vatican said late Tuesday. Fired from his job as a high-ranking Vatican financial official, Vallejo now falls under the authority of his local bishop in Astorga, Spain.

In July, a Vatican court convicted Vallejo of conspiring to pass documents onto two journalists, although it cleared him and a co-defendant of forming a criminal organization to do so.

Get Breaking News Delivered to Your Inbox

The case had been criticized by media rights groups because the two journalists were also put on trial, though the court ultimately declared it had no jurisdiction to prosecute them.

The two journalists, Emiliano Fittipaldi and Gianluigi Nuzzi, wrote blockbuster books last year based on Vatican documents exposing the greed of bishops and cardinals angling for big apartments, the extraordinarily high costs of getting a saint made and the loss to the Holy See of millions of euros in rental income because of undervalued real estate.

In this Nov. 24, 2015 file photo, from left, Italian journalists Gianluigi Nuzzi and Emiliano Fittipaldi, public relations expert Francesca Chaouqui and Monsignor Angelo Lucio Vallejo Balda sit during their trial inside the Vatican. AP

The documentation had been compiled by a pontifical commission that Francis had asked to gather information about the Vatican’s finances to make them more transparent and efficient.

Vallejo, the No. 2 of the commission, admitted in court that he gave Nuzzi 85 passwords to password-protected documents. He denied that the journalists threatened him, and put the blame of feeling pressured on Francesca Chaouqui, the communications expert who was also a member of the commission and was convicted alongside him of conspiracy.

She received a 10-month suspended sentence.

Publishing confidential information is a crime in the Vatican, punishable by up to eight years in prison.

The trial had several surreal moments, including when Vallejo was put back under house arrest after a friend sneaked a cellphone to him inside a cake.

Francis’ Christmas-time clemency harks back to the 2012 gesture granted by Pope Benedict XVI to his then-butler, who had been convicted of giving Nuzzi confidential documents for an earlier book about Vatican misdeeds.