Skip to content

Instantly share code, notes, and snippets.

View PatriceBlin's full-sized avatar
🛩️
I may be slow to respond.

Patrice Blin PatriceBlin

🛩️
I may be slow to respond.
View GitHub Profile
@sumonst21
sumonst21 / Remove YT Shorts | AdGuard.md
Created June 23, 2023 09:48
Remove YT Shorts | AdGuard

https://www.reddit.com/r/uBlockOrigin/wiki/solutions/youtube/#wiki_shorts

! YT Homepage - Hide the Shorts section
youtube.com##[is-shorts]
! YT Menu - Hide the Shorts button
www.youtube.com###guide [title="Shorts"], .ytd-mini-guide-entry-renderer[title="Shorts"]
! YT Search - Hide Shorts
www.youtube.com##ytd-search ytd-video-renderer [overlay-style="SHORTS"]:upward(ytd-video-renderer)
! YT Search and Channels - Hide the Shorts sections
www.youtube.com##ytd-reel-shelf-renderer
@macshome
macshome / defang.md
Last active April 1, 2025 17:44
How to defang system protections on macOS

How to Defang macOS System Protections

If you want to change things on the root drive of a Mac you will need to take some steps to disable the built in security of the system. Most of these steps are the same regardless if you are on Intel or Apple Silicon. If there is a difference it is noted.

Note that all of these things put a Mac into an unsupported and less secure state.

Make sure you either perform these steps in a VM or that you reset the protections after you are done poking around

Protections and Terms

(This list is not exahustive on the details of each. Check the links at the end for more info.)

# Script to rebase 64 bits iBoots
#@author matteyeux
#@category iOS
#@keybinding
#@menupath
#@toolbar
def get_disassembly(address):
"""
Get disassembly insn at specify addr.
@bazad
bazad / arm64_sysregs_ios.py
Created July 17, 2020 19:58
Label iOS arm64 system registers in IDA Pro
#
# arm64_sysregs_ios.py
# Brandon Azad
#
# Based on https://github.com/gdelugre/ida-arm-system-highlight by Guillaume Delugre.
#
import idautils
import idc
@bazad
bazad / sep_firmware_split.py
Last active July 24, 2024 19:46
Split a decrypted Apple SEP firmware image into individual Mach-O files.
#! /usr/bin/env python3
#
# sep_firmware_split.py
# Brandon Azad
#
# Split a decrypted Apple SEP firmware image into individual Mach-O files.
#
# iPhone11,8 17C5053a https://twitter.com/s1guza/status/1203550760102969345
# iPhone11,8 17E255 https://twitter.com/s1guza/status/1244683851957522435
#
This file has been truncated, but you can view the full file.
Accessibility:
Accessibility Information:
Cursor Magnification: Off
Display: Black on White
Flash Screen: Off
Mouse Keys: Off
Slow Keys: Off
Sticky Keys: Off
@icecr4ck
icecr4ck / idapython_cheatsheet.md
Last active March 11, 2025 14:17
Cheatsheet for IDAPython
@wangruohui
wangruohui / intel-nvidia.md
Last active July 27, 2024 14:14
Intel for display, Nvidia for computing

Intel for display, NVIDIA for computing

This guide will show you how to use Intel graphics for rendering display and NVIDIA graphics for CUDA computing on Ubuntu 18.04 / 20.04 desktop.

I made this work on an ordinary gaming PC with two graphics devices, an Intel UHD Graphics 630 plus an NVIDIA GeForce GTX 1080 Ti. Both of them can be shown via lspci | grep VGA.

00:02.0 VGA compatible controller: Intel Corporation Device 3e92
01:00.0 VGA compatible controller: NVIDIA Corporation GP102 [GeForce GTX 1080 Ti] (rev a1)
if(GlobalVariable* GA = M.getGlobalVariable("llvm.global.annotations")) {
// the first operand holds the metadata
for (Value *AOp : GA->operands()) {
// all metadata are stored in an array of struct of metadata
if (ConstantArray *CA = dyn_cast<ConstantArray>(AOp)) {
// so iterate over the operands
for (Value *CAOp : CA->operands()) {
// get the struct, which holds a pointer to the annotated function
// as first field, and the annotation as second field
if (ConstantStruct *CS = dyn_cast<ConstantStruct>(CAOp)) {