Skip to content

Instantly share code, notes, and snippets.

View adricnet's full-sized avatar

Adric Net adricnet

View GitHub Profile
@adricnet
adricnet / how-learn-malware.md
Last active March 20, 2022 16:37
Some notes on how to learn malware analysis

Yay, one of my favourite topics :) I'm still learning malware analysis, and here's what's helped me:

Resources

  • Books: PMA, and then Malware Analyst's Cookbook, Exploits, Reversing books once you get going
  • Tools: Remnux for static and a safe execution environment for dynamic[1]
  • Samples from books and courses and CTFs .. virusshare is cool too, please seed!
  • Online courses: The http://opensecuritytraining.info/Training.html material is all fantastic and free.
  • Do follow the recommended paths (see img ) if you don't know, say, x86 ASM, or you may get lost fast and not get as much out of it.
@adricnet
adricnet / dexray_rocks.md
Last active March 2, 2021 10:12
dexray testing

Brad says:

Review the traffic and consult the alerts if necessary. You should be able to get the following information from the pcap:

The user's first and last name
The host name of the user's Windows computer
The MAC address of the user's Windows computer
What type(s) or item(s) of malware the user's computer is infected with.

How the user's computer got infected with the item(s) of malware.

@adricnet
adricnet / yara_ole_vba.md
Last active March 3, 2020 18:59
Trying to automate clustering some vba in OLE in DOCX

Some DOCX samples today had the VBA script payload embedded into OLE objects in the DOCX. To a user this looks like document icons in the Word file, and for file analysis they are in the DOCX zip under word/embeddings (Thanks Brian!). After doing a few of these manaully, and then dynamically fighting with the Office debugger to get the indicators out of them individually, I took a moment to try and automate at least part of the process.

Loop through samples in a directory, yank all of the embedded OLE objects, and scan them for likely VBA script with Yara

$ for file in efax/*.docx ; do unzip -qq -o -j $file "word/embeddings*" ; \
  for y in `ls oleObject*`; do echo -n "$file  "; \
    yara -f -w vbaoleobj.yara $y;done; rm -f oleObject* ; done
@adricnet
adricnet / some_vba_notes.md
Last active December 27, 2019 21:01
Some notes on VBA analysis

Some VBA notes

Tools

  • Unix(Remnux): viper.li, oletools, & Didier's tools
  • Windows: Office Excel (VBE) & Visual Studio Community (VSC), officemalscanner
  • Editors: scite, VS Code

Dependencies

@adricnet
adricnet / kali-config-monkeypatch.md
Created November 1, 2019 21:35
Minimally customize a Kali ISO for moar package goodness
root@kali:~/Desktop/live-build-config# cat kali-config/variant-light-voltron/package-lists/kali.list.chroot 
# You always want those
#kali-linux-core
kali-desktop-live

# Kali applications
#<package>
# You can customize the set of Kali metapackages (groups of tools) to install
@adricnet
adricnet / some-conf-talks.md
Last active October 15, 2019 02:05
Conference talks I missed live, watching videos
@adricnet
adricnet / vba-sed-script
Created October 20, 2016 20:25
Normalise VBA code in macros for easier code analysis
### Normalise VBA code in macros for easier code analysis, @adricnet
## Remove all the DOS newlines to start
/^[[:space:]]*$/d
## Add in newlines we want to highlight code blocks
s/end function/End Function\n/i
s/end sub/End Sub\n/i
## Fix mangled cASe obFUScaTioN while we are here
@adricnet
adricnet / cuckoo-windows.md
Last active April 12, 2018 17:17
Cuckoo 2 python 2.7 32bit on Win x64

Some obstacles overcome to get a Cuckoo 2 sandbox going on the class laptop: Win10x64 Pro. This is just my notes and rambling and intent is to write up a working build in case someone else in 610 or the community wants it.

Book

Upstream installation instructions, might give harmless cert error: http://docs.cuckoosandbox.org/en/latest/installation/guest/agent/

Python

@adricnet
adricnet / poof-msf3-joker.md
Last active March 22, 2018 01:30
Proof of obtaining flag? Metasploitable 3's Joker card

The live demo attempt method (FileInsight):

  1. Use web developer tools or Burp to capture source of index page. (Ctrl-A, Ctrl-C)

  2. Paste that HTML into a new buffer in FileInsight.

  3. Trim away everything but the suspicious bitstream.

  4. Select the bitstream (Ctrl-A) and use the Decode tools in the left pane to convert Hex to ASCII (no key).