SDK fails some times (Error Code 19: Security Error)

Hi,

I have implemented the “GetStatusCommand” but it is causing some temporal errors. If I try many times, it works once or twice but it also fails. Always, I am trying with the same code developed in PHP.

Please, find below the log messages:

  • Error:
joaquin@joaquin-lap-linux:~/PhpstormProjects/LPRManager$ php bin/console integrations:milestone STATUS
08:56:06 ERROR     [app] Get Server Status: Ko. Milestone login error. Milestone Error Code: 19
08:56:06 ERROR     [app] Milestone Disconnect: Ko. Milestone login error. Milestone Error Code: 19
08:56:06 ERROR     [app] Milestone Disconnect: Ko. Milestone login error. Milestone Error Code: 19
 
                                                                                                                        
 [WARNING] Command Name: "GetServerStatus" | Result: "Error" | Error Code: "19"                                         
                                                                                                                        
 
08:56:06 WARNING   [app] 2022-11-30T08:56:06+01:00-Milestone Command: KO. Milestone command executed with errors. Start time: 2022/11/30 08:56:05. End time: 2022/11/30 08:56:06. Details: Command Name: "GetServerStatus" | Result: "Error" | Error Code: "19"
  • After that a new attempt:
joaquin@joaquin-lap-linux:~/PhpstormProjects/LPRManager$ php bin/console integrations:milestone STATUS
 
                                                                                                                        
 [SUCCESS] Command Name: "GetServerStatus" | Result: "OK" |                                                             
                                                                                                                        

The workflow to make the request is:

  1. Connect and get public key from server.
  2. Calculate shared key and encrypt credentials. Login successfully.
  3. Execute “RequestChallengues”.
  4. If success, store the challengues and use to request server status (to test) using “GetServerStatus” command.
  5. Once getting the result or the error, proceed to disconnect from server.

Please, could you help us? We are using versión 2022 R1

Thank you. Best regards,

Joaquín

Hey,

Few things that might have gone wrong

  1. Challenge is already used - each challenge can be used only once
  2. Challenge has expired - make sure you are using not expiring challenge
  3. Calculated hash is wrong

KR,

Svetlana