"The Star-Spangled Banner" in no way glorifies or celebrates slavery. The middle two verses of Key's lyric vilify the British enemy in the War of 1812, what Key refers to in Verse 3 as "hirelings and slaves." This enemy included both whites and blacks, largely British professional soldiers (hirelings) but also the Corps of Colonial Marines (slaves). The Colonial Marines were escaped black American slaves who joined British forces because of the promise of freedom in return for fighting their former masters.
Fortunately, Britain honored this promise after the war, relocating the former slaves and their families to Halifax and Trinidad. For Key, however, the British mercenaries were scoundrels and the Colonial Marines were traitors who threatened to spark a national insurrection.
Yet in 1814 Key's lyric honored American soldiers both black and white. "The Star-Spangled Banner" celebrates the heroes who defended Fort McHenry in the face of almost certain defeat against the most powerful gunships of the era. America's soldiers included mainly whites, but also free and escaped blacks.
http://www.cnn.com/2016/08/31/opinions/star-spangled-banner-criticisms-opinion-clague/index.html
Mark Clague says the national anthem doesn’t glorify slavery or racism but it is a product of its time.