{"componentChunkName":"component---src-templates-post-template-js","path":"/note-credential-rdp-en","result":{"data":{"markdownRemark":{"id":"cd5a29ae-2972-55c1-a553-7a05f93198ce","html":"<blockquote>\n<p>This page has been machine-translated from the <a href=\"/note-credential-rdp\">original page</a>.</p>\n</blockquote>\n<p>Ever since I started using Windows 11, automatic connections using credentials saved in an <code class=\"language-text\">.rdp</code> file have started failing with the error below.</p>\n<p><span\n      class=\"gatsby-resp-image-wrapper\"\n      style=\"position: relative; display: block; margin-left: auto; margin-right: auto; max-width: 637px; \"\n    >\n      <a\n    class=\"gatsby-resp-image-link\"\n    href=\"/static/e85d850dd8a0cc0e06eca70ec3e2e69d/13a9a/image-20250101220630899.png\"\n    style=\"display: block\"\n    target=\"_blank\"\n    rel=\"noopener\"\n  >\n    <span\n    class=\"gatsby-resp-image-background-image\"\n    style=\"padding-bottom: 98.33333333333334%; position: relative; bottom: 0; left: 0; background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAACXBIWXMAAAsTAAALEwEAmpwYAAACkklEQVQ4y41UyW4TQRCdL8AOASkee+xZvI3t2Yy3eImdeEmUO+I/EAiBAvwpJ7hx4AAoSMCjX5kejZ1Acniq6uru17W2cXJygsvLS9TrdcxmM4xGI/T7ffR6PbiuC9u2UziOI6BeqVRSu9Y7nQ6MRqMhZKVSCZ7npRcpi8UiCoWCSK2bppkS7JMSRrPZxOnpKQaDAY6Pj7Fer3F2diaSHl9cXGA8HmM6nWI+n8tZer5PmhLWajUsFgshnEwmWC6XsuZlEjEllMPhUOwk1hHsh0wYvu/LqyQgIb3jJeaQNhLSThs9JjF13uFDPE8710yZwfxxsdls5DLBNb3RZLy4Wq0EQRDAsqzUM12oNGS9US6XBTysdX0ou58NL5u7NGR6SE9YEEp6Vq1Wb1y8C/q8tA37rtvtSjgsUvbl+2CHkEVhblhdVpoes5X40F3gOTqwEzITynBZUUp2e7vdRhzHSJLkVkRRhDAMRdKhHUK+sg05kZZIkljGjxORy+VwcHCQIp/Pi2Thsr24Q+ipAoQh88eXu8rDWK0TPHp8hAe5hzg8PLyBbNvcyGG1WkYSm4hCE522KXoYmBgNyug9sVWzujJqWfzrcxBC17URdYroRkWRSVhEHFmCKLTuVdksDDG2Qti+QisQ3bI9lCwHpbLyhrnam93/waiofNSDDhpxhIaqXFMVx7FKsAtHsM0CKurLqvz9svY9vK1fDZuNPBztwJmoH2U8URhv5WAIR+VOzy2hR9HN2Lc5fPoM/g/A//oT/vffaH65Ru3DJ/jffm1t10Dz42e01O8TtFrSp+zR8/Nz+UTYs5wwPWWG0x/Au3oP781bhXfwXl/BffFqq9PGvecvUeVUqBbjJU4TSdncXGvQ2z/JG124Ej/dfgAAAABJRU5ErkJggg=='); background-size: cover; display: block;\"\n  ></span>\n  <picture>\n          <source\n              srcset=\"/static/e85d850dd8a0cc0e06eca70ec3e2e69d/8ac56/image-20250101220630899.webp 240w,\n/static/e85d850dd8a0cc0e06eca70ec3e2e69d/d3be9/image-20250101220630899.webp 480w,\n/static/e85d850dd8a0cc0e06eca70ec3e2e69d/63990/image-20250101220630899.webp 637w\"\n              sizes=\"(max-width: 637px) 100vw, 637px\"\n              type=\"image/webp\"\n            />\n          <source\n            srcset=\"/static/e85d850dd8a0cc0e06eca70ec3e2e69d/8ff5a/image-20250101220630899.png 240w,\n/static/e85d850dd8a0cc0e06eca70ec3e2e69d/e85cb/image-20250101220630899.png 480w,\n/static/e85d850dd8a0cc0e06eca70ec3e2e69d/13a9a/image-20250101220630899.png 637w\"\n            sizes=\"(max-width: 637px) 100vw, 637px\"\n            type=\"image/png\"\n          />\n          <img\n            class=\"gatsby-resp-image-image\"\n            src=\"/static/e85d850dd8a0cc0e06eca70ec3e2e69d/13a9a/image-20250101220630899.png\"\n            alt=\"image-20250101220630899\"\n            title=\"image-20250101220630899\"\n            loading=\"lazy\"\n            style=\"width:100%;height:100%;margin:0;vertical-align:middle;position:absolute;top:0;left:0;\"\n          />\n        </picture>\n  </a>\n    </span></p>\n<p>From this error, it appears that Credential Guard is blocking the use of stored credentials.</p>\n<p>From a quick investigation, Credential Guard seems to be enabled by default starting with Windows 11 22H2.</p>\n<p>Reference: <a href=\"https://learn.microsoft.com/ja-jp/windows/security/identity-protection/credential-guard/#default-enablement\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">Overview of Credential Guard | Microsoft Learn</a></p>\n<p>I could not determine in detail why Credential Guard blocks the use of credentials in this case, but the behavior described in the following document is likely involved.</p>\n<div class=\"gatsby-highlight\" data-language=\"bash\"><pre class=\"language-bash\"><code class=\"language-bash\">Devices that use <span class=\"token number\">802</span>.1x wireless or wired networks, RDP, or VPN connections that rely on insecure protocols with password-based authentication cannot use SSO to sign in, and are forced to manually reauthenticate <span class=\"token keyword\">for</span> all new Windows sessions <span class=\"token keyword\">while</span> Credential Guard is running.</code></pre></div>\n<p>Reference: <a href=\"https://learn.microsoft.com/ja-jp/windows/security/identity-protection/credential-guard/considerations-known-issues#single-sign-on-for-network-services-breaks-after-upgrading-to-windows-11-version-22h2-or-windows-server-2025\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">Considerations and known issues when using Credential Guard | Microsoft Learn</a></p>\n<p>This time, I looked into ways to avoid this reauthentication during RDP connections and perform remote access more smoothly, so I am summarizing them here.</p>\n<!-- omit in toc -->\n<h2 id=\"contents\" style=\"position:relative;\"><a href=\"#contents\" aria-label=\"contents permalink\" class=\"anchor before\"><svg aria-hidden=\"true\" focusable=\"false\" height=\"16\" version=\"1.1\" viewBox=\"0 0 16 16\" width=\"16\"><path fill-rule=\"evenodd\" d=\"M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z\"></path></svg></a>Contents</h2>\n<ul>\n<li><a href=\"#workaround-1-use-the-microsoft-store-remote-desktop-app\">Workaround 1: Use the Microsoft Store remote desktop app</a></li>\n<li><a href=\"#workaround-2-register-generic-credentials-with-cmdkey\">Workaround 2: Register generic credentials with cmdkey</a></li>\n<li><a href=\"#summary\">Summary</a></li>\n</ul>\n<h2 id=\"workaround-1-use-the-microsoft-store-remote-desktop-app\" style=\"position:relative;\"><a href=\"#workaround-1-use-the-microsoft-store-remote-desktop-app\" aria-label=\"workaround 1 use the microsoft store remote desktop app permalink\" class=\"anchor before\"><svg aria-hidden=\"true\" focusable=\"false\" height=\"16\" version=\"1.1\" viewBox=\"0 0 16 16\" width=\"16\"><path fill-rule=\"evenodd\" d=\"M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z\"></path></svg></a>Workaround 1: Use the Microsoft Store remote desktop app</h2>\n<p>Apparently, this problem can be resolved by using the Microsoft Store version of the Remote Desktop app.</p>\n<p>When I actually tried it, using the Store version of Remote Desktop made it possible to automatically access the remote machine using credentials saved in the app.</p>\n<p>However, personally I do not like the Store app version of Remote Desktop because the scrolling behavior feels weird, so I decided not to adopt this method.</p>\n<h2 id=\"workaround-2-register-generic-credentials-with-cmdkey\" style=\"position:relative;\"><a href=\"#workaround-2-register-generic-credentials-with-cmdkey\" aria-label=\"workaround 2 register generic credentials with cmdkey permalink\" class=\"anchor before\"><svg aria-hidden=\"true\" focusable=\"false\" height=\"16\" version=\"1.1\" viewBox=\"0 0 16 16\" width=\"16\"><path fill-rule=\"evenodd\" d=\"M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z\"></path></svg></a>Workaround 2: Register generic credentials with cmdkey</h2>\n<p>The next workaround is to register generic credentials with <code class=\"language-text\">cmdkey</code>.</p>\n<p>Reference: <a href=\"https://learn.microsoft.com/ja-jp/windows-server/administration/windows-commands/cmdkey\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">cmdkey | Microsoft Learn</a></p>\n<p>If you save credentials in the traditional Remote Desktop client, those credentials are stored as <code class=\"language-text\">Windows Credentials</code>.</p>\n<p><span\n      class=\"gatsby-resp-image-wrapper\"\n      style=\"position: relative; display: block; margin-left: auto; margin-right: auto; max-width: 960px; \"\n    >\n      <a\n    class=\"gatsby-resp-image-link\"\n    href=\"/static/05a270462f80976806b297597be10497/b12f7/image-20250101223815507.png\"\n    style=\"display: block\"\n    target=\"_blank\"\n    rel=\"noopener\"\n  >\n    <span\n    class=\"gatsby-resp-image-background-image\"\n    style=\"padding-bottom: 54.166666666666664%; position: relative; bottom: 0; left: 0; background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAALCAYAAAB/Ca1DAAAACXBIWXMAAAsTAAALEwEAmpwYAAABxUlEQVQoz3WSTW/TQBCG/SvSOLkiwl8oTU5IaZQ0/5YLEgfEgUPVQw8ggUAVDaZO6q/Y613v2mu/zNhOpdDU8qNZz+688+F13kxeYTKZEK8xHrtwXRejkYvhcEh21FqXvsfjEe0NMRgMcHY2aO0pnIuLKc7P32I6nWJx+Q7z+Ryr1ZLWc1xdrbBYXGK1XGK9Xrd7fG42mz2D/YwjhEQU7RHHKXKpYIzG7jHBvRfA38XY/A2xDRLked6ilCIkpOzgNfs4zhgDByceVWhkuaYEBUSukGYCSnaBXIAsKhJTHeTLsgzW1m2s0zQNDtR153yIA3z/eYN9HFH1IXmap2TX3zy8/3yNj199fLj18OlHhJsHiy+/JTJVHgsyXYUFwsAja5CrAmVVo+wr2NJofm02uAsk7h4F7iMFL63wJzEwdO6o5U6wgS5rUMeUkVozDURhIbR9Svjs6f012ROCJJSm2G19bH0fuRD9Zk1v3Y7FWgvbrwXNkxMzRWlPC2qtkZIokyQJTFlScDfjAyyojIXU1IXu7Asto/2bYRi214TFSxJsmvpIkNFUEWN6W9kXBPl+RVHUVseVHG7A//DsuLq9rIiS5m3xD6IT+cjBIcUGAAAAAElFTkSuQmCC'); background-size: cover; display: block;\"\n  ></span>\n  <picture>\n          <source\n              srcset=\"/static/05a270462f80976806b297597be10497/8ac56/image-20250101223815507.webp 240w,\n/static/05a270462f80976806b297597be10497/d3be9/image-20250101223815507.webp 480w,\n/static/05a270462f80976806b297597be10497/e46b2/image-20250101223815507.webp 960w,\n/static/05a270462f80976806b297597be10497/52c2b/image-20250101223815507.webp 1020w\"\n              sizes=\"(max-width: 960px) 100vw, 960px\"\n              type=\"image/webp\"\n            />\n          <source\n            srcset=\"/static/05a270462f80976806b297597be10497/8ff5a/image-20250101223815507.png 240w,\n/static/05a270462f80976806b297597be10497/e85cb/image-20250101223815507.png 480w,\n/static/05a270462f80976806b297597be10497/d9199/image-20250101223815507.png 960w,\n/static/05a270462f80976806b297597be10497/b12f7/image-20250101223815507.png 1020w\"\n            sizes=\"(max-width: 960px) 100vw, 960px\"\n            type=\"image/png\"\n          />\n          <img\n            class=\"gatsby-resp-image-image\"\n            src=\"/static/05a270462f80976806b297597be10497/d9199/image-20250101223815507.png\"\n            alt=\"image-20250101223815507\"\n            title=\"image-20250101223815507\"\n            loading=\"lazy\"\n            style=\"width:100%;height:100%;margin:0;vertical-align:middle;position:absolute;top:0;left:0;\"\n          />\n        </picture>\n  </a>\n    </span></p>\n<p>By deleting those with <code class=\"language-text\">cmdkey</code> and re-registering them as <code class=\"language-text\">Generic Credencials</code>, it seems possible to avoid Credential Guard blocking during Remote Desktop and enable automatic logon.</p>\n<p>First, use the following command to check the currently registered credentials.</p>\n<div class=\"gatsby-highlight\" data-language=\"bash\"><pre class=\"language-bash\"><code class=\"language-bash\">cmdkey /list\n\n<span class=\"token operator\">></span>\nTarget: Domain:target<span class=\"token operator\">=</span>TERMSRV/192.168.10.10\nType: Domain Password\nUser: kash1064\nLocal machine persistence</code></pre></div>\n<p>Next, after deleting the existing credentials with the <code class=\"language-text\">delete</code> option, re-register the credentials as <code class=\"language-text\">Generic Credencials</code>.</p>\n<div class=\"gatsby-highlight\" data-language=\"bash\"><pre class=\"language-bash\"><code class=\"language-bash\">cmdkey /delete:TERMSRV/192.168.10.10\ncmdkey /generic:TERMSRV/192.168.10.10 /user:<span class=\"token operator\">&lt;</span>UserName<span class=\"token operator\">></span> /pass:<span class=\"token operator\">&lt;</span>Password<span class=\"token operator\">></span></code></pre></div>\n<p>Run the following command again to confirm that the credentials were registered, and then confirm that you can successfully perform remote access using the <code class=\"language-text\">.rdp</code> file.</p>\n<div class=\"gatsby-highlight\" data-language=\"bash\"><pre class=\"language-bash\"><code class=\"language-bash\">cmdkey /list\n\n<span class=\"token operator\">></span>\nTarget: LegacyGeneric:target<span class=\"token operator\">=</span>TERMSRV/192.168.10.10\nType: Generic\nUser: kash1064</code></pre></div>\n<h2 id=\"summary\" style=\"position:relative;\"><a href=\"#summary\" aria-label=\"summary permalink\" class=\"anchor before\"><svg aria-hidden=\"true\" focusable=\"false\" height=\"16\" version=\"1.1\" viewBox=\"0 0 16 16\" width=\"16\"><path fill-rule=\"evenodd\" d=\"M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z\"></path></svg></a>Summary</h2>\n<p>I do not know nearly enough about Windows credential management, so I could not dig deeply enough into why Credential Guard blocks the connection or why the workaround works. I would like to study authentication-related topics more as well.</p>","fields":{"slug":"/note-credential-rdp-en","tagSlugs":["/tag/notes/","/tag/windows/","/tag/english/"]},"frontmatter":{"date":"2025-01-01","description":"Workarounds for the issue where RDP connections using saved credentials are blocked by Credential Guard on Windows 11","tags":["Notes","Windows","English"],"title":"Workarounds for the Issue Where RDP Connections Using Saved Credentials Are Blocked by Credential Guard on Windows 11","socialImage":{"publicURL":"/static/bbf7b2fb834ddf65c9f511cf5027eca3/note-credential-rdp.png"}}}},"pageContext":{"slug":"/note-credential-rdp-en"}},"staticQueryHashes":["251939775","401334301","825871152"]}