Nub to the board but also a firefighter with a small amount of knowledge on the subject.
The fire rating is based on the safe being impacted by external temperatures for a certain amount of time with the internal temp not exceeding 350 degrees. Smokeless powders can auto ignite (that’s igniting without and open flame ignition source) in the 320 degree range (Accurate double-base MSDS), I would imagine black powder and maybe even some other smokeless powders could be less.
That being said, unless you are packing a significant amount of powder into your safe (in my mind that's >5lbs in a 40 cubic safe) I doubt that you would have a catastrophic failure of the safe. There just isn't enough gas produced in the combustion to cause the safe to go boom. However, in the event of a fire there would certainly be an increased potential for the loss of everything combustible inside with internal temperature never meeting the rating of the safe (at least prior to the powder lighting off). Sorry to be so thorough, it’s just how my brain is wired.
Saami's recommendations for powder storage, based off National Fire Protection Association (NFPA) standards.