Skip to content

Commit

Permalink
Removed binary files from the repository so template.iso was removed.…
Browse files Browse the repository at this point in the history
… README.md was edited to capture additional steps to make up for that and the fuzzer-master was edited to fix cases with iso fuzzing without a template file.
  • Loading branch information
Diane Dubois committed Jan 12, 2023
1 parent d79aa5d commit 8364fa2
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ All arguments are mandatory except the last 5 arguments:
- `HostIdaPath` is used to precompute the blocks' addresses on the target binary when no breakpoint list is found. It is though strongly advised to use the utilities to precompute the blocks beforehand and filter out unneeded blocks to keep the list minimal.
- The default max mutation rate for input files is 0.3.
- `MinInputSize` and `MaxInputSize` set limits for the corpus files. Default values: 100 and 4096.
- `VirtualDiskType` should be set if the fuzzer needs to run on mutated file systems (bi-dimensional fuzzing mode). The type should then be given as an argument: "vfd", "vhd", "iso", or a combination of those values in a list.
- `VirtualDiskType` should be set if the fuzzer needs to run on mutated file systems (bi-dimensional fuzzing mode). The type should then be given as an argument: "vfd", "vhd", "iso", or a combination of those values in a list. If iso is selected, a "template.iso" should be added to data.

### Running the fuzzer

Expand Down
14 changes: 12 additions & 2 deletions core/fuzzer-master.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -110,15 +110,25 @@ if ($VirtualDiskType) {
}
$fsGeneratorPath = Join-Path $ScriptPath "fs-generator.ps1"
if ($VirtualDiskType.GetType().Name -eq "String") {
Copy-Item "..\data\template.$VirtualDiskType" $fsCorpus
$fsTemplate = Join-Path $fsCorpus "template.$VirtualDiskType"
if (Test-Path -Path "..\data\template.$VirtualDiskType") {
Copy-Item "..\data\template.$VirtualDiskType" $fsCorpus
}
else {
New-Item -Path $fsTemplate -Value "Test" -ItemType File -Force > $null
}
$fscommand = "-HostOutputDir ""$HostOutputDir"" -VirtualDiskType $VirtualDiskType"
$fsGenPid = Start-HelperProcess -script $fsGeneratorPath -commandline $fscommand
} else {
$fsTemplate = New-Object System.Collections.ArrayList
$fscommands = New-Object System.Collections.ArrayList
foreach ($format in $VirtualDiskType) {
Copy-Item "..\data\template.$format" $fsCorpus
if (Test-Path -Path "..\data\template.$VirtualDiskType") {
Copy-Item "..\data\template.$format" $fsCorpus
}
else {
New-Item -Path (Join-Path $fsCorpus "template.$format") -Value "Test" -ItemType File -Force > $null
}
$fsTemplate.Add((Join-Path $fsCorpus "template.$format")) > $null
$fscommand = "-HostOutputDir ""$HostOutputDir"" -VirtualDiskType $format"
$fscommands.Add($fscommand) > $null
Expand Down
Binary file removed data/template.iso
Binary file not shown.

0 comments on commit 8364fa2

Please sign in to comment.