changed Event ID Statistics wording to Metrics #706
This commit is contained in:
@@ -1,9 +1,9 @@
|
||||
use crate::detections::message::{LOGONSUMMARY_FLAG, STATISTICS_FLAG};
|
||||
use crate::detections::message::{LOGONSUMMARY_FLAG, METRICS_FLAG};
|
||||
use crate::detections::{detection::EvtxRecordInfo, utils};
|
||||
use hashbrown::HashMap;
|
||||
|
||||
#[derive(Debug)]
|
||||
pub struct EventStatistics {
|
||||
pub struct EventMetrics {
|
||||
pub total: usize,
|
||||
pub filepath: String,
|
||||
pub start_time: String,
|
||||
@@ -14,7 +14,7 @@ pub struct EventStatistics {
|
||||
/**
|
||||
* Windows Event Logの統計情報を出力する
|
||||
*/
|
||||
impl EventStatistics {
|
||||
impl EventMetrics {
|
||||
pub fn new(
|
||||
total: usize,
|
||||
filepath: String,
|
||||
@@ -22,8 +22,8 @@ impl EventStatistics {
|
||||
end_time: String,
|
||||
stats_list: HashMap<String, usize>,
|
||||
stats_login_list: HashMap<String, [usize; 2]>,
|
||||
) -> EventStatistics {
|
||||
EventStatistics {
|
||||
) -> EventMetrics {
|
||||
EventMetrics {
|
||||
total,
|
||||
filepath,
|
||||
start_time,
|
||||
@@ -34,8 +34,8 @@ impl EventStatistics {
|
||||
}
|
||||
|
||||
pub fn evt_stats_start(&mut self, records: &[EvtxRecordInfo]) {
|
||||
// 引数でstatisticsオプションが指定されている時だけ、統計情報を出力する。
|
||||
if !*STATISTICS_FLAG {
|
||||
// 引数でmetricsオプションが指定されている時だけ、統計情報を出力する。
|
||||
if !*METRICS_FLAG {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
use crate::detections::message::{LOGONSUMMARY_FLAG, STATISTICS_FLAG};
|
||||
use crate::detections::message::{LOGONSUMMARY_FLAG, METRICS_FLAG};
|
||||
use crate::detections::{configs::CONFIG, detection::EvtxRecordInfo};
|
||||
use prettytable::{Cell, Row, Table};
|
||||
|
||||
use super::statistics::EventStatistics;
|
||||
use super::statistics::EventMetrics;
|
||||
use hashbrown::HashMap;
|
||||
|
||||
#[derive(Debug)]
|
||||
pub struct Timeline {
|
||||
pub stats: EventStatistics,
|
||||
pub stats: EventMetrics,
|
||||
}
|
||||
|
||||
impl Default for Timeline {
|
||||
@@ -26,7 +26,7 @@ impl Timeline {
|
||||
let statsloginlst = HashMap::new();
|
||||
|
||||
let statistic =
|
||||
EventStatistics::new(totalcnt, filepath, starttm, endtm, statslst, statsloginlst);
|
||||
EventMetrics::new(totalcnt, filepath, starttm, endtm, statslst, statsloginlst);
|
||||
Timeline { stats: statistic }
|
||||
}
|
||||
|
||||
@@ -36,7 +36,7 @@ impl Timeline {
|
||||
}
|
||||
|
||||
pub fn tm_stats_dsp_msg(&mut self) {
|
||||
if !*STATISTICS_FLAG {
|
||||
if !*METRICS_FLAG {
|
||||
return;
|
||||
}
|
||||
// 出力メッセージ作成
|
||||
|
||||
Reference in New Issue
Block a user