1
0
mirror of https://github.com/bitwarden/mobile synced 2026-01-18 00:13:16 +00:00

feat: add support for credProps.rk extension (#3132)

This commit is contained in:
Andreas Coroiu
2024-04-03 17:52:39 +02:00
committed by GitHub
parent 86368c57ef
commit ceca142c65
8 changed files with 136 additions and 14 deletions

View File

@@ -0,0 +1,9 @@
namespace Bit.Core.Utilities.Fido2.Extensions
{
#nullable enable
public class Fido2CreateCredentialExtensionsParams
{
public bool CredProps { get; set; } = false;
}
}

View File

@@ -0,0 +1,9 @@
namespace Bit.Core.Utilities.Fido2.Extensions
{
#nullable enable
public class Fido2CreateCredentialExtensionsResult
{
public Fido2CredPropsResult? CredProps { get; set; }
}
}

View File

@@ -0,0 +1,9 @@
namespace Bit.Core.Utilities.Fido2.Extensions
{
#nullable enable
public class Fido2CredPropsResult
{
public bool? Rk { get; set; } = false;
}
}

View File

@@ -36,7 +36,7 @@ namespace Bit.Core.Utilities.Fido2
/// The effective user verification preference for assertion, provided by the client.
/// </summary>
public Fido2UserVerificationPreference UserVerificationPreference { get; set; }
/// <summary>
/// CTAP2 authenticators support setting this to false, but we only support the WebAuthn authenticator model which does not have that option.
/// </summary>

View File

@@ -1,6 +1,8 @@
using Bit.Core.Utilities.Fido2.Extensions;
namespace Bit.Core.Utilities.Fido2
{
#nullable enable
#nullable enable
/// <summary>
/// Parameters for creating a new credential.
@@ -42,9 +44,8 @@ namespace Bit.Core.Utilities.Fido2
/// <summary>
/// This member contains additional parameters requesting additional processing by the client and authenticator.
/// Not currently supported.
/// </summary>
public object? Extensions { get; set; }
public Fido2CreateCredentialExtensionsParams? Extensions { get; set; }
/// <summary>
/// This member contains information about the desired properties of the credential to be created.

View File

@@ -1,3 +1,5 @@
using Bit.Core.Utilities.Fido2.Extensions;
namespace Bit.Core.Utilities.Fido2
{
/// <summary>
@@ -15,5 +17,6 @@ namespace Bit.Core.Utilities.Fido2
public byte[] PublicKey { get; set; }
public int PublicKeyAlgorithm { get; set; }
public string[] Transports { get; set; }
public Fido2CreateCredentialExtensionsResult Extensions { get; set; }
}
}