Page MenuHome GnuPG

Kleopatra: Loop reading keys from smartcard
Closed, ResolvedPublic

Description

Noticed while doing smartcard tests for 3.2 on Windows. This is not reproducible for me on Linux, but it is reproducible on Windows. Even after a restart of Kleopatra.

I use a PKCS#15 S/MIME card.

I started with an empty GnuPG Homedir and launched Kleopatra. The loop repeats in the similar manner between "[9508] org.kde.pim.kleopatra: Updating key info after changes"

It goes into a loop of:

[9508] org.kde.pim.kleopatra: Updating key info after changes
[9508] org.kde.pim.kleopatra: ReaderStatusThread[GUI]::ping()
[9508] org.kde.pim.kleopatra: ReaderStatusThread[2nd]: new iteration command= "__update__"  ; nullSlot= true
[9508] org.kde.pim.kleopatra: update_cardinfo()
[9508] org.kde.pim.libkleo: sendCommand "SCD SERIALNO"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "SCD SERIALNO" : got ( status( "SERIALNO" ) = "FF0000FF354830313232363537" 
[9508]  )
[9508] org.kde.pim.libkleo: sendCommand "SCD SERIALNO"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "SCD SERIALNO" : got ( status( "SERIALNO" ) = "FF0000FF354830313232363537" 
[9508]  )
[9508] org.kde.pim.libkleo: sendCommand "SCD GETATTR APPTYPE"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "SCD GETATTR APPTYPE" : got ( status( "APPTYPE" ) = "p15" 
[9508]  )
[9508] org.kde.pim.kleopatra: get_card_status( "FF0000FF354830313232363537" , "p15" , 0x6c076b8 )
[9508] org.kde.pim.libkleo: sendCommand "SCD GETATTR $SIGNKEYID"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "SCD GETATTR $SIGNKEYID" : got ( status( "$SIGNKEYID" ) = "P15.55" 
[9508]  )
[9508] org.kde.pim.libkleo: sendCommand "SCD GETATTR $ENCRKEYID"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "SCD GETATTR $ENCRKEYID" : got ( status( "$ENCRKEYID" ) = "P15.58" 
[9508]  )
[9508] org.kde.pim.kleopatra: get_card_status: found P15 card FF0000FF354830313232363537 end
[9508] org.kde.pim.libkleo: sendCommand "SCD LEARN --force"
[9508] org.kde.pim.libkleo: Reading config group "UpdateNotification"
[9508] org.kde.pim.libkleo: Reading config group "KDE Action Restrictions"
[9508] org.kde.pim.libkleo: Reading config group "Icons"
[9508] org.kde.pim.libkleo: Reading config group "Group-n8PTyiLx"
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: 4616692EEEDCB736B380FCA2D78D8BB4CA553DA3
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: 5F4C389C9265ABDE08B21CEA41FAC215ADE1CB46
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: DC0B670A715728F0F8CCA76DEE77B3D57243F72E
[9508] org.kde.pim.libkleo: Read group "konform@heinecke.or.at" (id: "n8PTyiLx", source: 1, keys: 0, isImmutable: false)
[9508] org.kde.pim.libkleo: Reading config group "Group-SdXMcvW1"
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: 4616692EEEDCB736B380FCA2D78D8BB4CA553DA3
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: 5F4C389C9265ABDE08B21CEA41FAC215ADE1CB46
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: 73DE38A58BDC7A11A4A3384749C3A4D4848D585F
[9508] org.kde.pim.libkleo: Read group "nichtkonform@heinecke.or.at" (id: "SdXMcvW1", source: 1, keys: 0, isImmutable: false)
[9508] org.kde.pim.libkleo: Reading config group "Notification Messages"
[9508] org.kde.pim.libkleo: Reading config group "Group-PXkaivIe"
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: 4616692EEEDCB736B380FCA2D78D8BB4CA553DA3
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: 98111E67AE06F2BEFD2BDE10C5D6C919005F36A4
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: DC0B670A715728F0F8CCA76DEE77B3D57243F72E
[9508] org.kde.pim.libkleo: Read group "unbeglaubigt@heinecke.or.at" (id: "PXkaivIe", source: 1, keys: 0, isImmutable: false)
[9508] org.kde.pim.libkleo: Reading config group "Group-Ol959QrJ"
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: 4616692EEEDCB736B380FCA2D78D8BB4CA553DA3
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: 569E9C0F54E80C6ECDD701BB4BAA787CA5E951D6
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: 5F4C389C9265ABDE08B21CEA41FAC215ADE1CB46
[9508] org.kde.pim.libkleo: Read group "abgelaufen@heinecke.or.at" (id: "Ol959QrJ", source: 1, keys: 0, isImmutable: false)
[9508] org.kde.pim.libkleo: Reading config group "General"
[9508] org.kde.pim.libkleo: Reading config group "CertificateCreationWizard"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "SCD LEARN --force" : got ( status( "READER" ) = "SCM Microsystems Inc. SPRx32 USB Smart Card Reader 0" 
[9508]  status( "SERIALNO" ) = "FF0000FF354830313232363537" 
[9508]  status( "APPTYPE" ) = "p15" 
[9508]  status( "MANUFACTURER" ) = "0 Technology Nexus" 
[9508]  status( "CERTINFO" ) = "100 P15.58 Verschlüsselung" 
[9508]  status( "CERTINFO" ) = "100 P15.55 MS_Smartcard_Logon" 
[9508]  status( "CERTINFO" ) = "100 P15.33 Fortgeschrittene_Signatur" 
[9508]  status( "CERTINFO" ) = "100 P15.11 Authentisierung" 
[9508]  status( "CERTINFO" ) = "101 P15.33363339373439393332323232313933323137 -" 
[9508]  status( "CERTINFO" ) = "101 P15.36303134333235313131323332323833313236 -" 
[9508]  status( "KEYPAIRINFO" ) = "83DAC0502E57C04D7EEC05847D79429C92EEEC01 P15.58 e 1650612629 rsa4096" 
[9508]  status( "KEYPAIRINFO" ) = "FE2E7817335F19F3338EC62086B4D666F6292101 P15.55 scea 1650612629 rsa4096" 
[9508]  status( "KEYPAIRINFO" ) = "961BF16F4EE095BC36EC5F6339F1BA10A561C0C5 P15.33 s 1650612629 rsa4096" 
[9508]  status( "KEYPAIRINFO" ) = "3BE5196862C68A4C7B4C850D552070A0CE772827 P15.11 sca 1650612628 rsa4096" 
[9508]  status( "CHV-STATUS" ) = "3 3" 
[9508]  status( "CHV-LABEL" ) = "PIN1 PUK" 
[9508]  )
[9508] org.kde.pim.libkleo: sendCommand "SCD GETATTR KEY-FPR"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "SCD GETATTR KEY-FPR" : got ( status( "KEY-FPR" ) = "1 B74F2C5F0E10F3CFDC2014E2E8994B241BFF459A" 
[9508]  status( "KEY-FPR" ) = "2 1372A71EC30F7BD0DDD280C0803A1AB3472ED892" 
[9508]  )
[9508] org.kde.pim.kleopatra: Card FF0000FF354830313232363537 info:
[9508] org.kde.pim.kleopatra: READER : SCM Microsystems Inc. SPRx32 USB Smart Card Reader 0
[9508] org.kde.pim.kleopatra: SERIALNO : FF0000FF354830313232363537
[9508] org.kde.pim.kleopatra: APPTYPE : p15
[9508] org.kde.pim.kleopatra: MANUFACTURER : 0 Technology Nexus
[9508] org.kde.pim.kleopatra: CERTINFO : 100 P15.58 Verschlüsselung
[9508] org.kde.pim.kleopatra: CERTINFO : 100 P15.55 MS_Smartcard_Logon
[9508] org.kde.pim.kleopatra: CERTINFO : 100 P15.33 Fortgeschrittene_Signatur
[9508] org.kde.pim.kleopatra: CERTINFO : 100 P15.11 Authentisierung
[9508] org.kde.pim.kleopatra: CERTINFO : 101 P15.33363339373439393332323232313933323137 -
[9508] org.kde.pim.kleopatra: CERTINFO : 101 P15.36303134333235313131323332323833313236 -
[9508] org.kde.pim.kleopatra: KEYPAIRINFO : 83DAC0502E57C04D7EEC05847D79429C92EEEC01 P15.58 e 1650612629 rsa4096
[9508] org.kde.pim.kleopatra: KEYPAIRINFO : FE2E7817335F19F3338EC62086B4D666F6292101 P15.55 scea 1650612629 rsa4096
[9508] org.kde.pim.kleopatra: KEYPAIRINFO : 961BF16F4EE095BC36EC5F6339F1BA10A561C0C5 P15.33 s 1650612629 rsa4096
[9508] org.kde.pim.kleopatra: KEYPAIRINFO : 3BE5196862C68A4C7B4C850D552070A0CE772827 P15.11 sca 1650612628 rsa4096
[9508] org.kde.pim.kleopatra: CHV-STATUS : 3 3
[9508] org.kde.pim.kleopatra: CHV-LABEL : PIN1 PUK
[9508] org.kde.pim.kleopatra: KEY-FPR : 1 B74F2C5F0E10F3CFDC2014E2E8994B241BFF459A
[9508] org.kde.pim.kleopatra: KEY-FPR : 2 1372A71EC30F7BD0DDD280C0803A1AB3472ED892
[9508] org.kde.pim.libkleo: sendCommand "READKEY --card --no-data -- P15.58"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "READKEY --card --no-data -- P15.58" : got ( )
[9508] org.kde.pim.libkleo: sendCommand "READKEY --card --no-data -- P15.55"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "READKEY --card --no-data -- P15.55" : got ( )
[9508] org.kde.pim.libkleo: sendCommand "READKEY --card --no-data -- P15.33"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "READKEY --card --no-data -- P15.33" : got ( )
[9508] org.kde.pim.libkleo: sendCommand "READKEY --card --no-data -- P15.11"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "READKEY --card --no-data -- P15.11" : got ( )
[9508] org.kde.pim.libkleo: sendCommand "SCD GETATTR $DISPSERIALNO"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "SCD GETATTR $DISPSERIALNO" : got ( status( "$DISPSERIALNO" ) = "5H01 2265 7" 
[9508]  )
[9508] org.kde.pim.kleopatra: ReaderStatusThread[2nd]: waiting for commands
[9508] org.kde.pim.libkleo: "C:/Users/Andre Heinecke/AppData/Roaming/gnupg/private-keys-v1.d/83DAC0502E57C04D7EEC05847D79429C92EEEC01.key"
[9508] org.kde.pim.libkleo: "C:/Users/Andre Heinecke/AppData/Roaming/gnupg/private-keys-v1.d/FE2E7817335F19F3338EC62086B4D666F6292101.key"
[9508] org.kde.pim.libkleo: "C:/Users/Andre Heinecke/AppData/Roaming/gnupg/private-keys-v1.d/961BF16F4EE095BC36EC5F6339F1BA10A561C0C5.key"
[9508] org.kde.pim.libkleo: "C:/Users/Andre Heinecke/AppData/Roaming/gnupg/private-keys-v1.d/3BE5196862C68A4C7B4C850D552070A0CE772827.key"
[9508] org.kde.pim.kleopatra: Updating key info after changes
[9508] org.kde.pim.kleopatra: ReaderStatusThread[GUI]::ping()
[9508] org.kde.pim.kleopatra: ReaderStatusThread[2nd]: new iteration command= "__update__"  ; nullSlot= true
[9508] org.kde.pim.kleopatra: update_cardinfo()
[9508] org.kde.pim.libkleo: sendCommand "SCD SERIALNO"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "SCD SERIALNO" : got ( status( "SERIALNO" ) = "FF0000FF354830313232363537" 
[9508]  )
[9508] org.kde.pim.libkleo: sendCommand "SCD SERIALNO"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "SCD SERIALNO" : got ( status( "SERIALNO" ) = "FF0000FF354830313232363537" 
[9508]  )
[9508] org.kde.pim.libkleo: sendCommand "SCD GETATTR APPTYPE"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "SCD GETATTR APPTYPE" : got ( status( "APPTYPE" ) = "p15" 
[9508]  )
[9508] org.kde.pim.kleopatra: get_card_status( "FF0000FF354830313232363537" , "p15" , 0x6bdeac0 )
[9508] org.kde.pim.libkleo: sendCommand "SCD GETATTR $SIGNKEYID"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "SCD GETATTR $SIGNKEYID" : got ( status( "$SIGNKEYID" ) = "P15.55" 
[9508]  )
[9508] org.kde.pim.libkleo: sendCommand "SCD GETATTR $ENCRKEYID"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "SCD GETATTR $ENCRKEYID" : got ( status( "$ENCRKEYID" ) = "P15.58" 
[9508]  )
[9508] org.kde.pim.kleopatra: get_card_status: found P15 card FF0000FF354830313232363537 end
[9508] org.kde.pim.libkleo: sendCommand "SCD LEARN --force"
[9508] org.kde.pim.libkleo: Reading config group "UpdateNotification"
[9508] org.kde.pim.libkleo: Reading config group "KDE Action Restrictions"
[9508] org.kde.pim.libkleo: Reading config group "Icons"
[9508] org.kde.pim.libkleo: Reading config group "Group-n8PTyiLx"
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: 4616692EEEDCB736B380FCA2D78D8BB4CA553DA3
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: 5F4C389C9265ABDE08B21CEA41FAC215ADE1CB46
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: DC0B670A715728F0F8CCA76DEE77B3D57243F72E
[9508] org.kde.pim.libkleo: Read group "konform@heinecke.or.at" (id: "n8PTyiLx", source: 1, keys: 0, isImmutable: false)
[9508] org.kde.pim.libkleo: Reading config group "Group-SdXMcvW1"
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: 4616692EEEDCB736B380FCA2D78D8BB4CA553DA3
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: 5F4C389C9265ABDE08B21CEA41FAC215ADE1CB46
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: 73DE38A58BDC7A11A4A3384749C3A4D4848D585F
[9508] org.kde.pim.libkleo: Read group "nichtkonform@heinecke.or.at" (id: "SdXMcvW1", source: 1, keys: 0, isImmutable: false)
[9508] org.kde.pim.libkleo: Reading config group "Notification Messages"
[9508] org.kde.pim.libkleo: Reading config group "Group-PXkaivIe"
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: 4616692EEEDCB736B380FCA2D78D8BB4CA553DA3
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: 98111E67AE06F2BEFD2BDE10C5D6C919005F36A4
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: DC0B670A715728F0F8CCA76DEE77B3D57243F72E
[9508] org.kde.pim.libkleo: Read group "unbeglaubigt@heinecke.or.at" (id: "PXkaivIe", source: 1, keys: 0, isImmutable: false)
[9508] org.kde.pim.libkleo: Reading config group "Group-Ol959QrJ"
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: 4616692EEEDCB736B380FCA2D78D8BB4CA553DA3
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: 569E9C0F54E80C6ECDD701BB4BAA787CA5E951D6
[9508] org.kde.pim.libkleo: findByFingerprint Ignoring unknown key with fingerprint: 5F4C389C9265ABDE08B21CEA41FAC215ADE1CB46
[9508] org.kde.pim.libkleo: Read group "abgelaufen@heinecke.or.at" (id: "Ol959QrJ", source: 1, keys: 0, isImmutable: false)
[9508] org.kde.pim.libkleo: Reading config group "General"
[9508] org.kde.pim.libkleo: Reading config group "CertificateCreationWizard"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "SCD LEARN --force" : got ( status( "READER" ) = "SCM Microsystems Inc. SPRx32 USB Smart Card Reader 0" 
[9508]  status( "SERIALNO" ) = "FF0000FF354830313232363537" 
[9508]  status( "APPTYPE" ) = "p15" 
[9508]  status( "MANUFACTURER" ) = "0 Technology Nexus" 
[9508]  status( "CERTINFO" ) = "100 P15.58 Verschlüsselung" 
[9508]  status( "CERTINFO" ) = "100 P15.55 MS_Smartcard_Logon" 
[9508]  status( "CERTINFO" ) = "100 P15.33 Fortgeschrittene_Signatur" 
[9508]  status( "CERTINFO" ) = "100 P15.11 Authentisierung" 
[9508]  status( "CERTINFO" ) = "101 P15.33363339373439393332323232313933323137 -" 
[9508]  status( "CERTINFO" ) = "101 P15.36303134333235313131323332323833313236 -" 
[9508]  status( "KEYPAIRINFO" ) = "83DAC0502E57C04D7EEC05847D79429C92EEEC01 P15.58 e 1650612629 rsa4096" 
[9508]  status( "KEYPAIRINFO" ) = "FE2E7817335F19F3338EC62086B4D666F6292101 P15.55 scea 1650612629 rsa4096" 
[9508]  status( "KEYPAIRINFO" ) = "961BF16F4EE095BC36EC5F6339F1BA10A561C0C5 P15.33 s 1650612629 rsa4096" 
[9508]  status( "KEYPAIRINFO" ) = "3BE5196862C68A4C7B4C850D552070A0CE772827 P15.11 sca 1650612628 rsa4096" 
[9508]  status( "CHV-STATUS" ) = "3 3" 
[9508]  status( "CHV-LABEL" ) = "PIN1 PUK" 
[9508]  )
[9508] org.kde.pim.libkleo: sendCommand "SCD GETATTR KEY-FPR"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "SCD GETATTR KEY-FPR" : got ( status( "KEY-FPR" ) = "1 B74F2C5F0E10F3CFDC2014E2E8994B241BFF459A" 
[9508]  status( "KEY-FPR" ) = "2 1372A71EC30F7BD0DDD280C0803A1AB3472ED892" 
[9508]  )
[9508] org.kde.pim.kleopatra: Card FF0000FF354830313232363537 info:
[9508] org.kde.pim.kleopatra: READER : SCM Microsystems Inc. SPRx32 USB Smart Card Reader 0
[9508] org.kde.pim.kleopatra: SERIALNO : FF0000FF354830313232363537
[9508] org.kde.pim.kleopatra: APPTYPE : p15
[9508] org.kde.pim.kleopatra: MANUFACTURER : 0 Technology Nexus
[9508] org.kde.pim.kleopatra: CERTINFO : 100 P15.58 Verschlüsselung
[9508] org.kde.pim.kleopatra: CERTINFO : 100 P15.55 MS_Smartcard_Logon
[9508] org.kde.pim.kleopatra: CERTINFO : 100 P15.33 Fortgeschrittene_Signatur
[9508] org.kde.pim.kleopatra: CERTINFO : 100 P15.11 Authentisierung
[9508] org.kde.pim.kleopatra: CERTINFO : 101 P15.33363339373439393332323232313933323137 -
[9508] org.kde.pim.kleopatra: CERTINFO : 101 P15.36303134333235313131323332323833313236 -
[9508] org.kde.pim.kleopatra: KEYPAIRINFO : 83DAC0502E57C04D7EEC05847D79429C92EEEC01 P15.58 e 1650612629 rsa4096
[9508] org.kde.pim.kleopatra: KEYPAIRINFO : FE2E7817335F19F3338EC62086B4D666F6292101 P15.55 scea 1650612629 rsa4096
[9508] org.kde.pim.kleopatra: KEYPAIRINFO : 961BF16F4EE095BC36EC5F6339F1BA10A561C0C5 P15.33 s 1650612629 rsa4096
[9508] org.kde.pim.kleopatra: KEYPAIRINFO : 3BE5196862C68A4C7B4C850D552070A0CE772827 P15.11 sca 1650612628 rsa4096
[9508] org.kde.pim.kleopatra: CHV-STATUS : 3 3
[9508] org.kde.pim.kleopatra: CHV-LABEL : PIN1 PUK
[9508] org.kde.pim.kleopatra: KEY-FPR : 1 B74F2C5F0E10F3CFDC2014E2E8994B241BFF459A
[9508] org.kde.pim.kleopatra: KEY-FPR : 2 1372A71EC30F7BD0DDD280C0803A1AB3472ED892
[9508] org.kde.pim.libkleo: sendCommand "READKEY --card --no-data -- P15.58"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "READKEY --card --no-data -- P15.58" : got ( )
[9508] org.kde.pim.libkleo: sendCommand "READKEY --card --no-data -- P15.55"
[9508] org.kde.pim.libkleo: "C:/Users/Andre Heinecke/AppData/Roaming/gnupg/private-keys-v1.d/83DAC0502E57C04D7EEC05847D79429C92EEEC01.key"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "READKEY --card --no-data -- P15.55" : got ( )
[9508] org.kde.pim.libkleo: sendCommand "READKEY --card --no-data -- P15.33"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "READKEY --card --no-data -- P15.33" : got ( )
[9508] org.kde.pim.libkleo: sendCommand "READKEY --card --no-data -- P15.11"
[9508] org.kde.pim.libkleo: "C:/Users/Andre Heinecke/AppData/Roaming/gnupg/private-keys-v1.d/FE2E7817335F19F3338EC62086B4D666F6292101.key"
[9508] org.kde.pim.libkleo: "C:/Users/Andre Heinecke/AppData/Roaming/gnupg/private-keys-v1.d/961BF16F4EE095BC36EC5F6339F1BA10A561C0C5.key"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "READKEY --card --no-data -- P15.11" : got ( )
[9508] org.kde.pim.libkleo: sendCommand "SCD GETATTR $DISPSERIALNO"
[9508] org.kde.pim.libkleo: "C:/Users/Andre Heinecke/AppData/Roaming/gnupg/private-keys-v1.d/3BE5196862C68A4C7B4C850D552070A0CE772827.key"
[9508] org.kde.pim.libkleo: sendStatusLinesCommand "SCD GETATTR $DISPSERIALNO" : got ( status( "$DISPSERIALNO" ) = "5H01 2265 7" 
[9508]  )
[9508] org.kde.pim.kleopatra: ReaderStatusThread[2nd]: waiting for commands
[9508] org.kde.pim.kleopatra: Updating key info after changes
[9508] org.kde.pim.kleopatra: ReaderStatusThread[GUI]::ping()
[9508] org.kde.pim.kleopatra: ReaderStatusThread[2nd]: new iteration command= "__update__"  ; nullSlot= true
[9508] org.kde.pim.kleopatra: update_cardinfo()

