Skip to main content
Advanced Search
Search Terms
Content Type

Exact Matches
Tag Searches
Date Options
Updated after
Updated before
Created after
Created before

Search Results

502 total results found

Distribution Lists

M365 - One Liners

Azure Powershell Module Cheatsheet

Azure - Cheatsheet

# Azure Product Azure CLI Example CLI PowerShell Module Example PS 1 Syntax az   PowerShell uses a verb-noun pair for the names of cmdlets   2 Log in to Azure az login az login -u johndoe@contoso.com -p VerySecret Az.Accounts ...

Email Management

M365 - One Liners

While loops

Bash - Cheatsheet

Run for period of time #!/bin/bash runtime="5 minute" endtime=$(date -ud "$runtime" +%s) while [[ $(date -u +%s) -le $endtime ]] do echo "Time Now: `date +%H:%M:%S`" echo "Sleeping for 10 seconds" sleep 10 done Resource: https://www.g...

Bugs

Outlook

For loops

Bash - Cheatsheet

Compute md5sum for every item in a directory for i in "$(ls)"; do md5sum "${i}"; done | sort Print 1 through 10 for COUNT in $(seq 1 10); do echo $COUNT sleep 1 done Read data into an array and loop over it mapfile -t buckets < <(aws s3 ls | grep t...

LAPS

Active Directory - Walkthroughs

SSH

Bash - Cheatsheet

Encrypt Key openssl rsa -des3 -in key.pem -out encrypted-key.pem # Enter a passphrase mv encrypted-key.pem key.pem chmod 400 key.pem Decrypt Key openssl rsa -in key.pem -out key.open.pem # Enter the passphrase used to encrypt the ke mv key.open.pem key...

Sleeping Bear Dunes

Vacation Destinations

Create sudo user non-interactively

Bash - Cheatsheet

Skip the prompts that come with creating a user typically, and give them sudoers privileges. Replace ${USERNAME} with the user you want to create. # The man page explanation for --gecos isn't that intuitive IMO # Basically specifying --gecos "" states you do...

Day 5 - Manisitique

Central UP Trip - KM and DB

Run function as another user

Bash - Cheatsheet

export -f <function_name> su <user to run function as> -c "bash -c <function_name>"  

Day 1 - St. Ignace, Sault Ste. Marie and Whitefish Point

Central UP Trip - KM and DB

Run command as another user

Bash - Cheatsheet

USER=centos runuser -l $USER -c 'whoami' Resource: https://devops.stackexchange.com/questions/10402/running-a-command-as-a-specific-user-on-an-ec2-using-ssm

Day 6 - Boyne Mountain and Crystal Mountain

Central UP Trip - KM and DB

New Page

Bash - Cheatsheet Unsorted

Exit-on-error mode Put this at the top of your bash script: set -e. If a command returns a nonzero status, the shell will exit. Resources: https://unix.stackexchange.com/questions/97101/how-to-catch-an-error-in-a-linux-bash-script http://linuxcommand.org/lc3...

Day 2 - Munising

Central UP Trip - KM and DB

Create Test Detections

Crowdstrike - Cheatsheet

Original Article We have several test detections that can be run to verify the Falcon sensor is sending detections back to the cloud and that they are being received in a timely manner. If you have a SOC that receives and responds to alerts, it would be advi...