I've been working on Provisioning my STM32H563 product and after 3 weeks of not touching the project, I am unable to perform Full Regression or Debug Authentication on my password-provisioned Nucleo Board. I tried using the generated bash scripts from CubeIDE/MX (which are using STM32_Programmer_CLI) and also STM32CubeProgrammer GUI.
I remember before the vacation, I could open and close the Board at will. I always used the same password(.bin).
Provisioning always happened using the generated provisioning.sh script.
Here is the Output of STM32CubeProgrammer (I found it has more info than dbg_auth.sh), after trying Discovery and Full Regression:
17:21:34 : Start Debug Authentication Sequence
17:21:34 : SDMOpen : 609 : open : SDM API v1.0
17:21:34 : SDMOpen : 610 : open : SDM Library version v1.1.0
17:21:34 : open_comms : 501 : open : Asserting target reset
17:21:34 : open_comms : 505 : open : Writing magic number
17:21:34 : open_comms : 515 : open : De-asserting target reset
17:21:34 : open_comms : 567 : open : Communication with the target established successfully
17:21:34 : discovery: target ID.......................:0x484
17:21:34 : discovery: SoC ID..........................:0x00000000_00000000_00000000_00000000
17:21:34 : discovery: SDA version.....................:2.4.0
17:21:34 : discovery: Vendor ID.......................:STMicroelectronics
17:21:34 : discovery: PSA lifecycle...................:ST_LIFECYCLE_CLOSED
17:21:34 : discovery: PSA auth version................:1.0
17:21:34 : discovery: ST HDPL1 status.................:0xffffffff
17:21:34 : discovery: ST HDPL2 status.................:0xffffffff
17:21:34 : discovery: ST HDPL3 status.................:0xffffffff
17:21:34 : discovery: Token Formats...................:0x200
17:21:34 : discovery: Certificate Formats.............:0x201
17:21:34 : discovery: cryptosystems...................:ST Password
17:21:34 : discovery: ST provisioning integrity status:0xeaeaeaea
17:21:34 : discovery: permission if authorized...........:Full Regression
17:21:42 : UR connection mode is defined with the HWrst reset mode
17:21:42 : Start Debug Authentication Sequence
17:21:42 : SDMOpen : 609 : open : SDM API v1.0
17:21:42 : SDMOpen : 610 : open : SDM Library version v1.1.0
17:21:42 : open_comms : 501 : open : Asserting target reset
17:21:42 : open_comms : 505 : open : Writing magic number
17:21:42 : open_comms : 515 : open : De-asserting target reset
17:21:42 : open_comms : 567 : open : Communication with the target established successfully
17:21:42 : [00%] discovery command
17:21:42 : [10%] sending discovery command
17:21:42 : [20%] receiving discovery
17:21:42 : [40%] loading credentials
17:21:42 : [50%] sending challenge request
17:21:42 : [60%] receiving challenge
17:21:42 : SDMAuthenticate : 1298 : client : Found 1 certificates
17:21:42 : [80%] sending ST password
17:21:42 : [90%] receiving response
17:21:42 : Error: Debug Authentication Failed
17:21:42 : Disconnected from device.
17:21:42 : ST-LINK SN : 0032002B3132511238363431
17:21:42 : ST-LINK FW : V3J15M6
17:21:42 : Board : NUCLEO-H563ZI
17:21:42 : Voltage : 3.25V
17:21:42 : Error: Cannot connect to access port 1! If you are trying to connect to a device with TrustZone enabled please try to connect with HotPlug mode. If you are trying to connect to a device which supports Debug Authentication with certificate or password, please open your device using it.
----------------------------------------------------------------------