-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added GUI Installer files for Windows Installation
- Loading branch information
Showing
6 changed files
with
46 additions
and
0 deletions.
There are no files selected for viewing
Binary file not shown.
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 |
---|---|---|
@@ -0,0 +1,32 @@ | ||
import subprocess | ||
|
||
# Define the PowerShell script content | ||
powershell_script = "FDETurbo-Enabling BitLocker and Full Disk Encryption" | ||
$Drive = "C:" | ||
$RecoveryKeyPath = "C:\\RecoveryKey.txt" | ||
|
||
$BitLockerStatus = Get-BitLockerVolume -MountPoint $Drive | ||
|
||
if ($BitLockerStatus.ProtectionStatus -eq 'Off') { | ||
Enable-BitLocker -MountPoint $Drive -RecoveryKeyPath $RecoveryKeyPath -EncryptionMethod Aes256 -UsedSpaceOnly | ||
Write-Host "BitLocker encryption has been initiated on $Drive." | ||
} else { | ||
Write-Host "BitLocker is already enabled on $Drive." | ||
} | ||
""" | ||
|
||
# Save the PowerShell script to a temporary .ps1 file | ||
script_path = "C:\\temp\\EnableBitLocker.ps1" | ||
with open(script_path, "w") as script_file: | ||
script_file.write(powershell_script) | ||
|
||
# Execute the PowerShell script | ||
try: | ||
result = subprocess.run(["powershell", "-ExecutionPolicy", "Bypass", "-File", script_path], capture_output=True, text=True) | ||
|
||
# Print the output and any errors | ||
print("Output:\n", result.stdout) | ||
print("Errors:\n", result.stderr) | ||
|
||
except Exception as e: | ||
print(f"An error occurred: {e}") |
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,14 @@ | ||
# Define the drive to encrypt and the location to save the recovery key | ||
$Drive = "C:" | ||
$RecoveryKeyPath = "C:\RecoveryKey.txt" # Change this to your desired recovery key path | ||
|
||
# Check if BitLocker is already enabled | ||
$BitLockerStatus = Get-BitLockerVolume -MountPoint $Drive | ||
|
||
if ($BitLockerStatus.ProtectionStatus -eq 'Off') { | ||
Enable-BitLocker -MountPoint $Drive -RecoveryKeyPath $RecoveryKeyPath -EncryptionMethod Aes256 -UsedSpaceOnly | ||
|
||
Write-Host "BitLocker encryption has been initiated on $Drive." | ||
} else { | ||
Write-Host "BitLocker is already enabled on $Drive." | ||
} |
Binary file not shown.