Event Timeline

aheinecke created this task.

Confirmed with two other cards. in the gpg-agent log I also see MARKTRUSTED not supported lines while the card is inserted - this is cause by the loop in Kleo.

The following logs indicate that the file system watcher detects a change of those files and that triggers an update of the keylist and the smart card view. Please check whether those files are indeed rewritten on every iteration.

[9508] org.kde.pim.libkleo: "C:/Users/Andre Heinecke/AppData/Roaming/gnupg/private-keys-v1.d/83DAC0502E57C04D7EEC05847D79429C92EEEC01.key"
[9508] org.kde.pim.libkleo: "C:/Users/Andre Heinecke/AppData/Roaming/gnupg/private-keys-v1.d/FE2E7817335F19F3338EC62086B4D666F6292101.key"
[9508] org.kde.pim.libkleo: "C:/Users/Andre Heinecke/AppData/Roaming/gnupg/private-keys-v1.d/961BF16F4EE095BC36EC5F6339F1BA10A561C0C5.key"
[9508] org.kde.pim.libkleo: "C:/Users/Andre Heinecke/AppData/Roaming/gnupg/private-keys-v1.d/3BE5196862C68A4C7B4C850D552070A0CE772827.key"

Yes these files are rewritten on every iteration.

Okay. How do we fix this? Make gpg-agent not rewrite the files again and again if nothing changed? Stop watching the private key files for changes and then miss updates in Kleopatra causing weird update problems like T5546: Kleopatra: After importing the first pubkey for a card from LDAP the keylistview is not refreshed for which I have introduced watching of the private key files?

