Carolina trailed 1-0 but scored four goals in the final 4:24 of the second period. Whitney needed only 1:40 to notch his second NHL hat trick and then helped set up Justin Williams' team-leading 28th goal with 2.6 seconds remaining in the period, sending the Bruins off the ice to a chorus of boos.
Carolina won for the third time in nine games and took three of four in the season series against the Bruins.
Hurricanes left wing Erik Cole had to be helped off the ice with an apparent lower body injury at 8:46 of the second period and didn't return. Last year, Cole missed the final 22 regular-season games and the first 23 playoff contests. He returned for the last two games of the Stanley Cup finals for the champion Hurricanes.
Rod Brind'Amour added an empty-net goal and had three assists. Cam Ward made 34 saves for Carolina.
Brandon Bochenski scored twice and Paul Mara had his second point in 12 games for Boston, which dropped its fourth straight at home and six of eight overall.