-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implemented base hash value transformation
- Loading branch information
1 parent
fdf85e1
commit 3dd942d
Showing
3 changed files
with
64 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
from ..kusto_common.transformations import BaseHashesValuesTransformation | ||
|
||
|
||
class ProcessCreateHashesValuesTransformation(BaseHashesValuesTransformation): | ||
""" | ||
Transforms the Hashes field in imProcessCreate table to get rid of the hash algorithm prefix in each value. | ||
""" | ||
|
||
def __init__(self): | ||
super().__init__(valid_hash_algos=["MD5", "SHA1", "SHA256", "SHA512", "IMPHASH"], field_prefix="TargetProcess") | ||
|
||
|
||
class FileEventHashesValuesTransformation(BaseHashesValuesTransformation): | ||
""" | ||
Transforms the Hashes field in imFileEvent table to get rid of the hash algorithm prefix in each value. | ||
""" | ||
|
||
def __init__(self): | ||
super().__init__(valid_hash_algos=["MD5", "SHA1", "SHA256", "SHA512"], field_prefix="TargetFile") | ||
|
||
|
||
class WebSessionHashesValuesTransformation(BaseHashesValuesTransformation): | ||
""" | ||
Transforms the Hashes field in imWebSession table to get rid of the hash algorithm prefix in each value. | ||
""" | ||
|
||
def __init__(self): | ||
super().__init__(valid_hash_algos=["MD5", "SHA1", "SHA256", "SHA512"], field_prefix="File") |