PostgreSQL cheatsheet
Get a root postgres shell
sudo -u postgres psql
sudo -u postgres psql
The CTREE is built from the optimized microcode (maturity at CMAT_FINAL
), it represents an AST-like tree with C statements and expressions. It can be printed as C code.
lsusb
sudo fdisk -l
df -h # if already mounted
.qcow2
image to raw imageqemu-img convert -p -O raw image.qcow2 image.raw
startsector
of the partition you want to mount with the command file
startsector
value by 512 (referenced as SS_OFFSET
in the next steps)mkdir /mnt/image
mount
command as follows to mount the partitionVirtualisation: hardware assisted virtualisation where the VM’s processor matches host computer’s processor.
Emulation: faking the hardware to virtualise OSes using a different processor than the host computer's processor.
In /etc/ansible/ansible.cfg
by default, but the path can be overwritten by creating a file .ansible.cfg
in the home directory.
Create a hosts
file in /etc/ansible
to add the hosts, it is possible to create groups with [group_name]
.
# /etc/ansible/hosts
import idautils | |
import ida_range | |
import ida_hexrays as hr | |
class decryptor(hr.mop_visitor_t): | |
def visit_mop(self, op, type, is_target): | |
if op.t != hr.mop_f: | |
return 0 |
import idaapi | |
class ExamplePlugin(idaapi.plugin_t): | |
flags = idaapi.PLUGIN_DRAW | |
comment = "This plugin does nothing useful" | |
help = "No help is needed" | |
wanted_name = "Example" | |
wanted_hotkey = "Alt-F11" | |
def init(): |
{ | |
"Miasm\\IR graph" : "Ctrl+Shift+M", | |
"Miasm\\IR graph (simplified)" : "Ctrl+Shift+I", | |
"Disassembly Graph" : "Ctrl+Shift+G", | |
"Hex Editor" : "Ctrl+Shift+H", | |
"Strings" : "Ctrl+Shift+S", | |
"Triage Summary" : "Ctrl+Shift+T" | |
} |