beagle.common package¶
Submodules¶
beagle.common.logging module¶
Module contents¶
-
beagle.common.
dedup_nodes
(nodes: List[beagle.nodes.node.Node]) → List[beagle.nodes.node.Node][source]¶ Deduplicates a list of nodes.
Parameters: nodes (List[Node]) – [description] Returns: [description] Return type: List[Node]
-
beagle.common.
split_path
(path: str) → Tuple[str, str][source]¶ Parse a full file path into a file name + extension, and directory at once. For example:
>>> split_path('c:\ProgramData\app.exe') (app.exe', 'c:\ProgramData')
By default, if it can’t split, it’ll return as the directory, and None as the image.
Parameters: path (str) – The path to parse Returns: A tuple of file name + extension, and directory at once. Return type: Tuple[str, str]
-
beagle.common.
split_reg_path
(reg_path: str) → Tuple[str, str, str][source]¶ Splits a full registry path into hive, key, and path.
Examples
>>> split_reg_path(\REGISTRY\MACHINE\SYSTEM\ControlSet001\Control\ComputerName) (REGISTRY, ComputerName, MACHINE\SYSTEM\ControlSet001\Control)
Parameters: regpath (str) – The full registry key Returns: Hive, registry key, and registry key path Return type: Tuple[str, str, str]