@werner I think this question is for you to answer. IMO these files should not be overwritten. I mean they could contain actual secret keys instead of just the shadow keys and then those would be overwritten, right?

Ok since this does not happen with other cards this is definetly a gnupg issue I just checked with a telesec card and the behavior there is different.

@ikloecker I thought about this some more. Why do we do the READKEY when we could look up the keygrips and see that we already have keys for this. That sounds to me like a simpler fix then changing how gpg-agent behaves here. Although I still think that gpg-agent is in the wrong to just overwrite and potentially delete softkeys here.

We always try to update the stub files because meta data of the key material might have changed due to the use on another box. On Windows the file system watch might be triggered by the remove of a key file right before writing it (cf. the usual Windows rename file problem) which is the cause for the loop. The new patches now detect whether a key file actually changed and avoid writing it back to disk.

Looks like Werner fixed this by avoiding unnecessary file changes in the agent.

We can think about changing some things in ReaderStatus, but not that close before a release. Everything done in ReaderStatus is done for a reason (although some things may have become redundant) and I don't want to risk any regressions.

aheinecke moved this task from Restricted Project Column to Restricted Project Column on the Restricted Project board.

Since I have such a test card, I just tested it and the issue is indeed gone.

ebo edited projects, added vsd32 (vsd-3.2.0); removed vsd32.