Skip to content

Instantly share code, notes, and snippets.

Avatar
🎯
Focusing

John Steele camusicjunkie

🎯
Focusing
  • Germany
View GitHub Profile
View One Dark Pro tweaks
"editor.tokenColorCustomizations": {
"[One Dark Pro]": {
"textMateRules": [
{
"scope": [
"punctuation.definition.variable.powershell",
"support.variable.automatic",
"support.constant.variable",
"variable.language"
],
View Iron Scripter 2
$files = gci -Recurse -File
$files | measure -Property length -Sum -Average | select @{n = 'ComputerName'; e = {$env:COMPUTERNAME}}, Count, Sum, Average, @{n = 'Date'; e = {Get-Date}}
View Iron Scripter Cryptogram
$crypto = @"
P k T r 2 s z 2 * c F -
r a z 7 G u D 4 w 6 U #
g c t K 3 E @ B t 1 a Y
Q P i c % 7 0 5 Z v A e
W 6 j e P R f p m I ) H
y ^ L o o w C n b J d O
S i 9 M b e r # ) i e U
* f 2 Z 6 M S h 7 V u D
5 a ( h s v 8 e l 1 o W
View Description XML 2
$Description = '<root>' + $xml.benchmark.group[0].rule.description + '</root>'
View Description XML
'<VulnDiscussion>Inadequate physical protection can undermine all
other security precautions utilized to protect the system. This can
jeopardize the confidentiality, availability, and integrity of the
system. Physical security is the first line of protection of any syst
em.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives><
/FalseNegatives><Documentable>false</Documentable><Mitigations></Mitig
ations><SeverityOverrideGuidance></SeverityOverrideGuidance><Potential
Impacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><Mitigat
ionControl></MitigationControl><Responsibility></Responsibility><IACon
trols></IAControls>'
View New-DynamicParameter.ps1
Function New-DynamicParameter {
[cmdletbinding()]
param(
[Parameter(Mandatory)]
[ValidateNotNullOrEmpty()]
[string] $Name,
[string[]] $ValidateSet,
View Invoke-ScanState.ps1
function Invoke-ScanState {
[cmdletbinding(DefaultParameterSetName = 'StorePath')]
param(
[Parameter(ParameterSetName = 'StorePath',
Position = 0)]
[string] $StorePath = 'C:\Backup',
[Parameter(ParameterSetName = 'StorePath')]
View Get-ComputerStats
function Get-ComputerStats {
<#
.SYNOPSIS
Gets computer and disk information
.DESCRIPTION
Gets computer information and disk information for all
logical disks. Each disk is added as part of the other
properties for as many type 3 disks that exist
View Get-MonitorInfo.ps1
function Get-MonitorInfo {
<#
.SYNOPSIS
Gets computer and monitor information
.DESCRIPTION
Gets computer information and monitor information for all
connected monitors. Each monitor is numbered for as many
monitors as you have connected
You can’t perform that action at this time.