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
function Trust-Certificate { | |
# Prompt the user to input the certificate's path | |
$certPath = Read-Host "Enter path to certificate" | |
# Create a new X.509 certificate object | |
$cert = New-Object System.Security.Cryptography.X509Certificates.X509Certificate2 | |
try { | |
# Import the certificate from the specified path | |
$cert.Import($certPath) |
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
## Displays a Message Box | |
Add-Type -AssemblyName PresentationFramework | |
[System.Windows.MessageBox]::Show('Checking App Log Files Complete','App Logs','OK','Information') |
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
function demo { | |
param ( | |
[parameter()] | |
[ValidateSet('v', 'n', 'r')] | |
[string]$Option = 'v' | |
) | |
switch ($Option) { | |
# hide PS version | |
'n' { | |
function global:prompt { "PS > " } |
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
$disks = Get-WmiObject win32_diskdrive ## Gets the list of disks | |
$partitions = Get-WmiObject win32_diskpartition ## Gets the list of partitions | |
## Defining Variables | |
$i = 0 | |
$partitionCount = 0 | |
$myTable = $null | |
## Scanning Disks and Partitions and their Sizes | |
foreach($disk in $disks) { |
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
## Displays a Message Box | |
Add-Type -AssemblyName PresentationFramework | |
[System.Windows.MessageBox]::Show('Checking App Log Files Complete','App Logs','OK','Information') |
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
@{ | |
Root = '' | |
OutputPath = '' | |
Package = @{ | |
Enabled = $true | |
Obfuscate = $false | |
HideConsoleWindow = $true | |
DotNetVersion = 'v4.6.2' | |
FileVersion = '1.0.0' | |
FileDescription = '' |
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
## Displays a Message Box | |
[System.Windows.Forms.Messagebox]::Show('Checking App Log Files Complete.','App Logs','OK','Information') |
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
# Get-LatestAppLog.ps1 | |
## Define the log file | |
$logDir = 'c:\temp' | |
$logFile = "$logDir\AppLog_$(Get-Date -format 'yyyy-mm-dd_hh-mm-ss-tt').xml" | |
## Get the ten latest application log events and export as an xml file | |
Get-WinEvent -LogName application -MaxEvents 10 | | |
Export-CliXml $logFile -Force |
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
Name | Description | List | Members | Due Date | Completed | Is Paid Task | Member Paid | Link | ||
---|---|---|---|---|---|---|---|---|---|---|
Forest and domain configuration | Documentation on how to manage Forest and Domain configuration | For Review | Zak Mason | Oct 23, 2020 02:00 PM | Yes | Yes | Yes | https://ImportTest.com/Domain-Configuration |