Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View Necklaces's full-sized avatar

Nichlas Severinsen Necklaces

View GitHub Profile
@vladiant
vladiant / Makefile
Created July 10, 2021 22:12
C++20 Hello World Module
main : main.o hello.o
g++-11 -o main main.o hello.o
main.o : main.cpp gcm.cache/smd.hello.gcm
g++-11 -fPIC -fmodules-ts -std=c++20 -o main.o -c main.cpp
hello.o: hello.cpp
g++-11 -fPIC -fmodules-ts -std=c++20 -o hello.o -c hello.cpp
gcm.cache/smd.hello.gcm: hello.o
@TheRealKeto
TheRealKeto / FuturerestoreGuide.md
Last active March 14, 2024 18:46
A guide fully covering the process of using Futurerestore to upgrade, downgrade, or re-restore to an unsigned iOS firmware.

Futurerestore Guide

Futurerestore is a tool that allows users to upgrade, downgrade, or re-restore their iOS device to an unsigned firmware through the use of SHSH2 blobs. This guide will teach you how to use Futurerestore in order to upgrade, downgrade, or re-restore to an unsigned firmware.

Before continuing, keep in mind that this guide is based off of this one, and contains information that can change your device's behavior or even damage it. With that in mind, please read the guide fully, as no one but YOU will be held responsible for any damage caused to your device.

Notes and Hints

Throughout the entirety of this guide, keep in mind that:

  • iOS 13.1.3's SEP and Baseband are NOT compatible with iOS 12.x for all devices. This means that you're NOT able to upgrade, downgrade, or re-restore A10-A12X devices back to iOS 12.x. Attempting to use an incompatible SEP and Baseband will cause Futureresto
@jleclanche
jleclanche / freeotp_backup.md
Last active April 22, 2024 14:22
A guide to back up and recover 2FA tokens from FreeOTP (Android)

Backing up and recovering 2FA tokens from FreeOTP

NOTE: THIS MAY NOT WORK ANYMORE - SEE COMMENTS

Backing up FreeOTP

Using adb, create a backup of the app using the following command:

adb backup -f freeotp-backup.ab -apk org.fedorahosted.freeotp
@nstarke
nstarke / release-android-debuggable.md
Last active April 16, 2024 08:06
How to make a Release Android App debuggable

How to make a Release Android App debuggable

Let's say you want to access the application shared preferences in /data/data/com.mypackage.
You could try to run adb shell and then run-as com.mypackage ( or adb shell run-as com.mypackge ls /data/data/com.mypackage/shared_prefs), but on a production release app downloaded from an app store you're most likely to see:

run-as: Package 'com.mypackage' is not debuggable
@ctrl-freak
ctrl-freak / android-adb-pull-apk.md
Last active April 9, 2024 11:31
Retrieve APK from Non-Rooted Android Device through ADB

https://stackoverflow.com/a/18003462/348146

None of these suggestions worked for me, because Android was appending a sequence number to the package name to produce the final APK file name (this may vary with the version of Android OS). The following sequence of commands is what worked for me on a non-rooted device:

  1. Determine the package name of the app, e.g. com.example.someapp. Skip this step if you already know the package name.

    adb shell pm list packages

    Look through the list of package names and try to find a match between the app in question and the package name. This is usually easy, but note that the package name can be completely unrelated to the app name. If you can't recognize the app from the list of package names, try finding the app in Google Play using a browser. The URL for an app in Google Play contains the package name.

@barneygale
barneygale / check_mode.py
Last active November 28, 2022 18:02
Check if a minecraft server is in offline or online mode
import json
import socket
### Helper functions
# Read n bytes from the socket
def read(sock, n):
o = ""
while len(o) < n:
o += sock.recv(n-len(o))
@TobiasWooldridge
TobiasWooldridge / gist:22f0cdca75190b9a473f
Last active April 4, 2024 20:03
How to Unbrick a Kindle Paperwhite

How to unbrick an Amazon Kindle Paperwhite™

This guide instructs you in how to unbrick an Amazon Kindle Paperwhite. The consequences of following it are your own responsibility. This method (opening the Kindle and using the serial interface) should be a last resort and should only be considered if other methods fail

The Guide

  1. Pry open Kindle using a prying tool
  2. Unscrew the screen and remove it from the base. Note that there's a screw hidden under the adhesive at the top in the middle
  3. Solder tin wire to serial ports on the bottom
  4. Attach tin wire to USB TTY device (order is ground, RX, TX, from the kindle's perspective, where GND is the smallest pad) and plug USB TTY device into your computer
  5. Open Putty on your computer in serial mode, with the serial port specified as your USB device and baud configured to 115200
@plentz
plentz / nginx.conf
Last active April 22, 2024 10:54
Best nginx configuration for improved security(and performance)
# to generate your dhparam.pem file, run in the terminal
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048
@stormwild
stormwild / virtualbox-clone-fixed-to-dynamic.md
Last active March 26, 2024 04:06
VirtualBox clone fixed size vm to dynamic, resize dynamic vm, expand partition

http://brainwreckedtech.wordpress.com/2012/01/08/howto-convert-vdis-between-fixed-sized-and-dynamic-in-virtualbox/ http://www.webdesignblog.asia/software/linux-software/resize-virtualbox-disk-image-manipulate-vdi/#comment-474

While there is no way to actually switch a VDI between fixed-size and dynamic, you can clone the existing VDI into a new one with different settings with VBoxManage.

VBoxManage clonehd [old-VDI] [new-VDI] --variant Standard
VBoxManage clonehd [old-VDI] [new-VDI] --variant Fixed

If you want to expand the capacity of a VDI, you can do so with