Skip to content

Instantly share code, notes, and snippets.

🔒
SECURE ALL THE MACHINES!!

Joe Garcia, CISSP infamousjoeg

🔒
SECURE ALL THE MACHINES!!
Block or report user

Report or block infamousjoeg

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@infamousjoeg
infamousjoeg / UnpackForSickRage.ps1
Created Nov 7, 2016
PowerShell script created to finish the unpack process started by SickRage, but normally failing -- this simplifies the mass moving to their final homes.
View UnpackForSickRage.ps1
# VARIABLES
$i = 0
$x = 0
$dirList = Get-ChildItem -Directory
$seasonArr = @{"00" = "Season 00";"01" = "Season 01";"02" = "Season 02";"03" = "Season 03";`
"04" = "Season 04";"05" = "Season 05";"06" = "Season 06";"07" = "Season 07";`
"08" = "Season 08";"09" = "Season 09"}
# EXECUTION
foreach ($dir in $dirList) {
@infamousjoeg
infamousjoeg / deps.pp
Created Nov 10, 2016 — forked from rcrowley/deps.pp
Deploying Django with Puppet
View deps.pp
stage { "pre": before => Stage["main"] }
class python {
package {
"build-essential": ensure => latest;
"python": ensure => "2.6.6-2ubuntu1";
"python-dev": ensure => "2.6.6-2ubuntu1";
"python-setuptools": ensure => "latest";
}
exec { "easy_install pip":
path => "/usr/local/bin:/usr/bin:/bin",
@infamousjoeg
infamousjoeg / site.pp
Created Nov 10, 2016
The following short manifest manages NTP. It uses package, file, and service resources; a case statement based on a fact; variables; ordering and notification relationships; and file contents being served from a module.
View site.pp
case $operatingsystem {
centos, redhat: { $service_name = 'ntpd' }
debian, ubuntu: { $service_name = 'ntp' }
}
package { 'ntp':
ensure => installed,
}
service { 'ntp':
@infamousjoeg
infamousjoeg / disable-dep.nfo
Created Nov 13, 2016
Central Policy Manager (CPM) - Disable DEP from Command Prompt (Admin)
View disable-dep.nfo
bcdedit /set nx alwaysoff
View aim_example.bat
@echo off
REM Declare and set variables
set Admin_ID=Svc_CyberArkREST
set AIM_AppID=AIM-CP-Test
set AIM_Safe=T-APP-CYBR-RESTAPI
REM Make sure the Object Name is the "Name" value of the account stored in EPV
set AIM_Object=Operating System-WinDomain-joe-garcia.local-Svc_CyberArkREST
REM Set AIM CP CLI command to run
View KeepAlive.au3
Opt("GuiOnEventMode",1)
Opt("TrayOnEventMode",1)
Opt("TrayMenuMode",1); no default tray menuitems
#NoTrayIcon
#include <GUIConstants.au3>
Global $infolabel
Global $sleepTime
Global $pause = 1
@infamousjoeg
infamousjoeg / DNA2PUU.ps1
Last active Oct 5, 2017
v0.2b - Convert DNA Results to PUU passwords.csv
View DNA2PUU.ps1
#####################################################
#
# DNA2PUU.ps1
#
# Converts DNA Results to passwords.csv format for
# Password Upload Utility Bulk Upload
#
# Version 0.2b
#
# Joe Garcia, CyberArk Software
@infamousjoeg
infamousjoeg / PASRESTFunctions.ps1
Last active Jun 22, 2017
REST API PowerShell Functions List
View PASRESTFunctions.ps1
# REST API PowerShell Functions List
# Last Updated: 6/21/2017
#
# Be sure to set $PVWA_URL to be global like: $Global:PVWA_URL="https://pvwa.cyberark.local"
# before calling any functions.
#
# Before each function are three (3) # and the RESTful Method it is an example of.
# Any of those functions can be copied and used as a template for other functions
# to be created that are not listed here. If you want to add PASREST-AddAccount,
# you would copy a POST example below and modify accordingly. But don't do that,
@infamousjoeg
infamousjoeg / CreateTestUsers.ps1
Created Mar 31, 2017
Create 1,000 Test Users for Home Lab
View CreateTestUsers.ps1
Import-Module ActiveDirectory
$total = 1000
for ($userIndex=0; $userIndex -lt $total; $userIndex++)
{
$userID = "{0:0000}" -f ($userIndex + 1)
$userName = "test.user$userID"
Write-Host "Creating user" ($userIndex + 1) "of" $total ":" $userName
@infamousjoeg
infamousjoeg / AIMAutoLogon.bat
Last active Sep 29, 2017
SysInternals AutoLogon via AIM
View AIMAutoLogon.bat
set scmd="C:\Program Files\CyberArk\ApplicationPasswordSdk\CLIPasswordSDK.exe" password /p AppDescs.AppID=AUTOLOGON /p query=Safe=AutoLogon_Accounts;Folder=Root;object=Workstation01 /p RequiredProps=Address,UserName /o PassProps.UserName,PassProps.Address,Password
for /f "tokens=1,2,3 delims=," %%A in ('"%scmd%"') do autologon %%A %%B %%C
You can’t perform that action at this time.