identifiers.py
ofrak_ghidra.components.identifiers
GhidraAnalysisIdentifier (Identifier)
Component to identify resources to analyze with Ghidra. If this component is discovered, it will tag all Programs as GhidraProjects
identify(self, resource, config=None)
async
Perform identification on the given resource.
Users should not call this method directly; rather, they should run Resource.identify.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
resource |
Resource |
required | |
config |
Optional config for identifying. If an implementation provides a default, this default will always be used when config would otherwise be None. Note that a copy of the default config will be passed, so the default config values cannot be modified persistently by a component run. |
None |
Source code in ofrak_ghidra/components/identifiers.py
async def identify(self, resource: Resource, config=None):
for tag in _GHIDRA_AUTO_LOADABLE_FORMATS:
if resource.has_tag(tag):
resource.add_tag(GhidraAutoLoadProject)
return
resource.add_tag(GhidraCustomLoadProject)