Skip to content

Instantly share code, notes, and snippets.

View roelds's full-sized avatar
:shipit:
(╯°□°)╯︵ ┻━┻

RoelDS roelds

:shipit:
(╯°□°)╯︵ ┻━┻
  • 06:29 (UTC -05:00)
View GitHub Profile
@roelds
roelds / keybase.md
Created December 4, 2022 01:59
keybase.md

Keybase proof

I hereby claim:

  • I am roelds on github.
  • I am roelds (https://keybase.io/roelds) on keybase.
  • I have a public key ASB7yu-JsK3LuohfgbPbkgUTq2Puwwp6xEM8cGVBZWGl8go

To claim this, I am signing this object:

@mklement0
mklement0 / ConvertTo-BodyWithEncoding.ps1
Last active September 22, 2024 04:40
PowerShell function that converts the raw body of a web-request response to a string based on the given character encoding.
<#
Prerequisites: Window PowerShell v5.1 and PowerShell (Core), on all supported platforms. (May work in earlier versions.)
License: MIT
Author: Michael Klement <[email protected]>
DOWNLOAD and INSTANT DEFINITION OF THE FUNCTION:
irm https://gist.github.com/mklement0/209a9506b8ba32246f95d1cc238d564d/raw/ConvertTo-BodyWithEncoding.ps1 | iex
@mklement0
mklement0 / Get-WinError.ps1
Last active May 2, 2025 01:48
PowerShell function that looks up information about Windows errors, including HRESULT values, by number or name.
<#
Prerequisites: Windows PowerShell v5.1 or PowerShell Core (v6+)
License: MIT
Author: Michael Klement <[email protected]>
DOWNLOAD and INSTANT DEFINITION OF THE FUNCTION:
irm https://gist.github.com/mklement0/0fc086da1af9a72a94cbdb4a59d55230/raw/Get-WinError.ps1 | iex
@lukechilds
lukechilds / install-cross-platform-emulators.md
Created October 25, 2022 06:14
Install cross platform emulators for Docker

Installs all cross platform emulators for use with docker buildx

docker run -it --rm --privileged tonistiigi/binfmt --install all
@veganaize
veganaize / Icons.md
Last active January 6, 2025 20:29
Site, company, and product icons for use in github markdown.

- Acrobat
- Adobe PDF
- Android (classic)
- Android (modern)
- Apple (classic)
- Apple (modern)
- Arch

@gmurdocca
gmurdocca / socat_caesar_dpi.md
Last active May 2, 2025 06:17
Circumventing Deep Packet Inspection with Socat and rot13

Circumventing Deep Packet Inspection with Socat and rot13

I have a Linux virtual machine inside a customer's private network. For security, this VM is reachable only via VPN + Citrix + Windows + a Windows SSH client (eg PuTTY). I am tasked to ensure this Citrix design is secure, and users can not access their Linux VM's or other resources on the internal private network in any way outside of using Citrix.

The VM can access the internet. This task should be easy. The VM's internet gateway allows it to connect anywhere on the internet to TCP ports 80, 443, and 8090 only. Connecting to an internet bastion box on one of these ports works and I can send and receive clear text data using netcat. I plan to use good old SSH, listening on tcp/8090 on the bastion, with a reverse port forward configured to expose sshd on the VM to the public, to show their Citrix gateway can be circumvented.

Rejected by Deep Packet Inspection

I hit an immediate snag. The moment I try to establish an SSH or SSL connection over o

package main
import (
"errors"
"sync"
)
func test(i int) (int, error) {
if i > 2 {
return 0, errors.New("test error")
@TrevCan
TrevCan / TypeClipboard.md
Last active October 22, 2023 11:47 — forked from ethack/TypeClipboard.md
type-clip: scripts that simulate typing the clipboard contents. Useful when pasting is not allowed.

It "types" the contents of the clipboard.

Why can't you just paste the contents you ask? Sometimes pasting just doesn't work.

  • One example is in system password fields on OSX.
  • Sometimes you're working in a VM and the clipboard isn't shared.
  • Other times you're working via Remote Desktop and again, the clipboard doesn't work in password boxes such as the system login prompts.
  • Connected via RDP and clipboard sharing is disabled and so is mounting of local drives. If the system doesn't have internet access there's no easy way to get things like payloads or Powershell scripts onto it... until now.

Windows

The Windows version is written in AutoHotKey and easily compiles to an executable. It's a single line script that maps Ctrl-Shift-V to type the clipboard.