Skip to content

Instantly share code, notes, and snippets.

{
"name": "pd Pool",
"description": "My very own Cardano StakePool",
"ticker": "pds",
"homepage": "https://github.com/platdrag/cardano-node-docker"
}
@platdrag
platdrag / Threadsafe_iter.py
Last active July 9, 2024 08:36
An example generic wrapper for making any iterator / generator thread-safe compatible with python 3
import threading
'''
A generic iterator and generator that takes any iterator and wrap it to make it thread safe.
This method was introducted by Anand Chitipothu in http://anandology.com/blog/using-iterators-and-generators/
but was not compatible with python 3. This modified version is now compatible and works both in python 2.8 and 3.0
'''
class threadsafe_iter:
"""Takes an iterator/generator and makes it thread-safe by
serializing call to the `next` method of given iterator/generator.
"""
@platdrag
platdrag / Invoke-Kerberoast.ps1
Created March 29, 2017 12:33
Invoke-Kerberoast.ps1
<#
Invoke-Kerberoast.ps1
Author: Will Schroeder (@harmj0y), @machosec
License: BSD 3-Clause
Required Dependencies: None
Credit to Tim Medin (@TimMedin) for the Kerberoasting concept and original toolset implementation (https://github.com/nidem/kerberoast).
Note: the primary method of use will be Invoke-Kerberoast with various targeting options.