Hi @ale_di_vi
According to the information we have, one of the functions affected by the security bits is CMD_LOAD_KEY, specifly is affected by the Write Protection Flag (WRITE_PROT), Boot Protection Flag (BOOT_PROT), Debugger Usage Protection Flag (DEBUG_PROT) and Wildcard Protection Flag (WILDCARD).
As far as we understand, you will not be able to update the Key when DEBUG_PROT is set.
Please refer to the following image.

B.R.
VaneB