namespace SIGCM2.Infrastructure.Security;

public sealed class JwtOptions
{
    public string Issuer { get; set; } = "sigcm2.api";
    public string Audience { get; set; } = "sigcm2.web";
    public int AccessTokenMinutes { get; set; } = 60;
    public int RefreshTokenDays { get; set; } = 7;

    /// <summary>Path to private.pem file (dev). Used if PrivateKey is null.</summary>
    public string? PrivateKeyPath { get; set; }

    /// <summary>Path to public.pem file (dev). Used if PublicKey is null.</summary>
    public string? PublicKeyPath { get; set; }

    /// <summary>PEM content from env var (production). Takes precedence over file.</summary>
    public string? PrivateKey { get; set; }

    /// <summary>PEM content from env var (production). Takes precedence over file.</summary>
    public string? PublicKey { get; set; }
}
