katana.units.stego.zsteg — Run zsteg¶
Extract hidden data with zsteg
This unit will extract hidden data file using the zsteg
command-line utility. The syntax runs as:
zsteg <arguments> <target_path>
This unit will use only preselected arguments to search with zsteg.
This saves processing time, and still seems to find the majority of flags.
The unit inherits from katana.unit.FileUnit to ensure the target
is a PNG file.
Note
zsteg only works with PNG files!
-
class
katana.units.stego.zsteg.Unit(*args, **kwargs) Bases:
katana.unit.FileUnit-
DEPENDENCIES= ['zsteg'] Depends on the binary “zsteg”. This must be in your PATH for this unit to run.
-
GROUPS= ['stego', 'image', 'zsteg'] These are “tags” for a unit. Considering it is a Stego unit, “stego” is included, as well as the tag “image”, and the name of the unit itself, “zsteg”.
-
PRIORITY= 40 Priority works with 0 being the highest priority, and 100 being the lowest priority. 50 is the default priorty. This unit has a slightly higher priority of 40.
-
enumerate() → Generator[Any, None, None] This will loop through a set of pre-defined arguments for
zstegto run with.Returns: Generator of zstegarguments
-
evaluate(case: Any) → None Evaluate the target. Run
zstegon the target and recurse on any newfound information.Parameters: case – A case returned by enumerate. For this unit, thecaseis an argument to use forzsteg.Returns: None. This function should not return any data.
-
-
katana.units.stego.zsteg.permutations= ['b1,rgb,lsb,xy', 'b1,r,lsb,xy', 'b1,rgb,msb,yx', 'b2,rgb,lsb,yx', 'b2,rgb,lsb,xy', 'b1,rgba,lsb,xy', 'b1,r,lsb,xy', 'b1,rgba,msb,yx', 'b2,rgba,lsb,yx', 'b2,rgba,lsb,xy', 'b1,rgb,lsb,xy'] This is a pre-defined list of argument to use with
zsteg. These options tend to find flags hidden with the LSB steganography technique.