The man who firebombed the official residence of Pennsylvania Gov. Josh Shapiro pleaded guilty on Tuesday and was sentenced to 25 to 50 years, prosecutors said.