Skip to content

Instantly share code, notes, and snippets.

View json-m's full-sized avatar
🏴

Jason M. json-m

🏴
View GitHub Profile
@kkrypt0nn
kkrypt0nn / ansi-colors-discord.md
Last active April 24, 2024 09:14
A guide to ANSI on Discord

A guide to ANSI on Discord

Discord is now slowly rolling out the ability to send colored messages within code blocks. It uses the ANSI color codes, so if you've tried to print colored text in your terminal or console with Python or other languages then it will be easy for you.

Quick Explanation

To be able to send a colored text, you need to use the ansi language for your code block and provide a prefix of this format before writing your text:

\u001b[{format};{color}m

\u001b is the unicode escape for ESCAPE/ESC, meant to be used in the source of your bot (see ). If you wish to send colored text without using your bot you need to copy the character from the website.

@approovm
approovm / 00-android-bypass-certificate-pinning-and-mitm-attack-setup.md
Last active April 23, 2024 01:21
Certificate Pinning Bypassing: Setup with Frida, mitmproxy and Android Emulator with a writable file system
@packerdl
packerdl / lxc_plex_intel_quicksync.md
Last active March 19, 2024 11:35
Intel QuickSync passthrough to an unprivileged LXC container running plex.

Running Plex in an Unprivileged LXC with Intel QuickSync Passthrough

First setup an unprivileged Ubuntu container with Plex Media Server installed. Inside the container take note of the id of the plex group.

# Your Plex group's ID may be different
$ getent group plex | cut -d : -f3
998

CockroachDB and Docker Compose

This is the first in a series of tutorials on CockroachDB and Docker Compose

  • Information on CockroachDB can be found here.
  • Information on Docker Compose can be found here
  1. Install Docker Desktop

Because we already have an official CockroachDB docker image, we will use that in our docker-compose.yml file. We recommend you use one of the current tags instead of latest.

#!/bin/sh
# https://dl.ubnt.com/unifi/5.11.46/unifi_sh_api
#username=ubnt
#password=ubnt
#baseurl=https://unifi:8443
#site=default
#[ -f ./unifi_sh_env ] && . ./unifi_sh_env
cookie=$(mktemp)
@alexrqs
alexrqs / videojs-plugin-events-logger.js
Last active November 9, 2023 10:09
VideoJS event list
// The events are from https://www.w3.org/TR/html5/semantics-embedded-content.html#media-elements-event-summary
import videojs from 'video.js'
const Plugin = videojs.getPlugin('plugin')
const EVENTS = [
'loadstart',
'progress',
'suspend',
'abort',
'error',
@jonluca
jonluca / NintendoSystemVersionTable.csv
Last active April 10, 2023 03:04
Nintendo Switch Fuse Blown Count
System version Expected number of burnt fuses (retail) Expected number of burnt fuses (non-retail)
1.0.0 1 0
2.0.0-2.3.0 2 0
3.0.0 3 1
3.0.1-3.0.2 4 1
4.0.0-4.1.0 5 1
5.0.0-5.1.0 6 1
6.0.0-6.1.0 7 1
6.2.0 8 1
7.0.0-8.0.1 9 1
@inntran
inntran / vzw-lte-ipv6-prefix-translation.md
Last active September 9, 2022 00:58
To configure IPv6 NPTv6 on Linux to allow more hosts behind Verizon Wireless LTE IPv6 single /64 prefix

Problem

Verizon Wireless assigns you ONE IPv4 address and ONE /64 IPv6 prefix for their cellular service, and VZW would reset your datalink once they received 1 packet with an illegal source address.

We have NAT for IP but for IPv6 we would like to avoid address translation to get some kind of end-to-end communication.

Solution

NPTv6, defined in RFC6296, would help us to do stateless prefix translation for IPv6.

radare2

load without any analysis (file header at offset 0x0): r2 -n /path/to/file

  • analyze all: aa
  • show sections: iS
  • list functions: afl
  • list imports: ii
  • list entrypoints: ie
  • seek to function: s sym.main