Skip to content

Instantly share code, notes, and snippets.

View shahril96's full-sized avatar
🐢

Mohd Shahril shahril96

🐢
View GitHub Profile
@Nerten
Nerten / gist:399257dba4c36393c063
Last active June 2, 2017 03:40
Aria2c + webui-aria2 to Ubuntu on Odroid-C1
sudo apt-get install -y aria2
sudo mkdir /etc/aria2
sudo touch /etc/aria2/aria2.session
sudo bash -c "cat <<EOT > /etc/aria2/aria2.conf
daemon=true
continue=true
enable-rpc=true
rpc-listen-port=6800
rpc-listen-all=true
check-certificate=false
@rsds143
rsds143 / tmux.conf
Created January 21, 2011 05:39
my tmux file
# $Id: vim-keys.conf,v 1.2 2010/09/18 09:36:15 nicm Exp $
#
# vim-keys.conf, v1.2 2010/09/12
#
# By Daniel Thau. Public domain.
#
# This configuration file binds many vi- and vim-like bindings to the
# appropriate tmux key bindings. Note that for many key bindings there is no
# tmux analogue. This is intended for tmux 1.3, which handles pane selection
# differently from the previous versions
@ThunderCls
ThunderCls / darktheme_modded.ini
Last active November 20, 2019 09:11
Dark Theme Modded by ThunderCls (http://i.imgur.com/y3mcIRu.png)
[Colors]
AbstractTableViewBackgroundColor=#272822
AbstractTableViewHeaderTextColor=#000000
AbstractTableViewSelectionColor=#363930
AbstractTableViewSeparatorColor=#555A4C
AbstractTableViewTextColor=#FFFFFF
DisassemblyAddressBackgroundColor=#XXXXXX
DisassemblyAddressColor=#AE81FF
DisassemblyAutoCommentBackgroundColor=#XXXXXX
DisassemblyAutoCommentColor=#CF780D
@jas-
jas- / .gdbinit
Last active May 13, 2020 20:29
Memory scraping
python
sys.path.insert(0, '/path/to/module/dir')
import hexdump
end
@hugsy
hugsy / checksec.c
Last active March 5, 2021 16:31
PE version of checksec.sh
/**
* Poor version of checksec.sh script for PE (checks for ASLR, NX, Integrity, SEH flags)
*
* Copy/Paste commands
* c:\> dir /s /b *.dll > DllList.txt
* c:\> checksec.exe -f DllList.txt > DllList_checksec.txt
*
* @ref
* https://msdn.microsoft.com/en-us/library/windows/desktop/ms680339(v=vs.85).aspx
*/
@Apsu
Apsu / uefisetup.sh
Last active July 8, 2021 03:54
Arch Linux UEFI Setup
# **************** READ THIS FIRST ******************
#
# This is not a script for you to run. I repeat, do not download and run this!
#
# This is only a guide to show the required steps for successful UEFI + GRUB2 installation
# Many of the choices are examples or assumptions; don't blindly type shit into your machine
# until/unless you at least read the comments around each command
#
# These steps assume you've booted in UEFI mode by preparing your USB stick per these instructions:
# https://wiki.archlinux.org/index.php/UEFI#Archiso
@Steven-Rose
Steven-Rose / gist:3943830
Created October 24, 2012 04:27
VI: Select all + delete, select all + copy
Select all and delete (actually move to buffer)
:%d
Select all and copy to buffer
:%y
Use p to paste the buffer.
@mokhdzanifaeq
mokhdzanifaeq / extract.py
Last active July 4, 2023 03:30
extract data embeded in pixel channels
from PIL import Image
import argparse
from collections import OrderedDict
def parseMask(string):
mask = []
for val in string.split(","):
if "-" in val:
min, max = val.split("-")
mask += [1 << (i - 1) for i in range(int(min), int(max) + 1)]
@jojobyte
jojobyte / ContextCmder-Disable.reg
Last active October 5, 2023 13:13
Cmder Context (Right-Click) Menu for Windows 7, 8, 10 & 11
Windows Registry Editor Version 5.00
[-HKEY_CLASSES_ROOT\Directory\Background\shell\Cmder]
[-HKEY_CLASSES_ROOT\Directory\shell\Cmder]
@L0SG
L0SG / freeze_example.py
Last active October 12, 2023 05:02
PyTorch example: freezing a part of the net (including fine-tuning)
import torch
from torch import nn
from torch.autograd import Variable
import torch.nn.functional as F
import torch.optim as optim
# toy feed-forward net
class Net(nn.Module):
def __init__(self):