NEW YORK — Pope Benedict XVI returned to the clergy sex-abuse scandal as he preached Saturday in St. Patrick’s cathedral, assuring priests and nuns that he was close to them as they battled the damage left by the scandal.

Addressing some 3,000 people, most of them clergy, he called it a time for purification and healing.

“I simply wish to assure you, dear priests and religious, of my spiritual closeness as you strive to respond with Christian hope to he continuing challenges that this situation presents,” Benedict said.

He also urged them to cooperate with bishops, who he said were working to resolve the crisis.

Saturday was the third anniversary of Benedict’s election as pope and he was feted by cardinals and bishops, priests and nuns who jammed the magnificent Gothic church on Fifth Avenue.

He was met outside by Mayor Michael Bloomberg, while former Mayor Rudy Giuliani was inside.

Benedict blessed the cathedral with holy water before making his way to the altar of the landmark church. As the pope walked down the center aisle, nuns clutched at his robes, showing an enthusiasm for his presence that has spread among the general public.

The Vatican said the German-born pope came outside from his residence on the Upper East Side Friday night to greet a crowd of more than 500 people who had lined up for hours. He shook hands and blessed the crowd before returning inside.

At the cathedral, Benedict touched on the theme of his trip — Christian hope — saying he wanted to communicate the joy born of faith to a cynical world.

But since the start of his trip Tuesday, Benedict has concentrated on the clergy sex-abuse scandal that has shaken the U.S. church. He has said that it is more important to have good priests than many priests.

A top Vatican official now says the Roman Catholic Church is weighing a further change to clean up the clergy: revising church law so predators could be more easily removed.

“It’s possible,” said Cardinal William Levada, head of the Vatican office that reviews abuse claims against priests worldwide.

“There are some things under consideration that I’m not able to say,” Levada told reporters Friday, in a meeting at Time magazine’s offices.

It is the latest signal during Benedict’s first papal visit to America that he is intent on purifying the priesthood as he affirms traditional Catholic practices and teaching.

He spoke privately with victims — in what is believed to be the first time a pope has met with people who had been abused by priests. He also told bishops the problem had sometimes been very “badly handled” — an indirect but clear papal admonition.

Still, Benedict has offered support to America’s clergy during his visit.

He said priests who had done nothing wrong had been unfairly tarred by the crisis. More than 4,000 clergy have been accused of molesting minors in the U.S. since 1950. Abuse-related costs have surpassed $2 billion in that period, with much of the payouts in just the last six years. But most of the recent claims concern wrongdoing that occurred decades ago.

At the height of the scandal, which erupted in 2002 with the case of one predator in the Archdiocese of Boston, the shame was so intense that some priests took off their clergy collars before going out in public. Benedict compared their suffering to “Christ in his Passion.” However, morale has been improving as the intensity of the crisis has eased.

Seminary rectors say that their students are eager to show through their service to parishioners that the priesthood can still be a noble calling.

The priesthood has been shrinking for decades. More than 3,200 of the 18,600 U.S. parishes don’t have resident priests, according to the Center for Research in the Apostolate at Georgetown University. More lay people than clergy work full-time in the churches.

The U.S. Conference of Catholic Bishops created a recruitment campaign called “Fishers of Men,” that encourages priests to invite young men to consider entering the priesthood.

Dioceses have been hiring recruiters to travel overseas to find clergy candidates. The number of priests from other countries has grown so steadily that some seminaries are adding English classes, hiring accent reduction tutors and providing courses on American culture.

International recruitment is motivated partly by the exploding demand for Spanish speakers for the Latino immigrants filling the pews.

Leading a Mass in Nationals Park in Washington Thursday, Benedict asked the thousands of parishioners who crammed the stadium to “love your priests, and to affirm them in the excellent work that they do.” Later Saturday in New York, Benedict will speak to seminarians at a youth rally. Then on Sunday, the final day of his trip, he will visit ground zero and hold a Mass at Yankee Stadium.

The owners of Boulder’s Sterling University Peaks apartments, who this summer were cited for illegally subdividing 92 bedrooms in the complex, have reached an agreement to settle the case for $410,000, the city announced Thursday.