From 5903f86ac5e96f12073f9693654ec8b10a514ec0 Mon Sep 17 00:00:00 2001 From: "Namhyeon, Go" Date: Fri, 12 Apr 2024 18:45:01 +0900 Subject: [PATCH] some fixes --- .../Helper/FileExtensionDB.cs | 37 +++++++++++++++++++ .../Model/AndroidPermission.cs | 1 + Catswords.DataType.Client/Model/FileHash.cs | 6 ++- Catswords.DataType.Client/Model/Indicator.cs | 1 + 4 files changed, 44 insertions(+), 1 deletion(-) diff --git a/Catswords.DataType.Client/Helper/FileExtensionDB.cs b/Catswords.DataType.Client/Helper/FileExtensionDB.cs index 0d9685d..b836baf 100644 --- a/Catswords.DataType.Client/Helper/FileExtensionDB.cs +++ b/Catswords.DataType.Client/Helper/FileExtensionDB.cs @@ -38,6 +38,16 @@ namespace Catswords.DataType.Client.Helper // 각 아이템을 반복하며 정보 출력 foreach (XmlNode itemNode in itemList) { + // organization + Indicators.Add(new Indicator() + { + Id = itemNode.SelectSingleNode("id").InnerText, + CreatedAt = GetDateTimeFromString(itemNode.SelectSingleNode("datetime").InnerText), + Content = "This format published by " + itemNode.SelectSingleNode("organization").InnerText, + Url = "" + }); + + // description Indicators.Add(new Indicator() { Id = itemNode.SelectSingleNode("id").InnerText, @@ -45,6 +55,33 @@ namespace Catswords.DataType.Client.Helper Content = itemNode.SelectSingleNode("description").InnerText, Url = "" }); + + // content + Indicators.Add(new Indicator() + { + Id = itemNode.SelectSingleNode("id").InnerText, + CreatedAt = GetDateTimeFromString(itemNode.SelectSingleNode("datetime").InnerText), + Content = itemNode.SelectSingleNode("content").InnerText, + Url = "" + }); + + // openwith + Indicators.Add(new Indicator() + { + Id = itemNode.SelectSingleNode("id").InnerText, + CreatedAt = GetDateTimeFromString(itemNode.SelectSingleNode("datetime").InnerText), + Content = "Open with " + itemNode.SelectSingleNode("openwith").InnerText, + Url = "" + }); + + // first reported + Indicators.Add(new Indicator() + { + Id = itemNode.SelectSingleNode("id").InnerText, + CreatedAt = GetDateTimeFromString(itemNode.SelectSingleNode("datetime").InnerText), + Content = "This format first seen on " + GetDateTimeFromString(itemNode.SelectSingleNode("datetime").InnerText).ToString(), + Url = "" + }); } } catch (Exception ex) diff --git a/Catswords.DataType.Client/Model/AndroidPermission.cs b/Catswords.DataType.Client/Model/AndroidPermission.cs index ec89c49..47b940e 100644 --- a/Catswords.DataType.Client/Model/AndroidPermission.cs +++ b/Catswords.DataType.Client/Model/AndroidPermission.cs @@ -8,5 +8,6 @@ namespace Catswords.DataType.Client.Model public string Description { get; set; } public int Severity { get; set; } public DateTime CreatedAt { get; set; } + public DateTime UpdatedAt { get; set; } } } diff --git a/Catswords.DataType.Client/Model/FileHash.cs b/Catswords.DataType.Client/Model/FileHash.cs index 1d18f2c..472274b 100644 --- a/Catswords.DataType.Client/Model/FileHash.cs +++ b/Catswords.DataType.Client/Model/FileHash.cs @@ -1,4 +1,6 @@ -namespace Catswords.DataType.Client.Model +using System; + +namespace Catswords.DataType.Client.Model { public class FileHash { @@ -11,5 +13,7 @@ public string SHA256 { get; set; } public string InfoHash { get; set; } public string SSDEEP { get; set; } + public DateTime CreatedAt { get; set; } + public DateTime UpdatedAt { get; set; } } } \ No newline at end of file diff --git a/Catswords.DataType.Client/Model/Indicator.cs b/Catswords.DataType.Client/Model/Indicator.cs index 38f5110..0e51ba8 100644 --- a/Catswords.DataType.Client/Model/Indicator.cs +++ b/Catswords.DataType.Client/Model/Indicator.cs @@ -8,5 +8,6 @@ namespace Catswords.DataType.Client.Model public string Content { get; set; } public string Url { get; set; } public DateTime CreatedAt { get; set; } + public DateTime UpdatedAt { get; set; } } }