Skip to content

Instantly share code, notes, and snippets.

@xan7r
xan7r / digitalOceanAPI.py
Last active May 6, 2023 11:10
Script for basic management of Digital Ocean droplets and DNS records
#!/usr/bin/python3
import digitalocean, time, datetime, sys, re, argparse
from urllib import request
# NOTE: REQUIRES python-digitalocean
#
# examples:
# ./digitalOceanAPI.py --create-droplet "ubuntu 18.04"
# ./digitalOceanAPI.py --destroy-droplet <ubuntu18.04-20180723.185051>
# ./digitalOceanAPI.py --list-droplets
# ./digitalOceanAPI.py --list-images
@xan7r
xan7r / decryptKerbTicket.py
Last active April 10, 2024 04:29
Decrypt kerberos tickets and parse out authorization data
#!/usr/bin/env python2
# NOTE: this script was created for educational purposes to assist learning about kerberos tickets.
# Likely to have a few bugs that cause it to fail to decrypt some TGT or Service tickets.
#
# Recommended Instructions:
# Obtain valid kerberos tickets using Rubeus or mimikatz "sekurlsa::tickets /export"
# Optionally convert tickets to ccache format using kekeo "misc::convert ccache <ticketName.kirbi>"
# Obtain appropriate aes256 key using dcsync (krbtgt for TGT or usually target computer account for Service Ticket)
# Run this script to decrypt:
# ./decryptKerbTicket.py -k 5c7ee0b8f0ffeedbeefdeadbeeff1eefc7d313620feedbeefdeadbeefafd601e -t ./Administrator@TESTLAB.LOCAL_krbtgt~TESTLAB.LOCAL@TESTLAB.LOCAL.ccaches