Skip to content

Instantly share code, notes, and snippets.

View navichok26's full-sized avatar
💜

x5113nc3x navichok26

💜
View GitHub Profile
@pellaeon
pellaeon / child-gating-poc.py
Created September 23, 2022 12:21
Frida child-gating and spawn-gating example
"""
This POC is based on example from https://frida.re/news/#child-gating
and is aimed to instrument child processes along with the main one.
"""
from __future__ import print_function
import frida
from frida_tools.application import Reactor
import threading
@danhab99
danhab99 / i3_keybindings.md
Created January 21, 2022 03:32
I3 keybindings for moving the mouse

I3 Keybindings For Moving The Mouse

This is really just meant to be goofy, noone should use this instead of a mouse.

Installation

Add these lines to your i3 config.

bindsym $mod+Mod1+h exec xdotool mousemove_relative -p 270 10
@niklaskeerl
niklaskeerl / install_pwndbg.md
Last active April 25, 2024 02:37
Install pwndbg and gdb on arch linux

How to install pwndbg and gdb on arch linux

sudo pacman -S gdb
sudo pacman -S pwndbg
echo 'source /usr/share/pwndbg/gdbinit.py' >> ~/.gdbinit

If you are getting the following error "Cannot find Pwndbg virtualenv directory: /usr/share/pwndbg/.venv: please re-run setup.sh", do the following steps, otherwise ignore:

@navichok26
navichok26 / application.properties
Created January 12, 2020 08:39
spring boot config for postgreSQL
spring.datasource.url=jdbc:postgresql://localhost:5432/springbootdb
spring.datasource.username=postgres
spring.datasource.password=1234
spring.jpa.hibernate.ddl-auto=create
@jimmychu0807
jimmychu0807 / string-conversion.rs
Created November 21, 2019 10:20
Conversion between String, str, Vec<u8>, Vec<char> in Rust
use std::str;
fn main() {
// -- FROM: vec of chars --
let src1: Vec<char> = vec!['j','{','"','i','m','m','y','"','}'];
// to String
let string1: String = src1.iter().collect::<String>();
// to str
let str1: &str = &src1.iter().collect::<String>();
// to vec of byte
@sekkr1
sekkr1 / android_gdb.md
Created August 12, 2019 15:27
Attaching GDB to Android apps' native libraries

How to GDB android native libraries

[1] Install NDK from android studio

[2] Push appropriate gdb-server to phone

adb push ~/android-sdk-linux/ndk-bundle/prebuilt/android-<arch>/gdbserver/gdbserver /data/local/tmp
adb shell "chmod 777 /data/local/tmp/gdbserver"
adb shell "ls -l /data/local/tmp/gdbserver"

[4] Forward ports

adb forward tcp:1337 tcp:1337

@kloudsamurai
kloudsamurai / encrypt_decrypt_gpg_passphrase_example.sh
Last active October 3, 2021 09:59
Using GPG with a passphrase to encrypt and decrypt with AES256
# encrypt secret.txt
gpg --symmetric --yes --batch --cipher-algo AES256 --passphrase=XXXXX secret.txt && rm -f secret.txt
# decrypt secret.txt
gpg --decrypt --yes --batch --passphrase=XXXXX secret.txt.gpg > secret.txt && rm -f secret.txt.gpg
@jesobreira
jesobreira / url-encode.c
Created January 22, 2019 21:21 — forked from sudar/url-encode.c
URL Encoding in C (urlencode / encodeURIComponent)
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
char* urlencode(char* originalText)
{
// allocate memory for the worst possible case (all characters need to be encoded)
char *encodedText = (char *)malloc(sizeof(char)*strlen(originalText)*3+1);
@bDrwx
bDrwx / mmf.c
Created January 14, 2019 18:27
memory-mapped files
#include <fcntl.h>
#include <sys/mman.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <errno.h>
#include <stdarg.h>
#define MAXLINE 4096 /* max line length */
@KRostyslav
KRostyslav / tsconfig.json
Last active May 6, 2024 06:54
tsconfig.json с комментариями.
// Файл "tsconfig.json":
// - устанавливает корневой каталог проекта TypeScript;
// - выполняет настройку параметров компиляции;
// - устанавливает файлы проекта.
// Присутствие файла "tsconfig.json" в папке указывает TypeScript, что это корневая папка проекта.
// Внутри "tsconfig.json" указываются настройки компилятора TypeScript и корневые файлы проекта.
// Программа компилятора "tsc" ищет файл "tsconfig.json" сначала в папке, где она расположена, затем поднимается выше и ищет в родительских папках согласно их вложенности друг в друга.
// Команда "tsc --project C:\path\to\my\project\folder" берет файл "tsconfig.json" из папки, расположенной по данному пути.
// Файл "tsconfig.json" может быть полностью пустым, тогда компилятор скомпилирует все файлы с настройками заданными по умолчанию.
// Опции компилятора, перечисленные в командной строке перезаписывают собой опции, заданные в файле "tsconfig.json".