「[[マイクロソフト系技術情報 Wiki>http://techinfoofmicrosofttech.osscons.jp/]]」は、「[[Open棟梁Project>https://github.com/OpenTouryoProject/]]」,「[[OSSコンソーシアム .NET開発基盤部会>https://www.osscons.jp/dotNetDevelopmentInfrastructure/]]」によって運営されています。 -戻る --[[FIDO2]] --[[Microsoft Passport]] * 目次 [#t997f2c6] #contents *概要 [#oe736650] [[FIDO]] 2.0 の Web Application用 JavaScript Library。 **サポート状況 [#d26348bb] ***ブラウザ [#zd5347d5] -Microsoft Edge~ 早期ドラフトの実装 (ms-prefix実装)。 -Chrome -Firefox -Safari ***認証器 [#l10ca068] -Embedded Authenticator (利用 Device に付随した認証) に限定 -External Authenticator (外部 Device による認証) は将来対応予定 *API [#e44e4639] -Web Authentication API で使用する (主な) 関数は 2 つだけ。 -W3C で定義されている API の名前空間は --window.webauthn.[[makeCredential>#ed03528a]] --window.webauthn.[[getAssertion>#vb05a7a9]] **仕様 [#c9b811f4] ***ドラフト [#a8e59cb8] -現在はドラフト仕様に基づく ms-prefix実装であるため、~ 現在 (2016/05 時点) の Edge の実装では、明示的に下記を使用。 --window.msCredentials.[[makeCredential>#ed03528a]] --window.msCredentials.[[getAssertion>#vb05a7a9]] ***[[Polyfill>https://dotnetdevelopmentinfrastructure.osscons.jp/index.php?JavaScript#me2ddef5]] [#z9c36841] -[[webauthn.js>#x7fbdb40]]という[[Polyfill>https://dotnetdevelopmentinfrastructure.osscons.jp/index.php?JavaScript#me2ddef5]]を使用すると良い。 ***Promise [#c3481199] [[Promise>https://dotnetdevelopmentinfrastructure.osscons.jp/index.php?JavaScript#j2209b5b]]で実装されている。 **メソッド [#z9b20aaa] ***makeCredential()メソッド [#ed03528a] 初回の key pair の作成 -private key の (Device への) 登録 -public key の取得 ([[JWK>JWT]] format) ***getAssertion()メソッド [#vb05a7a9] private key を用いた challenge data のデジタル署名 *補足 [#x49db2e9] -(現時点で)以下に値が入ってこない。 --result.algorithm --result.attestation -PKIのキーペアは、CredentialIDを使用して、紐付けを行う模様。 --このキーペアは、[[AIK(認証IDキー)>TPM(Trusted Platform Module)#e8431d17]]だと思われる。 --従って、CredentialIDには、認証器が生成した値を使用する必要がある。 --なので、実装に注意が必要(あるサンプルコードは失敗する)。~ https://github.com/OpenTouryoProject/MultiPurposeAuthSite/issues/50#issuecomment-336858649 --なお、CredentialIDを使用すれば、複数のデバイスの登録が可能。~ しかし、デバイスを特定する方法が無いので、登録が重複してしまう。 *参考 [#b22f8c0c] **Yubico [#m94f60dc] -New NIST Authentication Guidelines for Public Safety and First Responders~ https://www.yubico.com/2018/05/new-nist-authentication-guidelines-for-public-safety-and-first-responders/ **microsoft.com [#z2da3470] -Web Authentication API 紹介 (Windows Hello を使った Edge 開発) – Tsmatz~ https://blogs.msdn.microsoft.com/tsmatsuz/2016/06/08/w3c-web-authentication-api-javascript/ -Dev guide: Web authentication - Microsoft Edge Development~ https://developer.microsoft.com/en-us/microsoft-edge/platform/documentation/dev-guide/device/web-authentication/ -A world without passwords: Windows Hello in Microsoft Edge - Microsoft Edge Dev BlogMicrosoft Edge Dev Blog~ https://blogs.windows.com/msedgedev/2016/04/12/a-world-without-passwords-windows-hello-in-microsoft-edge/ ***API リファレンス [#x65290df] -Web Authentication~ https://msdn.microsoft.com/en-us/library/mt697638.aspx --MSCredentials object~ https://msdn.microsoft.com/en-us/library/mt697639.aspx ---makeCredential method~ https://msdn.microsoft.com/en-us/library/mt697641.aspx ---getAssertion method~ https://msdn.microsoft.com/en-us/library/mt697640.aspx ***adrianba/fido-snippets [#x7fbdb40] -polyfill --webauthn.js~ https://github.com/adrianba/fido-snippets/blob/master/polyfill/webauthn.js --polyfill.html~ https://github.com/adrianba/fido-snippets/blob/master/polyfill/polyfill.html -csharp/app.cs~ https://github.com/adrianba/fido-snippets/blob/master/csharp/app.cs **しばやん雑記 [#t7f57b1c] -Windows Hello を Web で使うための Web Authentication API (FIDO 2.0) について調べた ~ http://blog.shibayan.jp/entry/20170129/1485665985 -ASP.NET Core Identity に Windows Hello を使ったログイン機能を追加する~ http://blog.shibayan.jp/entry/20170131/1485844075 --shibayan/webauthn-aspnet-demo: Demo Application for Windows Hello (Web Authn API)~ https://github.com/shibayan/webauthn-aspnet-demo ***Views [#vf27ef62] -Manage/AddPublicKey.cshtml~ https://github.com/shibayan/webauthn-aspnet-demo/blob/master/src/WebAuthnDemo/Views/Manage/AddPublicKey.cshtml -Account/Login.cshtml~ https://github.com/shibayan/webauthn-aspnet-demo/blob/master/src/WebAuthnDemo/Views/Account/Login.cshtml ***Controllers [#ddeef527] -AccountController.cs~ https://github.com/shibayan/webauthn-aspnet-demo/blob/master/src/WebAuthnDemo/Controllers/AccountController.cs#L149 -ManageController.cs~ https://github.com/shibayan/webauthn-aspnet-demo/blob/master/src/WebAuthnDemo/Controllers/ManageController.cs#L127 ***Services [#jd6b7233] -FidoAuthenticator.cs~ https://github.com/shibayan/webauthn-aspnet-demo/blob/master/src/WebAuthnDemo/Services/FidoAuthenticator.cs **FIDO2.0対応 - Open 棟梁 Wiki [#r622885f] https://opentouryo.osscons.jp/index.php?FIDO2.0%E5%AF%BE%E5%BF%9C ---- Tags: [[:認証基盤]]