Update TGBeta.ps1
This commit is contained in:
60
TGBeta.ps1
60
TGBeta.ps1
@@ -653,20 +653,20 @@ function GetHtmlContent {
|
|||||||
<!-- Right column -->
|
<!-- Right column -->
|
||||||
<div class="checkbox-group column" id="rightColumn" >
|
<div class="checkbox-group column" id="rightColumn" >
|
||||||
<label>
|
<label>
|
||||||
<input type="checkbox" class="right-checkbox" name="installtemp1" id="installtemp1Checkbox">
|
<input type="checkbox" class="right-checkbox" name="EnableBitLocker" id="installtemp1Checkbox">
|
||||||
Installtemp1
|
Enable Bitlocker
|
||||||
</label>
|
</label>
|
||||||
<label>
|
<label>
|
||||||
<input type="checkbox" class="right-checkbox" name="installtemp2" id="installtemp2Checkbox">
|
<input type="checkbox" class="right-checkbox" name="EdgeDefaultSearchEngine" id="installtemp2Checkbox">
|
||||||
Install temp2
|
Set Edge Default Search Engine
|
||||||
</label>
|
</label>
|
||||||
<!-- Add more checkboxes here -->
|
<!-- Add more checkboxes here -->
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="n8nPasswordContainer" style="display: none;">
|
<div id="n8nPasswordContainer" style="display: none;">
|
||||||
<label for="n8nPassword">Enter n8n Password:</label><br>
|
<label for="n8nPassword">Enter Password:</label><br>
|
||||||
<input type="password" id="n8nPassword" class="password-input" placeholder="Enter N8N Password">
|
<input type="password" id="n8nPassword" class="password-input" placeholder="Enter Password">
|
||||||
</div>
|
</div>
|
||||||
<br>
|
<br>
|
||||||
<div id="DattoRMMContainer" style="display: none;">
|
<div id="DattoRMMContainer" style="display: none;">
|
||||||
@@ -1387,7 +1387,7 @@ try {
|
|||||||
$responseString = "Method not allowed. Use GET."
|
$responseString = "Method not allowed. Use GET."
|
||||||
$response.StatusCode = 405
|
$response.StatusCode = 405
|
||||||
}
|
}
|
||||||
$buffer = [System.Text.Encoding]::UTF8.GetBytes($responseString)
|
$buffer = [System.Text.Encoding]::UTF8.GetBytes($responseString)
|
||||||
$response.ContentType = "text/plain"
|
$response.ContentType = "text/plain"
|
||||||
$response.ContentLength64 = $buffer.Length
|
$response.ContentLength64 = $buffer.Length
|
||||||
$response.OutputStream.Write($buffer, 0, $buffer.Length)
|
$response.OutputStream.Write($buffer, 0, $buffer.Length)
|
||||||
@@ -1482,8 +1482,7 @@ try {
|
|||||||
|
|
||||||
"/installSVSWatchtower" {
|
"/installSVSWatchtower" {
|
||||||
if ($request.HttpMethod -eq "GET") {
|
if ($request.HttpMethod -eq "GET") {
|
||||||
Install-SVSWatchtower
|
try {
|
||||||
try {
|
|
||||||
Install-SVSWatchtower
|
Install-SVSWatchtower
|
||||||
$responseString = "Install SVSWatchtower triggered successfully."
|
$responseString = "Install SVSWatchtower triggered successfully."
|
||||||
$response.StatusCode = 200
|
$response.StatusCode = 200
|
||||||
@@ -1502,6 +1501,49 @@ try {
|
|||||||
$response.OutputStream.Close()
|
$response.OutputStream.Close()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
"/EdgeDefaultSearchEngine"
|
||||||
|
if ($request.HttpMethod -eq "GET") {
|
||||||
|
try {
|
||||||
|
Set-EdgeDefaultSearchEngine.ps1
|
||||||
|
$responseString = " Set Edge Default Search Engine triggered successfully."
|
||||||
|
$response.StatusCode = 200
|
||||||
|
} catch {
|
||||||
|
$responseString = "Error triggering Install SVSWatchtower: $_"
|
||||||
|
$response.StatusCode = 500
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
$responseString = "Method not allowed. Use GET."
|
||||||
|
$response.StatusCode = 405
|
||||||
|
}
|
||||||
|
$buffer = [System.Text.Encoding]::UTF8.GetBytes($responseString)
|
||||||
|
$response.ContentType = "text/plain"
|
||||||
|
$response.ContentLength64 = $buffer.Length
|
||||||
|
$response.OutputStream.Write($buffer, 0, $buffer.Length)
|
||||||
|
$response.OutputStream.Close()
|
||||||
|
}
|
||||||
|
|
||||||
|
"/EnableBitLocker"
|
||||||
|
if ($request.HttpMethod -eq "GET") {
|
||||||
|
try {
|
||||||
|
Set-SVSBitLocker -Mode Enable -DriveLetter C -SaveToRegistry $true
|
||||||
|
$responseString = " Set Edge Default Search Engine triggered successfully."
|
||||||
|
$response.StatusCode = 200
|
||||||
|
} catch {
|
||||||
|
$responseString = "Error triggering Install SVSWatchtower: $_"
|
||||||
|
$response.StatusCode = 500
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
$responseString = "Method not allowed. Use GET."
|
||||||
|
$response.StatusCode = 405
|
||||||
|
}
|
||||||
|
$buffer = [System.Text.Encoding]::UTF8.GetBytes($responseString)
|
||||||
|
$response.ContentType = "text/plain"
|
||||||
|
$response.ContentLength64 = $buffer.Length
|
||||||
|
$response.OutputStream.Write($buffer, 0, $buffer.Length)
|
||||||
|
$response.OutputStream.Close()
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
"/offboard" {
|
"/offboard" {
|
||||||
if ($request.HttpMethod -eq "POST") {
|
if ($request.HttpMethod -eq "POST") {
|
||||||
try {
|
try {
|
||||||
|
|||||||
Reference in New Issue
Block a user