Add signal contracts for reachability, exploitability, trust, and unknown symbols
- Introduced `ReachabilityState`, `RuntimeHit`, `ExploitabilitySignal`, `ReachabilitySignal`, `SignalEnvelope`, `SignalType`, `TrustSignal`, and `UnknownSymbolSignal` records to define various signal types and their properties. - Implemented JSON serialization attributes for proper data interchange. - Created project files for the new signal contracts library and corresponding test projects. - Added deterministic test fixtures for micro-interaction testing. - Included cryptographic keys for secure operations with cosign.
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
namespace StellaOps.Gateway.WebService;
|
||||
|
||||
/// <summary>
|
||||
/// Static configuration for a gateway node.
|
||||
/// </summary>
|
||||
public sealed class GatewayNodeConfig
|
||||
{
|
||||
/// <summary>
|
||||
/// Gets the region where this gateway is deployed (e.g., "eu1").
|
||||
/// Routing decisions use this value; it is never derived from headers or URLs.
|
||||
/// </summary>
|
||||
public required string Region { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets the unique identifier for this gateway node (e.g., "gw-eu1-01").
|
||||
/// </summary>
|
||||
public required string NodeId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets the environment name (e.g., "prod", "staging", "dev").
|
||||
/// </summary>
|
||||
public required string Environment { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets the neighbor regions for fallback routing, in order of preference.
|
||||
/// </summary>
|
||||
public IReadOnlyList<string> NeighborRegions { get; init; } = [];
|
||||
}
|
||||
13
src/Gateway/StellaOps.Gateway.WebService/Program.cs
Normal file
13
src/Gateway/StellaOps.Gateway.WebService/Program.cs
Normal file
@@ -0,0 +1,13 @@
|
||||
var builder = WebApplication.CreateBuilder(args);
|
||||
|
||||
// Placeholder: Gateway services will be registered here in later sprints
|
||||
|
||||
var app = builder.Build();
|
||||
|
||||
// Placeholder: Middleware pipeline will be configured here in later sprints
|
||||
app.MapGet("/health", () => Results.Ok(new { status = "healthy" }));
|
||||
|
||||
app.Run();
|
||||
|
||||
// Make Program class accessible for integration tests
|
||||
public partial class Program { }
|
||||
@@ -0,0 +1,13 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk.Web">
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net10.0</TargetFramework>
|
||||
<LangVersion>preview</LangVersion>
|
||||
<Nullable>enable</Nullable>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\__Libraries\StellaOps.Router.Common\StellaOps.Router.Common.csproj" />
|
||||
<ProjectReference Include="..\..\__Libraries\StellaOps.Router.Config\StellaOps.Router.Config.csproj" />
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
Reference in New Issue
Block a user