HTB Lovely Malware - Sherlock
by trevor69000 - Thursday January 2, 2025 at 06:25 AM
#1
Hidden Content
You must register or login to view this content.
Reply
#2
can u unlock it
Reply
#3
how did you decrypt for last q? Found key in pcap but cant seem to decrypt
Reply
#4
(Jan 03, 2025, 06:07 PM)xsi5kqdb Wrote: how did you decrypt for last q? Found key in pcap but cant seem to decrypt

Pcap key is not a valid one. I found the iv. But didnt get how key is generated
Reply
#5
i dont have enough credits for this Undecided
Reply
#6
stuck on the last question o.O
Reply
#7
the key in pcap is not valid. The following is obfuscation part inside it.
```cpp
__int64 convert_aeskey_tobase64()
{
  unsigned int i; // [rsp+34h] [rbp-24h]
  unsigned int v2; // [rsp+38h] [rbp-20h] BYREF
  __int64 mem; // [rsp+40h] [rbp-18h]

  if ( !qword_7FF77F68F388 )
    get_crypt32_baseaddr();
  v2 = 0;
  for ( i = 0; i < 0x20; ++i )
    *(_BYTE *)(random_aes_key + i) ^= 0xBBu;
  if ( !(unsigned __int8)CryptBinaryToString(random_aes_key, 0x20u, 0x40000001u, 0i64, (__int64)&v2) )
    return 0i64;
  mem = allocate_mem(v2);
  if ( (unsigned __int8)CryptBinaryToString(random_aes_key, 0x20u, 0x40000001u, mem, (__int64)&v2) )
    return mem;
  else
    return 0i64;
}
```
Hope this help someone
Reply
#8
each execution the key is unique and will be sent to the c2. but is the key the plaintext key? (BB)
Reply
#9
(Feb 18, 2025, 04:57 PM)noter Wrote: each execution the key is unique and will be sent to the c2. but is the key the plaintext key? (BB)
use get the key from pcap, as I remember, it's base64 format. decode it then xor with 0xBB
Reply
#10
i dont have enough credits for this Sad
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  [FREE] HackTheBox Academy - CBBH CDSA CPTS All Modules Flags Techtom 20 2,450 3 hours ago
Last Post: op334
Heart [FREE] HackTheBox All Cheatsheets Tamarisk 3 370 3 hours ago
Last Post: op334
  [FREE] 300+ Writeups PDF HackTheBox/HTB premium retired Tamarisk 369 91,828 10 hours ago
Last Post: sabbyahmed
  CBBH Write Ups hiddenhacker 22 6,215 Yesterday, 06:39 AM
Last Post: Usercomplex
  [MEGALEAK] HackTheBox ProLabs, Fortress, Endgame - Alchemy, 250 Flags, leak htb-bot htb-bot 86 7,798 Apr 28, 2026, 11:39 PM
Last Post: my4ri0d0

Forum Jump:


 Users browsing this forum: 1 Guest(s)