Cardinal Bernard F. Law, whose stature as archbishop of Boston and America’s senior Roman Catholic prelate was shattered in a maelstrom of scandal, acrimony and resignation in 2002 after it was revealed that he had protected abusive priests for years, died on Wednesday in Rome. He was 86.

The Vatican confirmed the death in a news release.

Cardinal Law was a staunch defender of church orthodoxy, a Harvard-educated advocate of social justice for immigrants and the poor who had campaigned for civil rights in the segregated South. And when he arrived in Boston in 1984 as Pope John Paul II’s new archbishop, he was welcomed like a favorite son.

Over the next 17 years, he became one of the nation’s most influential churchmen, a protégé and confidant of the pope, a friend of presidents, a force in politics who traveled widely, conferred with foreign leaders and nurtured Catholic relations with Protestants, Jews and others. Admirers thought he might become the first American pope.