<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 15 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Consolas;
        panose-1:2 11 6 9 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;
        mso-fareast-language:EN-US;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:#0563C1;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:#954F72;
        text-decoration:underline;}
code
        {mso-style-priority:99;
        font-family:"Courier New";}
pre
        {mso-style-priority:99;
        mso-style-link:"HTML Preformatted Char";
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:10.0pt;
        font-family:"Courier New";}
span.EmailStyle17
        {mso-style-type:personal-compose;
        font-family:"Calibri",sans-serif;
        color:windowtext;}
span.HTMLPreformattedChar
        {mso-style-name:"HTML Preformatted Char";
        mso-style-priority:99;
        mso-style-link:"HTML Preformatted";
        font-family:"Courier New";
        mso-fareast-language:DE;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri",sans-serif;
        mso-fareast-language:EN-US;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=DE link="#0563C1" vlink="#954F72"><div class=WordSection1><p style='mso-margin-top-alt:0cm;margin-right:0cm;margin-bottom:12.0pt;margin-left:0cm;background:white;vertical-align:baseline'><span lang=EN-US style='font-size:11.5pt;font-family:"Arial",sans-serif;color:#242729'>I have installed GnuPG Windows on a Windows 10 machine and I'd like to use it with Putty as key based ssh authentication together with a smartcard. I got everything working fine.<o:p></o:p></span></p><p style='mso-margin-top-alt:0cm;margin-right:0cm;margin-bottom:12.0pt;margin-left:0cm;background:white;vertical-align:baseline;font-variant-ligatures: normal;font-variant-caps: normal;font-variant-numeric: inherit;font-variant-east-asian: inherit;font-stretch: inherit;line-height:inherit;box-sizing: inherit;orphans: 2;widows: 2;-webkit-text-stroke-width: 0px;text-decoration-style: initial;text-decoration-color: initial;word-spacing:0px'><span lang=EN-US style='font-size:11.5pt;font-family:"Arial",sans-serif;color:#242729'>The only problem I have is that the gpg-agent always checks for the smartcard even when keys are not stored on a smartcard.<o:p></o:p></span></p><p style='mso-margin-top-alt:0cm;margin-right:0cm;margin-bottom:12.0pt;margin-left:0cm;background:white;vertical-align:baseline'><span lang=EN-US style='font-size:11.5pt;font-family:"Arial",sans-serif;color:#242729'><o:p> </o:p></span></p><p class=MsoNormal style='background:#EFF0F1;vertical-align:baseline'><span lang=EN-US style='font-size:10.0pt;font-family:Consolas;color:#242729;border:none windowtext 1.0pt;padding:0cm;background:#EFF0F1;mso-fareast-language:DE'>gpg-connect-agent "keyinfo --list" /bye<o:p></o:p></span></p><p class=MsoNormal style='background:#EFF0F1;vertical-align:baseline'><span lang=EN-US style='font-size:10.0pt;font-family:Consolas;color:#242729;border:none windowtext 1.0pt;padding:0cm;background:#EFF0F1;mso-fareast-language:DE'><o:p> </o:p></span></p><p class=MsoNormal style='background:#EFF0F1;vertical-align:baseline'><span lang=EN-US style='font-size:10.0pt;font-family:Consolas;color:#242729;border:none windowtext 1.0pt;padding:0cm;background:#EFF0F1;mso-fareast-language:DE'>S KEYINFO 16F96695784023BBD32BE7D9F8320568156CB76A D - - - P - - -<o:p></o:p></span></p><p class=MsoNormal style='background:#EFF0F1;vertical-align:baseline'><span lang=EN-US style='font-size:10.0pt;font-family:Consolas;color:#242729;border:none windowtext 1.0pt;padding:0cm;background:#EFF0F1;mso-fareast-language:DE'>S KEYINFO 3D3DE2508675ECE9856242056D8A5956E35B056E D - - - P - - -<o:p></o:p></span></p><p class=MsoNormal style='background:#EFF0F1;vertical-align:baseline'><span lang=EN-US style='font-size:10.0pt;font-family:Consolas;color:#242729;border:none windowtext 1.0pt;padding:0cm;background:#EFF0F1;mso-fareast-language:DE'>S KEYINFO C8316A470CEB466B4565C55B7FB8A98BA10BB558 D - - - P - - -<o:p></o:p></span></p><p class=MsoNormal style='background:#EFF0F1;vertical-align:baseline'><span lang=EN-US style='font-size:10.0pt;font-family:Consolas;color:#242729;border:none windowtext 1.0pt;padding:0cm;background:#EFF0F1;mso-fareast-language:DE'>S KEYINFO C9376FD06A963284ADC1EF46861EC611C5D780B7 D - - - P - - -</span><span lang=EN-US style='font-size:10.0pt;font-family:Consolas;color:#242729;mso-fareast-language:DE'><o:p></o:p></span></p><p style='mso-margin-top-alt:0cm;margin-right:0cm;margin-bottom:12.0pt;margin-left:0cm;background:white;vertical-align:baseline'><span lang=EN-US style='font-size:11.5pt;font-family:"Arial",sans-serif;color:#242729'><o:p> </o:p></span></p><p style='mso-margin-top-alt:0cm;margin-right:0cm;margin-bottom:12.0pt;margin-left:0cm;background:white;vertical-align:baseline'><span lang=EN-US style='font-size:11.5pt;font-family:"Arial",sans-serif;color:#242729;background:white'>This shows that all keys are located on the disk (column with the "D") but the gpg-agent log shows that the agent get a request from putty via the "Pageant" options and he checks for a SC via the scdaemon.<o:p></o:p></span></p><p style='mso-margin-top-alt:0cm;margin-right:0cm;margin-bottom:12.0pt;margin-left:0cm;background:white;vertical-align:baseline'><span lang=EN-US style='font-size:11.5pt;font-family:"Arial",sans-serif;color:#242729;background:white'><o:p> </o:p></span></p><pre style='background:#EFF0F1;vertical-align:baseline'><code><span lang=EN-US style='font-family:Consolas;color:#242729;border:none windowtext 1.0pt;padding:0cm;background:#EFF0F1'>2019-11-01 19:44:18 gpg-agent[6304] DBG: ssh map file 'PageantRequest00003d68'<o:p></o:p></span></code></pre><pre style='background:#EFF0F1;vertical-align:baseline'><code><span lang=EN-US style='font-family:Consolas;color:#242729;border:none windowtext 1.0pt;padding:0cm;background:#EFF0F1'>2019-11-01 19:44:18 gpg-agent[6304] DBG: ssh map handle 0x00000338<o:p></o:p></span></code></pre><pre style='background:#EFF0F1;vertical-align:baseline'><code><span lang=EN-US style='font-family:Consolas;color:#242729;border:none windowtext 1.0pt;padding:0cm;background:#EFF0F1'>2019-11-01 19:44:18 gpg-agent[6304] DBG:           my sid: 'S-1-5-21-2710969852-3158981170-84828875-1001'<o:p></o:p></span></code></pre><pre style='background:#EFF0F1;vertical-align:baseline'><code><span lang=EN-US style='font-family:Consolas;color:#242729;border:none windowtext 1.0pt;padding:0cm;background:#EFF0F1'>2019-11-01 19:44:18 gpg-agent[6304] DBG: ssh map file sid: 'S-1-5-21-2710969852-3158981170-84828875-1001'<o:p></o:p></span></code></pre><pre style='background:#EFF0F1;vertical-align:baseline'><code><span lang=EN-US style='font-family:Consolas;color:#242729;border:none windowtext 1.0pt;padding:0cm;background:#EFF0F1'>2019-11-01 19:44:18 gpg-agent[6304] DBG: ssh IPC buffer at 0x00670000<o:p></o:p></span></code></pre><pre style='background:#EFF0F1;vertical-align:baseline'><code><span lang=EN-US style='font-family:Consolas;color:#242729;border:none windowtext 1.0pt;padding:0cm;background:#EFF0F1'>2019-11-01 19:44:18 gpg-agent[6304] ssh request handler for request_identities (11) started<o:p></o:p></span></code></pre><pre style='background:#EFF0F1;vertical-align:baseline'><code><span lang=EN-US style='font-family:Consolas;color:#242729;border:none windowtext 1.0pt;padding:0cm;background:#EFF0F1'>2019-11-01 19:44:18 gpg-agent[6304] new connection to SCdaemon established (reusing)<o:p></o:p></span></code></pre><pre style='background:#EFF0F1;vertical-align:baseline'><code><span lang=EN-US style='font-family:Consolas;color:#242729;border:none windowtext 1.0pt;padding:0cm;background:#EFF0F1'>2019-11-01 19:44:18 gpg-agent[6304] DBG: chan_0x00000314 -> SERIALNO<o:p></o:p></span></code></pre><pre style='background:#EFF0F1;vertical-align:baseline'><code><span lang=EN-US style='font-family:Consolas;color:#242729;border:none windowtext 1.0pt;padding:0cm;background:#EFF0F1'>2019-11-01 19:44:18 gpg-agent[6304] DBG: chan_0x00000314 <- ERR 100696144 No such device <SCD><o:p></o:p></span></code></pre><pre style='background:#EFF0F1;vertical-align:baseline'><code><span lang=EN-US style='font-family:Consolas;color:#242729;border:none windowtext 1.0pt;padding:0cm;background:#EFF0F1'>2019-11-01 19:44:18 gpg-agent[6304] ssh request handler for request_identities (11) ready<o:p></o:p></span></code></pre><pre style='background:#EFF0F1;vertical-align:baseline'><code><span lang=EN-US style='font-family:Consolas;color:#242729;border:none windowtext 1.0pt;padding:0cm;background:#EFF0F1'>2019-11-01 19:44:18 gpg-agent[6304] DBG: chan_0x00000314 -> RESTART<o:p></o:p></span></code></pre><pre style='background:#EFF0F1;vertical-align:baseline'><code><span lang=EN-US style='font-family:Consolas;color:#242729;border:none windowtext 1.0pt;padding:0cm;background:#EFF0F1'>2019-11-01 19:44:18 gpg-agent[6304] DBG: chan_0x00000314 <- OK</span></code><span lang=EN-US style='font-family:Consolas;color:#242729'><o:p></o:p></span></pre><p style='mso-margin-top-alt:0cm;margin-right:0cm;margin-bottom:12.0pt;margin-left:0cm;background:white;vertical-align:baseline'><span lang=EN-US style='font-size:11.5pt;font-family:"Arial",sans-serif;color:#242729'><o:p> </o:p></span></p><p style='mso-margin-top-alt:0cm;margin-right:0cm;margin-bottom:12.0pt;margin-left:0cm;background:white;vertical-align:baseline'><span lang=EN-US style='font-size:11.5pt;font-family:"Arial",sans-serif;color:#242729'>I do not understand how the gpg-agent determines where to look for the private key (disk or smartcard) and where this is configured. I can switch off the scdaemon via --disable-scdaemon but this has no effect.<o:p></o:p></span></p><p style='mso-margin-top-alt:0cm;margin-right:0cm;margin-bottom:12.0pt;margin-left:0cm;background:white;vertical-align:baseline;font-variant-ligatures: normal;font-variant-caps: normal;font-variant-numeric: inherit;font-variant-east-asian: inherit;font-stretch: inherit;line-height:inherit;box-sizing: inherit;orphans: 2;widows: 2;-webkit-text-stroke-width: 0px;text-decoration-style: initial;text-decoration-color: initial;word-spacing:0px'><span lang=EN-US style='font-size:11.5pt;font-family:"Arial",sans-serif;color:#242729'>When I copy the secret key to the smartcard via keytocard in gpg everything works fine.<o:p></o:p></span></p><p style='mso-margin-top-alt:0cm;margin-right:0cm;margin-bottom:12.0pt;margin-left:0cm;background:white;vertical-align:baseline'><span lang=EN-US style='font-size:11.5pt;font-family:"Arial",sans-serif;color:#242729'><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p></div></body></html>