using System.Text.Json.Serialization;
namespace StellaOps.Policy.Determinization.Evidence;
///
/// EPSS (Exploit Prediction Scoring System) evidence.
///
public sealed record EpssEvidence
{
///
/// CVE identifier.
///
[JsonPropertyName("cve")]
public required string Cve { get; init; }
///
/// EPSS score [0.0, 1.0].
/// Probability of exploitation in the next 30 days.
///
[JsonPropertyName("epss")]
public required double Epss { get; init; }
///
/// EPSS percentile [0.0, 1.0].
///
[JsonPropertyName("percentile")]
public required double Percentile { get; init; }
///
/// When this EPSS value was published (UTC).
///
[JsonPropertyName("published_at")]
public required DateTimeOffset PublishedAt { get; init; }
///
/// EPSS model version.
///
[JsonPropertyName("model_version")]
public string? ModelVersion { get; init; }
///
/// Convenience property returning the EPSS score.
/// Alias for for API compatibility.
///
[JsonIgnore]
public double Score => Epss;
}