[성현모] ProxyKMS 컨피그, 패킷 클래스 추가

This commit is contained in:
SHM
2025-12-24 11:42:59 +09:00
parent e2c367961a
commit 31f3079ead
7 changed files with 335 additions and 2 deletions

View File

@ -1,4 +1,6 @@
using Microsoft.AspNetCore.Mvc;
using System.Text.Json;
using WebApi.Project.ProxyKMS.Models;
namespace WebApi.Project.ProxyKMS.Controllers
{
@ -21,6 +23,21 @@ namespace WebApi.Project.ProxyKMS.Controllers
[HttpGet(Name = "GetWeatherForecast")]
public IEnumerable<WeatherForecast> Get()
{
MasterEcuKey.Response_SupplierKeyProvisioning res = new MasterEcuKey.Response_SupplierKeyProvisioning();
res.ResultMessage = "";
res.ResultStatus = "";
res.ResultReason = "";
res.Records.M1 = "M11";
res.Records.M2 = "M22";
res.Records.M3 = "M33";
res.Records.M4 = "M44";
res.Records.M5 = "M55";
res.Records.KeyID = "key";
var serialize = JsonSerializer.Serialize(res, new JsonSerializerOptions() { WriteIndented = true });
var desObj = JsonSerializer.Deserialize<MasterEcuKey.Response_SupplierKeyProvisioning>(serialize);
return Enumerable.Range(1, 5).Select(index => new WeatherForecast
{
Date = DateOnly.FromDateTime(DateTime.Now.AddDays(index)),