< Summary - Heimdall API

Information
Class: ArturRios.Heimdall.Command.Input.VerifyTwoFactorAuthCommand
Assembly: ArturRios.Heimdall.Command
File(s): /home/runner/work/heimdall-api/heimdall-api/src/Application/ArturRios.Heimdall.Command/Input/VerifyTwoFactorAuthCommand.cs
Line coverage
100%
Covered lines: 3
Uncovered lines: 0
Coverable lines: 3
Total lines: 24
Line coverage: 100%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage
100%
Covered methods: 3
Fully covered methods: 3
Total methods: 3
Method coverage: 100%
Full method coverage: 100%

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
get_ChallengeToken()100%11100%
get_Code()100%11100%
get_RecoveryCode()100%11100%

File(s)

/home/runner/work/heimdall-api/heimdall-api/src/Application/ArturRios.Heimdall.Command/Input/VerifyTwoFactorAuthCommand.cs

#LineLine coverage
 1using ArturRios.Mediator.Command;
 2
 3namespace ArturRios.Heimdall.Command.Input;
 4
 5/// <summary>
 6///     Intent to complete a 2FA-gated login (UC-38) by redeeming the challenge token AF-11g issued at
 7///     login, together with either an app/email code or a recovery code. Carries no acting-person
 8///     identity — the caller holds no bearer token yet, only the challenge token, submitted here as
 9///     a plain request body field rather than an <c>Authorization</c> header (FR-2F-10) — the same
 10///     "opaque token as a body value" shape <see cref="ResetPasswordCommand" />'s <c>Token</c> uses.
 11///     The person the challenge names is resolved from <see cref="ChallengeToken" /> itself, inside
 12///     the handler.
 13/// </summary>
 14public class VerifyTwoFactorAuthCommand : BaseCommand
 15{
 16    /// <summary>The short-lived challenge token AF-11g returned from <c>POST /api/auth/login</c>.</summary>
 60017    public string ChallengeToken { get; set; } = string.Empty;
 18
 19    /// <summary>The caller's current app or email code, when proving a code rather than a recovery code.</summary>
 36820    public string? Code { get; set; }
 21
 22    /// <summary>One of the caller's unused recovery codes, when no code is available.</summary>
 49023    public string? RecoveryCode { get; set; }
 24}