Skip to content

Instantly share code, notes, and snippets.

View adbertram's full-sized avatar

Adam Bertram adbertram

View GitHub Profile
<script>
var contentsTitle = "Table of Contents"; // Set your title here, to avoid making a heading for it later
var ToC = "<h2>"+contentsTitle+"</h2>";
ToC += "<nav role='navigation' class='table-of-contents'><ul>";
var first = false;
$("h2,h3").each(function() {
var el = $(this);
if (first === false) {
first = true;
$('<span id="dynamictoc"></span>').insertBefore(el);
## Script.zip has iis_setup.ps1 inside
## iis_setup.ps1
Configuration iis_setup {
Param ( [string] $nodeName = 'localhost' )
Import-DscResource -ModuleName PSDesiredStateConfiguration
<?xml version='1.0' encoding='UTF-8'?>
<feed xmlns='http://www.w3.org/2005/Atom' xmlns:apps='http://schemas.google.com/apps/2006'>
<title>Mail Filters</title>
<updated>2019-10-23T14:41:44Z</updated>
<entry>
<category term='filter'></category>
<title>Mail Filter</title>
<id>tag:mail.google.com,2008:filter:1487958749986</id>
<updated>2019-10-23T14:41:44Z</updated>
<content></content>
{
"$schema": "http://schema.management.azure.com/schemas/2018-05-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"webAppName": {
"type": "string"
},
"sqlDbName": {
"type": "string"
}
Matching: powershell
Excluding: Sharepoint Obfuscation obfuscator Payload mimikittenz exploits blackhat cybersec pentest metasploit exploit exploitation #pentesting penetration attack attacks trojan obfuscation pen hijacking logitech malware phishing infosec virus ransomware powerops offensive bsides reverse empire mimikatz
function Save-ConsoleOutputToClipBoard {
[OutputType('string')]
[CmdletBinding()]
param
()
if ($host.Name -ne ‘ConsoleHost’) {
write-host -ForegroundColor Red "This script runs only in the console host. You cannot run this script in $($host.Name)."
}
Start-UDDashboard -Wait -Dashboard (
New-UDDashboard -Title "Hello, Azure" -Content {
New-UDCard -Title "Hello, Azure"
}
)
$scriptblock = {
New-UdGrid -Title 'Courses' -DefaultSortColumn 'Completion Deadline' -Headers @('Name', 'Completion Deadline', 'Stage Name') -Properties @('Name', 'Completion Deadline', 'Stage Name') -Endpoint {
$params = @{
BaseIdentity = 'Courses'
function Debug-Error {
[OutputType([void])]
[CmdletBinding()]
param
()
$action = {
if ($_ -and ($stacktrace -notmatch '^\s*at System\.Management\.Automation\.ExceptionHandlingOps\.CheckActionPreference') -and ($stacktrace -notmatch '^\s*at System\.Management\.Automation\.MshCommandRuntime\.ThrowTerminatingError\(ErrorRecord errorRecord\)\s*$')) {
break
}
## Test file
Set-Content -Path 'foo.txt' -Value 'This is a test file'
## Run any command and pipe to my fictional function
Get-Content -Path C:\foo.txt -Raw | Copy-CommandToClipBoard
## When pasting from the clipboard, it would look like this
Get-Content -Path C:\foo.txt -Raw
This is a test file
PowerShell lang:en-us -Sharepoint -Obfuscation -obfuscator -Payload -mimikittenz -exploits -blackhat -cybersec -pentest -metasploit -exploit -exploitation -#pentesting -penetration -attack -attacks -trojan -obfuscation -pen -hijacking -logitech -malware -phishing -infosec -virus -ransomware -powerops -offensive