diff --git a/src/app/modules/main/controller.nim b/src/app/modules/main/controller.nim index 6686254580..d7c0bcc2ed 100644 --- a/src/app/modules/main/controller.nim +++ b/src/app/modules/main/controller.nim @@ -372,7 +372,8 @@ proc init*(self: Controller) = let data = SharedKeycarModuleArgs(uniqueIdentifier: self.authenticateUserFlowRequestedBy, password: args.password, pin: args.pin, - keyUid: args.keyUid) + keyUid: args.keyUid, + keycardUid: args.keycardUid) self.authenticateUserFlowRequestedBy = "" self.events.emit(SIGNAL_SHARED_KEYCARD_MODULE_USER_AUTHENTICATED, data) diff --git a/src/app/modules/shared_modules/keycard_popup/controller.nim b/src/app/modules/shared_modules/keycard_popup/controller.nim index 3e0499995f..8863050f85 100644 --- a/src/app/modules/shared_modules/keycard_popup/controller.nim +++ b/src/app/modules/shared_modules/keycard_popup/controller.nim @@ -582,6 +582,7 @@ proc terminateCurrentFlow*(self: Controller, lastStepInTheCurrentFlow: bool) = self.tmpFlowData.password = exportedEncryptionPubKey self.tmpFlowData.pin = self.getPin() self.tmpFlowData.keyUid = flowEvent.keyUid + self.tmpFlowData.keycardUid = flowEvent.instanceUID else: self.tmpFlowData.password = self.getPassword() self.tmpFlowData.keyUid = singletonInstance.userProfile.getKeyUid() diff --git a/src/app/modules/shared_modules/keycard_popup/io_interface.nim b/src/app/modules/shared_modules/keycard_popup/io_interface.nim index 381e4f3fc6..668856d103 100644 --- a/src/app/modules/shared_modules/keycard_popup/io_interface.nim +++ b/src/app/modules/shared_modules/keycard_popup/io_interface.nim @@ -23,7 +23,7 @@ const SIGNAL_SHARED_KEYCARD_MODULE_KEYCARD_SYNC_TERMINATED* = "sharedKeycarModul ## and props there will be emitted: ## -- `uniqueIdentifier` - will be the same as one used for running authentication process ## -- in case of success of a regular user authentication `keyUid`, `password` will be sent, otherwise it will be empty -## -- in case of success of a keycard user authentication `keyUid`, `pin` and `password` will be sent, otherwise they will be empty +## -- in case of success of a keycard user authentication `keycardUid`, `keyUid`, `pin` and `password` will be sent, otherwise they will be empty ## ## TLDR: when you need to authenticate user, from the module where it's needed you have to send `SIGNAL_SHARED_KEYCARD_MODULE_AUTHENTICATE_USER` ## signal to run authentication process and connect to `SIGNAL_SHARED_KEYCARD_MODULE_USER_AUTHENTICATED` signal to get the results of it. @@ -37,6 +37,7 @@ type password*: string pin*: string # this is used in case we need to run another keycard flow which requires pin, after we successfully authenticated logged in user keyUid*: string + keycardUid*: string type SharedKeycarModuleFlowTerminatedArgs* = ref object of SharedKeycarModuleArgs