This repository has been archived by the owner on Nov 7, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 450
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #17 from DrDonk/dev
4.2.0 Release
- Loading branch information
Showing
37 changed files
with
770 additions
and
300 deletions.
There are no files selected for viewing
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
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
Binary file not shown.
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
Binary file not shown.
Binary file not shown.
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 |
---|---|---|
@@ -1,10 +1,38 @@ | ||
#!/usr/bin/env bash | ||
#!/usr/bin/env zsh | ||
#set -x | ||
|
||
echo Building release executables | ||
if ! [ $# -eq 1 ] ; then | ||
echo "Product version not found" >&2 | ||
exit 1 | ||
fi | ||
|
||
pushd ./commands/check | ||
echo "Building check" | ||
go-winres make --arch amd64 --product-version $1 --file-version $1 | ||
env GOOS=windows GOARCH=amd64 go build -o ../../dist/windows | ||
env GOOS=linux GOARCH=amd64 go build -o ../../dist/linux | ||
rm rsrc_windows_amd64.syso | ||
popd | ||
|
||
pushd ./commands/relock | ||
echo "Building relock" | ||
go-winres make --arch amd64 --product-version $1 --file-version $1 | ||
env GOOS=windows GOARCH=amd64 go build -o ../../dist/windows | ||
env GOOS=linux GOARCH=amd64 go build -o ../../dist/linux | ||
rm rsrc_windows_amd64.syso | ||
popd | ||
|
||
pushd ./commands/unlock | ||
echo "Building unlock" | ||
go-winres make --arch amd64 --product-version $1 --file-version $1 | ||
env GOOS=windows GOARCH=amd64 go build -o ../../dist/windows | ||
env GOOS=linux GOARCH=amd64 go build -o ../../dist/linux | ||
rm rsrc_windows_amd64.syso | ||
popd | ||
|
||
echo Building Windows executables... | ||
env GOOS=windows GOARCH=amd64 go build -o ./windows/dumpsmc.exe ./tools/dumpsmc.go | ||
env GOOS=windows GOARCH=amd64 go build -o ./windows/unlocker.exe ./command/unlocker.go | ||
|
||
echo Building Linux executables... | ||
env GOOS=linux GOARCH=amd64 go build -o ./linux/dumpsmc ./tools/dumpsmc.go | ||
env GOOS=linux GOARCH=amd64 go build -o ./linux/unlocker ./command/unlocker.go | ||
cp -v LICENSE ./dist | ||
cp -v *.md ./dist | ||
cp -v *.pdf ./dist | ||
cp -vr ./iso ./dist |
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,9 @@ | ||
#!/usr/bin/env zsh | ||
#set -x | ||
echo Clean distribution | ||
rm -vfr ./dist | ||
mkdir -vp ./dist/iso | ||
mkdir -vp ./dist/linux | ||
mkdir -vp ./dist/windows | ||
|
||
rm -vfr ./commands/rsrc_windows_amd64.syso |
This file was deleted.
Oops, something went wrong.
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,61 @@ | ||
// | ||
// SPDX-FileCopyrightText: © 2014-2022 David Parsons | ||
// SPDX-License-Identifier: MIT | ||
|
||
package main | ||
|
||
import ( | ||
"fmt" | ||
"github.com/drdonk/golocker/vmwpatch" | ||
"os" | ||
) | ||
|
||
func waitExit() { | ||
quiet := os.Getenv("UNLOCK_QUIET") | ||
if quiet != "1" { | ||
fmt.Println() | ||
fmt.Println("\nPress Enter key to continue...") | ||
|
||
_, _ = fmt.Scanln() | ||
} | ||
} | ||
|
||
func main() { | ||
// Titles | ||
fmt.Printf("Checker %s for VMware Workstation/Player\n", vmwpatch.VERSION) | ||
fmt.Println("============================================") | ||
fmt.Println(vmwpatch.COPYRIGHT) | ||
fmt.Println() | ||
|
||
// Check admin rights | ||
if !vmwpatch.IsAdmin() { | ||
fmt.Println("Re-run with admin/root privileges") | ||
waitExit() | ||
return | ||
} | ||
|
||
// Get VMware product details from registry and file system | ||
v := vmwpatch.VMWInfo() | ||
if v.ProductVersion != "" { | ||
fmt.Println("VMware is installed at: ", v.InstallDir) | ||
fmt.Println("VMware version: ", v.BuildNumber) | ||
} else { | ||
fmt.Println("VMware is not installed on this computer") | ||
waitExit() | ||
return | ||
} | ||
patchFlag, patchStatus, hash256 := vmwpatch.IsSMCPatched(v.PathVMXDefault) | ||
fmt.Printf("Patch Status: %s (%d)\nSHA256: %s\n", patchStatus, patchFlag, hash256) | ||
|
||
patchFlag, patchStatus, hash256 = vmwpatch.IsSMCPatched(v.PathVMXDebug) | ||
fmt.Printf("Patch Status: %s (%d)\nSHA256: %s\n", patchStatus, patchFlag, hash256) | ||
|
||
patchFlag, patchStatus, hash256 = vmwpatch.IsSMCPatched(v.PathVMXStats) | ||
fmt.Printf("Patch Status: %s (%d)\nSHA256: %s\n", patchStatus, patchFlag, hash256) | ||
|
||
patchFlag, patchStatus, hash256 = vmwpatch.IsGOSPatched(v.PathVMwareBase) | ||
fmt.Printf("Patch Status: %s (%d)\nSHA256: %s\n", patchStatus, patchFlag, hash256) | ||
|
||
waitExit() | ||
return | ||
} |
Oops, something went wrong.