Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Duplicate Sec 4688 events outputted with ./target/release/hayabusa -M -d ../hayabusa-sample-evtx #729

Closed
hitenkoku opened this issue Oct 5, 2022 · 8 comments · Fixed by #733
Assignees
Labels
bug Something isn't working
Milestone

Comments

@hitenkoku
Copy link
Collaborator

    > `./target/release/hayabusa -M -d ../hayabusa-sample-evtx`で一番多いイベントはSec 4688で合っていますが、下の方をよく見たら、`Sec 4688: Unknown`2件も出ています。なぜ不明な`Sec 4688`が出ているのか分かりますか?
Screen Shot 2022-10-05 at 8 10 33 Screen Shot 2022-10-05 at 8 11 27

これを別issueにしますか? @hitenkoku

Originally posted by @YamatoSecurity in #728 (comment)

@hitenkoku hitenkoku self-assigned this Oct 5, 2022
@hitenkoku hitenkoku added invalid This doesn't seem right under-investigation under investigation to develop labels Oct 5, 2022
@hitenkoku hitenkoku added this to the v1.7.1 milestone Oct 5, 2022
@YamatoSecurity
Copy link
Collaborator

@hitenkoku 今思い出しましたが、チャンネル名がSecurityだったり、小文字のsecurityだったりする場合があるので、それで別のチャンネルとして集計されているかもしれません。集計する前にチャンネル名を全部小文字にしたらどうですか?

@hitenkoku
Copy link
Collaborator Author

基本は小文字で実施をしています。問題がないか念のため確認します

@hitenkoku
Copy link
Collaborator Author

確認が完了しました。ご指摘いただいた事項はMetrics実装の際に対応済みです

データ自体になにも存在しない可能性があり得るためもう少し解析します

@hitenkoku hitenkoku reopened this Oct 7, 2022
@YamatoSecurity YamatoSecurity changed the title Sec 4688: Unknown when execute ./target/release/hayabusa -M -d ../hayabusa-sample-evtx Duplicate Sec 4688 events outputted with ./target/release/hayabusa -M -d ../hayabusa-sample-evtx Oct 7, 2022
@hitenkoku
Copy link
Collaborator Author

Metricsですべてのレコード情報を出したところEventID 4688 の物自体が9712件となっていました。
そのすべてが"Security"チャンネルとなっていました。(なので一番上の正しく表示されているものしか存在しなかった)

集計の際に何かしら情報が残ってしまっている可能性があるためもう少し調査します

@hitenkoku
Copy link
Collaborator Author

確認が取れました。eventIDの情報を取得した際にダブルクォートも含んだ形で情報を管理していたことが原因でした。修正を行いpull-requestを出しておきます

@hitenkoku hitenkoku added bug Something isn't working and removed invalid This doesn't seem right under-investigation under investigation to develop labels Oct 8, 2022
hitenkoku added a commit that referenced this issue Oct 8, 2022
@hitenkoku
Copy link
Collaborator Author

@YamatoSecurity 対応が完了しました。イベントIDのキー名に一部ダブルクォートが入ってしまったことによる集計の誤りであることが確認できました。 #733 で修正したのでご確認ください。

@YamatoSecurity
Copy link
Collaborator

@hitenkoku 対応ありがとうございました!
ということで、普段のスキャン時でもイベントIDがダブルクォートに囲まれているせいで、IDが一致しなくて検知漏れが出ている可能性はありそうですか?もしあり得るのであれば、別のissueでイベントIDをチェックする前に全部ダブルクォートをtrimした方が良さそうですが、どう思いますか?

@hitenkoku
Copy link
Collaborator Author

@YamatoSecurity 可能性は否定できないです。ただ、今回問題となっている処理の関数に関連した処理は検知側のロジックでは利用していないため、確実に修正が必要とは判断できないです。
確認するとすれば今回の4688のダブルクォートが入っているレコードを特定させて、そのファイルに対して実行をするなどの検証が必要となります。

確認は必要だとは思いますので、一応調査用のissueを作っておきます。もし不要となればissueをcloseする方針にしようともいます

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
2 participants