윈 도 우 cmd 파일 암호화 복화/암화 어떻게 하나요?
2022.09.17 23:13
분명히 exe 도 아니고 cmd 파일인데 실행되고
bat로 변경해도 마치 일반 텍스트 문서처럼 인식해서 실행이 됩니다
하지만 메모장이나 편집기로 열면 내용은 일반적인 exe 파일 처럼 보여지네요
신기해서 하나 첨부 했습니다
댓글 [11]
-
sadold 2022.09.18 03:59
-
지룡자 2022.09.18 09:22
UTF-8 로 보기 하니깐 영어는 보이긴 하네요
우클릭 메뉴 트윅이 어떤 건가요 그거 같은데 알고 싶습니다
-
-0- 2022.09.18 10:07 배치 파일 cmd 난독화라고 구글에 검색하면 대충 나옵니다.
난독화 기술은 현재 랜섬웨어에 사용되고 있는 기술들 중 하나입니다.
첨부한 cmd파일에 해골 모양있는 것 보니까 중국에서 만든 암호화 프로그램 사용하는 것 같습니다.
암호해독 하는 분 윈포에서 저는 한분 확인했습니다.
-
zerojiddu 2022.09.18 10:14 디펜더가 조심하라고 경고 띄우는데요.
-
메리아 2022.09.18 13:51
단순하게 첫 부분이 인코딩을 유니코드로 불러와서 혼란하게 하는 부분 집어넣고
영어와 중국어로 작성한겁니다.
일본어,중국어쪽 인코딩으로 하면 뭔가 한자가 제대로 뜨는거 같네요. utf-8만 해도 영어부분은 제대로 뜹니다.
일본어로 하면 히라가나나 가타가나가 안뜨는거 보면 일본어는 아니고
아무튼 중국어로 보이는군요.
내용 대충 보면
EasyDrv
KDriver
7-Zip
Bandizip
AppCheck
Defender
이런거에 대한 명령 있는데 그냥 윈도우 초기설치에 관련된 파일인거 같네요아니면 이것도 그냥 혼란스럽게 만든 위장일수도 있구요.실제 실행되는 악성코드는 따로 있을수도 있죠.반디집, 앱체크가 있는거 보면 한국인이 중국툴을 써서 난독화 한게 아닌가하는 생각도 드는군요. -
네오이즘 2022.09.18 14:45
&cls
@echo off & title Windows 10
mode con cols=50 lines=10
::PowerShell -NoLogo -WindowStyle Hidden -ExecutionPolicy Bypass -Command "& '.\*.ps1'"
move /y "c:\Windows\Setup\Scripts\Defender\Microsoft.Windows.SecHealthUI_cw5n1h2txyewy\AppxManifest.xml" "c:\windows\SystemApps\Microsoft.Windows.SecHealthUI_cw5n1h2txyewy" >nul 2>&1 \r\nmove /y "c:\Windows\Setup\Scripts\Defender\Program Files\Windows Defender\MsMpEng.exe" "c:\Program Files\Windows Defender" >nul 2>&1\r\n \r\n:: v2: less flicker\r\n\r\n:gui_dialog_1\r\nset first_choices=
,Microsoft-Defender
,Windows10
&set title=
:: Show gui dialog 1=Title 2=choices 3=outputvariable\r\ncall :choice "Windows 10
" "%first_choices%" CHOICE\r\n:: Quit if no choice selected\r\nif not defined CHOICE color 0c & exit /b\r\n:: Print choices\r\necho Choice1: %CHOICE% & echo.\r\n:: Continue to dialog_2\r\ngoto gui_dialog_2\r\n\r\n\r\n:gui_dialog_2\r\n:: Process results from dialog_1\r\nif "%CHOICE%"=="
" set next_choices=EasyDrv (
),K-Driver (
A~Z:\K-Driver),
&set title=
if "%CHOICE%"=="
" set next_choices=7-zip,
9.0,
(Translucent),Office 2021 LTSC
&set title=
if "%CHOICE%"=="Microsoft-Defender
" goto "Microsoft-Defender
if "%CHOICE%"=="Windows10
" goto "Windows10
if "%CHOICE%"=="
" call :"
" & reg delete "HKLM\SOFTWARE\EasyDrv7" /f >nul 2>&1 & exit\r\n:: Show gui dialog 1=Title 2=choices 3=outputvariable\r\ncall :choice "%title%" "%next_choices%" CHOICE\r\n:: Quit if no choice selected\r\nif not defined CHOICE color 0c & exit /b\r\n:: Print choices\r\necho Choice2: %CHOICE% & echo.\r\n:: Back to dialog_1\r\nif "%CHOICE%"=="
" goto gui_dialog_1\r\n\r\n:: Process final choice\r\ncall :"%CHOICE%"\r\n\r\n:: Choice code\r\n:"EasyDrv (
for %%A in ( Z Y X W V U T S R Q P O N M L K J I H G F E D C B A ) do (\r\n
for /f "tokens=*" %%B in ( '"dir /a:d /b %%A:\EasyDrv* 2>nul"' ) do ( set "EasyDrvPath=%%A:\%%B" )\r\n)\r\nif not defined EasyDrvPath ( goto gui_dialog_2 )\r\n\r\nfor /f "tokens=*" %%A in ( '"dir /a:-d /b "%EasyDrvPath%\EasyDrv7*.exe ""' ) do ( set "EasyDrvExe=%%A" )\r\nif not defined EasyDrvExe ( goto gui_dialog_2 )\r\n\r\ncall "%EasyDrvPath%\%EasyDrvExe%" /a /c\r\ntitle EasyDrv
goto gui_dialog_2\r\n\r\n:"K-Driver (
A~Z:\K-Driver)"\r\nfor %%A in ( Z Y X W V U T S R Q P O N M L K J I H G F E D C B A ) do (\r\n
for /f "tokens=*" %%B in ( '"dir /a:d /b %%A:\K-Dri* 2>nul"' ) do ( set "KDriverPath=%%A:\%%B" )\r\n)\r\nif not defined KDriverPath ( goto gui_dialog_2 )\r\n\r\nfor /f "tokens=*" %%A in ( '"dir /a:-d /b "%KDriverPath%\KDLaunc*.exe ""' ) do ( set "KDriverExe=%%A" )\r\nif not defined KDriverExe ( goto gui_dialog_2 )\r\n\r\ncall "%KDriverPath%\%KDriverExe%"\r\ntitle KDriver
goto gui_dialog_2\r\n\r\n:"7-zip"\r\ncall %~dp0data\7z2200-x64.exe /S\r\necho. \r\ntimeout /t 1 >nul\r\nmove /y "c:\Windows\Setup\Scripts\data\7-Zip\*.*" "c:\Program Files\7-Zip" >nul 2>&1 \r\ntitle 7-zip
call :MsgBox "7-zip
" "" "7-zip"\r\ncls\r\ngoto gui_dialog_2\r\n\r\n:"
netsh advfirewall firewall add rule name="Bandizip" dir=in program="C:\Program Files\Bandizip\Bandizip.exe" action=block >nul 2>&1\r\n\r\nnetsh advfirewall firewall add rule name="Bandizip" dir=out program="C:\Program Files\Bandizip\Bandizip.exe" action=block >nul 2>&1\r\n\r\ntimeout /t 2 >nul 2>&1\r\n\r\ncall %~dp0data\BANDIZIP-SETUP-ENT.EXE /S Bandizip@Forum.kr 20991231-ENT027912-CED03578AC-1695ED01\r\ntitle
call :MsgBox "
" "" "
goto gui_dialog_2\r\n\r\n:"
9.0"\r\nstart /wait %~dp0Packages\DX9\DX90c_Addon_Installer.exe /VERYSILENT /NORESTART /SUPPRESSMSGBOXES\r\ntitle
9.0
call :MsgBox "
9.0
" "" "
9.0"\r\ncls\r\ngoto gui_dialog_2\r\n\r\n:"
start /wait %~dp0Packages\AppCheck\AppCheckSetup.exe /S\r\nxcopy /y /s /h "%~dp0\Packages\AppCheck\AppCheck.reg" "c:\Windows\Setup\bat\data\Reg\" >nul 2>&1\r\ntitle
call :MsgBox "
" "" "
goto gui_dialog_2\r\n\r\n:"
(Translucent)"\r\nxcopy /y /s /h "%~dp0\Packages\Translucent" "%ProgramFiles(x86)%\Translucent\" >nul 2>&1\r\ntimeout /t 1 >nul\r\ncd /d "C:\Windows\Setup\Scripts\schedule" && schtasks /Create /XML "Translucent.xml" /TN "\Microsoft\Windows\Task Manager\Translucent" >nul 2>&1 \r\ntitle
call :MsgBox "
" "" "
goto gui_dialog_2\r\n\r\n:"Office 2021 LTSC
ren "%~dp0schedule\Office_Setup.xml" "Office Setup.xml" >nul 2>&1 \r\ntitle Office 2021 LTSC\r\ncall :MsgBox "Office 2021 LTSC
" "" "Office 2021 LTSC"\r\ncls\r\ngoto gui_dialog_2\r\n\r\n:"Microsoft-Defender
call :MsgBox "Microsoft Defender
.? " "VBYesNo+VBQuestion" "Microsoft Defender
" \r\n if errorlevel 7 ( goto gui_dialog_1 ) else if errorlevel 6 (\r\ntitle Microsoft Defender\r\n@start /b "Defender - TrustedInstaller" "%~dp0NSudo.exe" -U:T -P:E "%~dp0Defender.cmd" & call :MsgBox "Microsoft Defender
" "" "Microsoft Defender" & goto gui_dialog_1\r\n )\r\n\r\n:"Microsoft-Store
call :MsgBox "Windows Store
? " "VBYesNo+VBQuestion" "Windows Store
" \r\n if errorlevel 7 ( goto gui_dialog_2 ) else if errorlevel 6 (\r\ntitle Windows Store\r\ndism /online /Remove-ProvisionedAppxPackage /PackageName:Microsoft.WindowsStore_11910.1002.513.0_neutral_~_8wekyb3d8bbwe /NoRestart\r\ndism /online /Remove-ProvisionedAppxPackage /PackageName:Microsoft.StorePurchaseApp_11811.1001.1813.0_neutral_~_8wekyb3d8bbwe /NoRestart\r\ncall :MsgBox "Windows Store
" "" "Windows Store"\r\ngoto gui_dialog_2\r\n )\r\n\r\n:"QuickAssist
call :MsgBox "
.? " "VBYesNo+VBQuestion" "QuickAssist
" \r\n if errorlevel 7 ( goto gui_dialog_2 ) else if errorlevel 6 (\r\ntitle App.Support.QuickAssist\r\ndism.exe /Online /Remove-capability /capabilityname:App.Support.QuickAssist~~~~0.0.1.0 /NoRestart\r\ncall :MsgBox "QuickAssist
" "" "QuickAssist"\r\ngoto gui_dialog_2\r\n )\r\n\r\n:"Hello.Face
call :MsgBox "Windows
? " "VBYesNo+VBQuestion" "Hello.Face
" \r\n if errorlevel 7 ( goto gui_dialog_2 ) else if errorlevel 6 (\r\ntitle Hello.Face\r\ndism.exe /Online /Remove-capability /capabilityname:Hello.Face.18967~~~~0.0.1.0 /NoRestart\r\ncall :MsgBox "Hello.Face
" "" "Hello.Face"\r\ngoto gui_dialog_2\r\n )\r\n\r\n:"MathRecognizer
call :MsgBox "
? " "VBYesNo+VBQuestion" "MathRecognizer
" \r\n if errorlevel 7 ( goto gui_dialog_2 ) else if errorlevel 6 (\r\ntitle MathRecognizer\r\ndism.exe /Online /Remove-capability /capabilityname:MathRecognizer~~~~0.0.1.0 /NoRestart\r\ncall :MsgBox "MathRecognizer
" "" "MathRecognizer"\r\ngoto gui_dialog_2\r\n )\r\n\r\n:"OneSync
call :MsgBox "
.? " "VBYesNo+VBQuestion" "OneSync
" \r\n if errorlevel 7 ( goto gui_dialog_2 ) else if errorlevel 6 (\r\ntitle OneCoreUAP.OneSync\r\ndism.exe /Online /Remove-capability /capabilityname:OneCoreUAP.OneSync~~~~0.0.1.0 /NoRestart\r\ncall :MsgBox "OneSync
" "" "OneSync"\r\ngoto gui_dialog_2\r\n )\r\n\r\n:"OpenSSH.Client
call :MsgBox "OpenSSH
.? " "VBYesNo+VBQuestion" "OpenSSH
" \r\n if errorlevel 7 ( goto gui_dialog_2 ) else if errorlevel 6 (\r\ntitle OpenSSH\r\ndism.exe /Online /Remove-capability /capabilityname:OpenSSH.Client~~~~0.0.1.0 /NoRestart\r\ncall :MsgBox "OpenSSH.Client
" "" "OpenSSH.Client"\r\ngoto gui_dialog_2\r\n )\r\n\r\n:"Windows10
@start /b "WindowsAct - TrustedInstaller" "%~dp0NSudo.exe" -U:T -P:E "%~dp0WindowsAct.cmd" \r\ntitle Windows10
goto gui_dialog_1\r\n\r\n::---------------------------------------------------------------------------------------------------------------------------------\r\n:choice\r\nrem 1=title 2=options 3=output_variable example: call :choice Choose "op1,op2,op3" result\r\nsetlocal & set "c=about:<title>%~1</title><head><script language='javascript'>window.moveTo(-250,-250);window.resizeTo(250,250);"\r\nset "c=%c% </script><hta:application innerborder='no' sysmenu='yes' scroll='no'><style>body{background-color:white;}"\r\nset "c=%c% br{font-size:14px;vertical-align:-4px;} .button{background-color:#7D5BBE;border:2px solid #392E5C; color:white;"\r\nset "c=%c% padding:4px 4px;text-align:center;text-decoration:none;display:inline-block;font-size:16px;cursor:pointer;"\r\nset "c=%c% width:100%%;display:block;}</style></head><script language='javascript'>function choice(){"\r\nset "c=%c% var opt=document.getElementById('options').value.split(','); var btn=document.getElementById('buttons');"\r\nset "c=%c% for (o in opt){var b=document.createElement('button');b.className='button';b.onclick=function(){\r\nset "c=%c% close(new ActiveXObject('Scripting.FileSystemObject').GetStandardStream(1).Write(this.value));};"\r\nset "c=%c% b.appendChild(document.createTextNode(opt[o]));btn.appendChild(b);btn.appendChild(document.createElement('br'));};"\r\nset "c=%c% btn.appendChild(document.createElement('br'));var r=window.parent.screen;"\r\nset "c=%c% window.moveTo(r.availWidth/3,r.availHeight/6);window.resizeTo(r.availWidth/3,document.body.scrollHeight);}</script>"\r\nset "c=%c% <body onload='choice()'><div id='buttons'/><input type='hidden' name='options' value='%~2'></body>"\r\nfor /f "usebackq tokens=* delims=" %%# in (`mshta "%c%"`) do set "choice_var=%%#"\r\nendlocal & set "%~3=%choice_var%" & exit/b &rem snippet by AveYo released under MIT License\r\n::-------------------------------------------------------------------------------------------------------------------------------- \r\n\r\n::-------------------------------------------------------------------------------------------------------------------------------- \r\n :MsgBox prompt type title\r\n setlocal enableextensions\r\n set "tempFile=%temp%\%~nx0.%random%%random%%random%vbs.tmp"\r\n >"%tempFile%" echo(WScript.Quit msgBox("%~1",%~2,"%~3") & cscript //nologo //e:vbscript "%tempFile%"\r\n set "exitCode=%errorlevel%" & del "%tempFile%" >nul 2>nul\r\n endlocal & exit /b %exitCode%\r\n::-------------------------------------------------------------------------------------------------------------------------------- \r\n
-
-0- 2022.09.18 14:58 네오이즘님 혹 첨부파일도 해독 가능한가요?
-
네오이즘 2022.09.18 20:52
이 파일은 cmd파일도 아니고 내용확인이 힘드네요...
-
-0- 2022.09.18 21:07 확인해주셔서 감사합니다.
나중에 난독화 해독관련 강좌좀 해주시면 좋겠습니다. 저도 배우고 싶어요.
-
네오이즘 2022.09.18 22:05
배치파일을 exe파일로 만들어주는 프로그램들이 있습니다.
대부분 배치파일이 텍스트형태로 포함되있고 이를 실행시키는 역할만 하는데 이경우는 특이하게 cmd파일로 실행되게 만들어져 있습니다.
이런 종류의 실행형 변환 파일이 아닌가 싶습니다.
내용은 pestudio라는 프로그램으로 확인했습니다.
이런 프로그램들로 내용 확인이 가능한 경우들이 많이 있습니다.
100% 다 복원된건 아닙니다. 다만 무슨 내용인지는 확인할수 있는 정도구요.
헥사에디터로도 어느정도 확인이 가능합니다.
-
컨피그 2022.09.19 09:40
저번에 저도 비슷한 질문을 올렸었는데요
https://windowsforum.kr/qna/14945899
인코딩 변경을 통한 난독화 방법을 사용하신 거 같은데요
제가 이것저것 해보다가 해독은 가능했는데요
똑같이 따라해보려고 했는데 난독화 시키는 방법은 모르겠더라고요.
번호 | 제목 | 글쓴이 | 조회 | 등록일 |
---|---|---|---|---|
[공지] | 질문과 답변 게시판 이용간 유의사항 | gooddew | - | - |
99404 | 소프트웨어| Vmware 17 pro를 구입했는데 [3] | 개골동자 | 507 | 03-15 |
99403 | 윈 도 우| 예전 윈도우8 때 4만 얼마인가 5만원인가에 구입한 키. [6] | NDSM | 518 | 03-15 |
99402 | 윈 도 우| 파일 이용권한 [4] | 도파고 | 278 | 03-15 |
99401 | 하드웨어| PCIE 없는 PC에 별도로 추가할수 있나요? [7] | 밀크사랑 | 397 | 03-15 |
99400 | 윈 도 우| 윈11 작업표시줄 시스템 트레이 아이콘 목록 삭제가 안됩니다. [11] | macross | 275 | 03-15 |
99399 | 기 타| 벤토이 fat32로 포멧해도 되겠조? [4] | 소나무_뿌 | 262 | 03-15 |
99398 | 기 타| 배경화면에서 리사를 지워주세요 [2] | AsuraHan | 433 | 03-15 |
99397 | 윈 도 우| 윈도우10설치 후 부팅시 '사용자 암호 만료되었다'는 창이 ... [2] | pinnk | 274 | 03-15 |
99396 | 소프트웨어| PE에서 "EasyBCD"가 실행이 되지 않습니다 ㅠ_ㅠ [11] | 시종일관 | 364 | 03-15 |
99395 | 윈 도 우| 아래 탐색기 목록 삭제 안되네요 [6] | choory | 334 | 03-14 |
99394 | 기 타| 습기가 차지 않는 작업용 고글 좀 추천해주세요 [4] | 커피한잔 | 256 | 03-14 |
99393 | 윈 도 우| 윈도우 탐색기 목록 삭제 방법 조언 부탁드립니다 [6] | choory | 310 | 03-14 |
99392 | 소프트웨어| MS 워드 인쇄시 문의 [2] | 강남역5번 | 181 | 03-14 |
99391 | 소프트웨어| 크롬 업데이트 후 짜증이... [7] | 이슬 | 510 | 03-14 |
99390 | 윈 도 우| 윈도우 통합 이후 [2] | 집앞의_큰 | 300 | 03-14 |
99389 | 소프트웨어| Emeditor 정규표현식(경어체-반말바꾸기) 질문입니다. [2] | 파풍초 | 135 | 03-14 |
99388 | 윈 도 우| 폴더복사 배치 고수님 하나만 만들어 주세요^^ [8] | 수리수리 | 276 | 03-14 |
99387 | 윈 도 우| 업데이트 후 부팅 속도 느려집니다 [4] | choory | 374 | 03-14 |
99386 | 모 바 일| 휴대폰 앱 삭제하는 앱이 있나요? [2] | brucex | 267 | 03-14 |
99385 | 윈 도 우| PE 이미지 (boot.wim) 마운트시 오류 [2] | 홍은동초짜 | 178 | 03-14 |
하지만 메모장이나 편집기로 열면 내용은 일반적인 exe 파일 처럼 보여지네요
하지만 메모장이나 편집기로 열면 내용은 일반적인 cmd 파일 처럼 보여지네요 <-- 이게 맞는 말 아닌가요?
이게 맞다면 우클릭 메뉴 트윅을 했는지 봐야할 것 같네요
암호화 복호화의 문제는 아닌 것 같네요