-
Notifications
You must be signed in to change notification settings - Fork 72
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
79 additions
and
0 deletions.
There are no files selected for viewing
13 changes: 13 additions & 0 deletions
13
packages/ida.plugin.lighthouse.vm/ida.plugin.lighthouse.vm.nuspec
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,13 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<package xmlns="http://schemas.microsoft.com/packaging/2015/06/nuspec.xsd"> | ||
<metadata> | ||
<id>ida.plugin.lighthouse.vm</id> | ||
<version>0.9.3</version> | ||
<description>Lighthouse is a powerful code coverage explorer for IDA Pro and Binary Ninja, providing software researchers with uniquely interactive controls to study execution maps for native applications without requiring symbols or source.</description> | ||
<authors>gaasedelen</authors> | ||
<dependencies> | ||
<dependency id="common.vm" /> | ||
<dependency id="libraries.python3.vm" version="0.0.0.20230927" /> | ||
</dependencies> | ||
</metadata> | ||
</package> |
51 changes: 51 additions & 0 deletions
51
packages/ida.plugin.lighthouse.vm/tools/chocolateyinstall.ps1
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,51 @@ | ||
$ErrorActionPreference = 'Stop' | ||
Import-Module vm.common -Force -DisableNameChecking | ||
|
||
try { | ||
# Download the plugin | ||
$toolName = "lighthouse" | ||
$toolVersion = "0.9.3" | ||
$toolDir = Join-Path ${Env:chocolateyPackageFolder} "temp_$([guid]::NewGuid())" | ||
$toolUrl = "https://github.com/gaasedelen/lighthouse/archive/refs/tags/v0.9.3.zip" | ||
$toolSha256 = "b9f1888827f68d69672d1202783b47f7603fb80f42f9b70edeb9349d40c4f33c" | ||
$packageArgs = | ||
@{ | ||
packageName = ${Env:ChocolateyPackageName} | ||
unzipLocation = $toolDir | ||
url = $toolUrl | ||
checksum = $toolSha256 | ||
checksumType = "sha256" | ||
} | ||
Install-ChocolateyZipPackage @packageArgs | ||
|
||
# Install the plugin | ||
$pluginsDir = New-Item "$Env:APPDATA\Hex-Rays\IDA Pro\plugins" -ItemType "directory" -Force | ||
$pluginFile = Join-Path $toolDir "$toolName-$toolVersion\plugins\lighthouse_plugin.py" -Resolve | ||
$pluginDir = Join-Path $toolDir "$toolName-$toolVersion\plugins\lighthouse" -Resolve | ||
Copy-Item $pluginFile -Destination $pluginsDir -Force | ||
Copy-Item $pluginDir -Destination $pluginsDir -Force -Recurse | ||
|
||
# Remove the temp installation folder | ||
Remove-Item $toolDir -Recurse | ||
|
||
# Install the code coverage binaries | ||
$toolName = "CodeCoverage" | ||
$zipUrl = "https://github.com/gaasedelen/lighthouse/releases/download/v$toolVersion/CodeCoverage-v$toolVersion-98830.zip" | ||
$zipSha256 = "5b3e9659e934f8d7f4751cc0e20aa76de28822bc4f28b4936aa9be9c9e108595" | ||
|
||
$toolDir = Join-Path ${Env:RAW_TOOLS_DIR} $toolName | ||
|
||
# Download and unzip | ||
$packageArgs = @{ | ||
packageName = $toolName | ||
unzipLocation = $toolDir | ||
url = $zipUrl | ||
checksum = $zipSha256 | ||
checksumType = "sha256" | ||
} | ||
Install-ChocolateyZipPackage @packageArgs | ||
VM-Assert-Path $toolDir | ||
} catch { | ||
VM-Write-Log-Exception $_ | ||
} | ||
|
15 changes: 15 additions & 0 deletions
15
packages/ida.plugin.lighthouse.vm/tools/chocolateyuninstall.ps1
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,15 @@ | ||
$ErrorActionPreference = 'Continue' | ||
Import-Module vm.common -Force -DisableNameChecking | ||
|
||
$pluginsDir = "$Env:APPDATA\Hex-Rays\IDA Pro\plugins" | ||
|
||
# Uninstall plugin | ||
$pluginFile = Join-Path $pluginsDir "lighthouse_plugin.py" | ||
$pluginDir = Join-Path $pluginsDir "lighthouse" | ||
Remove-Item $pluginFile | ||
Remove-Item $pluginDir -Recurse | ||
|
||
# Uninstall the code coverage binaries | ||
$toolName = "CodeCoverage" | ||
$toolDir = Join-Path ${Env:RAW_TOOLS_DIR} $toolName | ||
Remove-Item $toolDir -Recurse |