View EncryptDecryptWebConfig.md

Encrypt Command

C:\WINDOWS\Microsoft.NET\Framework\<.Net Version Folder>\aspnet_regiis.exe -pef "<Secton to encrypt in Web.Config>" "<Path to Web.Config>" -prov "DataProtectionConfigurationProvider"

Decrypt Command

C:\WINDOWS\Microsoft.NET\Framework\<.Net Version Folder>\aspnet_regiis.exe -pdf "<Secton to decrypt in Web.Config>" "<Path to Web.Config>"

Note: Only certain sections can be encrypted.

View aim-ccp-nodejs.js
var http = require("https");
var options = {
"method": "GET",
"hostname": "pvwa.cyberark.local",
"port": "443",
"path": "/AIMWebService/api/Accounts?AppID=AIM-CCP-Test&Safe=T-APP-CYBR-RESTAPI-TESTADD1&Folder=Root&Object=Operating%20System-WinDomain-cyberark.local-Svc_CyberArkREST",
"headers": {
"content-type": "application/json",
"cache-control": "no-cache",
View install_chef_automate.sh
#!/bin/bash
apt-get update
apt-get -y install curl
chef_server_fqdn=$1
# create downloads directory
if [ ! -d /downloads ]; then
mkdir /downloads
fi
View install_chef_server.sh
#!/bin/bash
apt-get update
apt-get -y install curl
chef_automate_fqdn=$1
# create staging directories
if [ ! -d /drop ]; then
mkdir /drop
fi
View AIMCCP-CurlRest.sh
curl -k 'https://components.joe-garcia.local/AIMWebService/api/Accounts?AppID=AIM-CCP-Test&Safe=T-APP-CYBR-RESTAPI&Folder=Root&Object=Operating%20System-WinDomain-joe-garcia.local-Svc_CyberArkREST'
View AIMCCP-PowerShell.ps1
function Get-AIMPassword ([string]$PVWA_URL, [string]$AppID, [string]$Safe, [string]$ObjectName) {
# Declaration
$fetchAIMPassword = "${PVWA_URL}/AIMWebService/api/Accounts?AppID=${AppID}&Safe=${Safe}&Folder=Root&Object=${ObjectName}"
# Execution
try {
$response = Invoke-RestMethod -Uri $fetchAIMPassword -Method GET -ContentType "application/json" -ErrorVariable aimResultErr
Return $response.content
}
View machineID.sh
## Machine identity Example (-k due to self-signed cert on Conjur Master)
token=hostfactorytokenvalue
hostid="jenkins/masters/master01"
baseurl="https://devops"
curl --request POST -k --data-urlencode id=$hostid --header "Authorization: Token token=\"$token\"" $baseurl/api/host_factories/hosts
View ReissueCert.sh
evoke ca regenerate the-master-name-from-client-perspective
View touch.ps1
# Add nix-like touch command
function touch
{
$file = $args[0]
if($file -eq $null)
{
throw "No filename supplied"
}
View keybase.md

Keybase proof

I hereby claim:

  • I am infamousjoeg on github.
  • I am infamousjoeg (https://keybase.io/infamousjoeg) on keybase.
  • I have a public key ASBR9KhHoyuxeEK_EAnJJbycJy5qRPes0qnJbGcAk4peMgo

To claim this, I am signing this object: