If the sequential or parallel boot mode fail, BOK bit in FCSESTAT register is cleared and you can't use boot protected keys.
See "3.1.3 Key Attributes" in AN5401 for details.
See also SW examples in the application note. When loading a key, attributes can be added when calling calculate_M1_to_M5() function. It's the last parameter.
Regards,
Lukas