Skip to content

Instantly share code, notes, and snippets.

View mark05e's full-sized avatar

mark05E mark05e

View GitHub Profile
@colindix
colindix / O365search.ps1
Created July 5, 2018 02:37
Search O365 mailboxes for badness
# Get login credentials
$UserCredential = Get-Credential
$psOption = New-PSSessionOption -ProxyAccessType IEConfig -ProxyAuthentication Negotiate
$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://ps.compliance.protection.outlook.com/powershell-liveid -Credential $UserCredential -Authentication Basic -AllowRedirection -SessionOption $psOption
Import-PSSession $Session -AllowClobber -DisableNameChecking
$searchQry = '(Subject:<YOUR SUBJECT HERE) AND (Received:today)' #KQL https://msdn.microsoft.com/library/ee558911(v=office.15).aspx
$compName = "20180514-01-MalwareEmails"
@blackcater
blackcater / diagrams.md
Created July 6, 2018 16:45
Markdown Diagrams

Diagrams

Markdown Preview Enhanced supports rendering flow charts, sequence diagrams, mermaid, PlantUML, WaveDrom, GraphViz, Vega & Vega-lite, Ditaa diagrams. You can also render TikZ, Python Matplotlib, Plotly and all sorts of other graphs and diagrams by using Code Chunk.

Please note that some diagrams don't work well with file exports such as PDF, pandoc, etc.

Flow Charts

This feature is powered by flowchart.js.

@tanaikech
tanaikech / submit.md
Last active May 20, 2025 20:41
Adding Query Parameters to URL using Google Apps Script

Adding Query Parameters to URL using Google Apps Script

Updated on February 5, 2024

This is for adding the query parameters to the URL. These scripts can be also used for Javascript. When I created an endpoint with some query parameters, I had used the scripts of various patterns every time. Today, I prepared this sample script to unify them. If this is also useful for you, I'm glad.

Sample script (With V8 runtime):

String.prototype.addQuery = function (obj) {
@scotgabriel
scotgabriel / Windows-Compromised-System-EventLog-checks.ps1
Created August 2, 2018 22:20
"Compromised System" eventlog checks
# github username: gabe31415
# events compiled from: https://docs.microsoft.com/en-us/windows-server/identity/ad-ds/plan/appendix-l--events-to-monitor
# NOTES:
# get-winevent has an UNDOCUMENTED id list max of '23' events, therefore i chose to just loop through
# one event at a time
# Get OS version
$wmiOS = Get-WmiObject -Class Win32_OperatingSystem
@idleberg
idleberg / scoop.md
Last active October 29, 2025 06:48
Scoop Aliases

Common aliases for the scoop package manager

# Install app
scoop alias add i 'scoop install $args[0]' 'Install app'
scoop alias add add 'scoop install $args[0]' 'Install app'

# Uninstall app
scoop alias add rm 'scoop uninstall $args[0]' 'Uninstall an app'
scoop alias add remove 'scoop uninstall $args[0]' 'Uninstall an app'
@AveYo
AveYo / .. MediaCreationTool.bat ..md
Last active December 22, 2025 07:20
Universal MediaCreationTool wrapper for all MCT Windows 10 versions - MOVED TO github.com/AveYo/MediaCreationTool.bat
@ColonelBuendia
ColonelBuendia / overlay.ahk
Created October 15, 2018 04:47
[Overlay] Context sensitive help menu in autohotkey with same button activate and kill #ahk #overlay
#IfWinActive ahk_class AutoHotkeyGUI
Esc::GUI,Destroy
Capslock::GUI,Destroy
return
#IfWinActive
#IfWinActive ahk_class XLMAIN
Capslock::
SetCapslockState, Off
Gui, Add, Text,YM,
@chrisfcarroll
chrisfcarroll / Uninstall-Programs-Or-Features.ps1
Last active May 24, 2025 10:13
PowerShell commandline Uninstall-Programs-Or-Features.ps1
<#
.SYNOPSIS
Uninstall one or more Windows Program or Feature, by name or regular expression.
.DESCRIPTION
Lists Programs And Features installed on the current machine which match
the -matchingName parameter and then, after force or confirmation, uninstalls them.
Examples
@ericoporto
ericoporto / trabalho_canada.txt
Created October 29, 2018 01:21
Stuff about jobs in canada
##Job Search & Staffing Services
www.careerbuilder.ca
www.6figures.com
www.acsess.org
www.adecco.ca
www.allstarjobs.ca
www.auto-jobs.ca
www.bestjobsca.com
www.bridges.com
@tjelen
tjelen / zerotier-ubuntu-gateway.md
Last active August 30, 2025 08:45
Zerotier: Setting up the default gateway in Ubuntu Linux

Zerotier Ubuntu config notes

Setting up the default gateway (for VPN tunelling)

Ubuntu 18.04 UFW settings, based on [1] Step 1

  • ens3 .. primary physical ETH interface
  • 10.243.0.0/16 .. ZT network