Skip to content

Commit 6dee14f

Browse files
committed
v1.3.6
1 parent 5cac383 commit 6dee14f

9 files changed

+30
-23
lines changed

CDIR/CDIR.cpp

+18-10
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright(C) 2019 Cyber Defense Institute, Inc.
2+
* Copyright(C) 2022 Cyber Defense Institute, Inc.
33
*
44
* This program/include file is free software; you can redistribute it and/or
55
* modify it under the terms of the GNU General Public License as published
@@ -580,25 +580,27 @@ int get_pagefilepath(char *ret) {
580580
int get_memdump(bool is_x64, char *computername, char *pagefilepath) {
581581
// winpmem
582582
char tmp[256];
583+
char* winpmem_exe_name;
583584
DWORD status;
584585

585586
if (computername == NULL) {
586587
fprintf(stderr, "computername is NULL.\n");
587588
return -1;
588589
}
590+
if (is_x64 == true)
591+
winpmem_exe_name = "winpmem_x64.exe";
592+
else
593+
winpmem_exe_name = "winpmem_x86.exe";
594+
589595
if (config->isSet("MemoryDumpCmdline"))
590596
sprintf(tmp, "%s\\%s", exedir, (CASTVAL(string, config->getValue("MemoryDumpCmdline"))).c_str());
591597
else
592-
sprintf(tmp, "%s\\winpmem.exe -dd --output RAM_%s.aff4 -t", exedir, computername);
593-
598+
sprintf(tmp, "%s\\%s RAM_%s.raw", exedir, winpmem_exe_name, computername);
599+
594600
if (launchprocess(tmp, &status)) {
595601
return -1;
596602
}
597-
598-
// for pagefile.sys acquisition
599-
// sprintf(tmp, "..\\winpmem.exe -dd -p %s -o RAM_%s.aff4 -t", pagefilepath + 4, computername);
600-
// launchprocess(tmp);
601-
603+
602604
return 0;
603605
}
604606

@@ -1216,6 +1218,7 @@ int main(int argc, char **argv)
12161218
uint64_t time_diff;
12171219
struct tm *t;
12181220
SYSTEM_INFO sysinfo;
1221+
char* winpmem_exe_name;
12191222

12201223
sprintf(dllpath, "%s\\NTFSParserDLL.dll", dirname(string(argv[0])).c_str());
12211224
if ((hNTFSParserdll = LoadLibrary(dllpath)) == NULL) {
@@ -1234,7 +1237,7 @@ int main(int argc, char **argv)
12341237

12351238
// chack proces name
12361239
procname = basename(string(argv[0]));
1237-
cout << msg("CDIR Collector v1.3.5 - 初動対応用データ収集ツール", "CDIR Collector v1.3.5 - Data Acquisition Tool for First Response") << endl;
1240+
cout << msg("CDIR Collector v1.3.6 - 初動対応用データ収集ツール", "CDIR Collector v1.3.6 - Data Acquisition Tool for First Response") << endl;
12381241
cout << msg("Cyber Defense Institute, Inc.\n", "Cyber Defense Institute, Inc.\n") << endl;
12391242

12401243
// set curdir -> exedir
@@ -1442,9 +1445,14 @@ int main(int argc, char **argv)
14421445
}
14431446
}
14441447

1448+
if (is_x64 == true)
1449+
winpmem_exe_name = "winpmem_x64.exe";
1450+
else
1451+
winpmem_exe_name = "winpmem_x86.exe";
1452+
14451453

14461454
if (param_memdump) {
1447-
if (!(config->isSet("MemoryDumpCmdline")) && filecheck((char*)((string)exedir + "\\winpmem.exe").c_str())) {
1455+
if (!(config->isSet("MemoryDumpCmdline")) && filecheck((char*)((string)exedir + "\\" + winpmem_exe_name).c_str())) {
14481456
cerr << msg("メモリダンプ用プログラムがありません",
14491457
"No memory dump program found") << endl;
14501458
}

CDIR/CDIR.rc

+5-5
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,8 @@ IDI_ICON1 ICON "collector.ico"
6262
//
6363

6464
VS_VERSION_INFO VERSIONINFO
65-
FILEVERSION 1,3,5,0
66-
PRODUCTVERSION 1,3,5,0
65+
FILEVERSION 1,3,6,0
66+
PRODUCTVERSION 1,3,6,0
6767
FILEFLAGSMASK 0x3fL
6868
#ifdef _DEBUG
6969
FILEFLAGS 0x1L
@@ -80,12 +80,12 @@ BEGIN
8080
BEGIN
8181
VALUE "CompanyName", "Cyber Defense Institute, Inc."
8282
VALUE "FileDescription", "Data Collection Tool for Incident Response"
83-
VALUE "FileVersion", "1.3.5.0"
83+
VALUE "FileVersion", "1.3.6.0"
8484
VALUE "InternalName", "cdir-collector.exe"
85-
VALUE "LegalCopyright", "Copyright (C) 2020 Cyber Defense Institute"
85+
VALUE "LegalCopyright", "Copyright (C) 2022 Cyber Defense Institute"
8686
VALUE "OriginalFilename", "cdir-collector.exe"
8787
VALUE "ProductName", "CDIR Collector"
88-
VALUE "ProductVersion", "1.3.5.0"
88+
VALUE "ProductVersion", "1.3.6.0"
8989
END
9090
END
9191
BLOCK "VarFileInfo"

CDIR/cdir.ini

+1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ WMI = true
99
SRUM = true
1010
Web = true
1111
;Target = G:\
12+
;MemoryDumpCmdline = winpmem_v3.3.rc3.exe -dd --output RAM.aff4
1213
;MemoryDumpCmdline = winpmem-2.1.post4.exe --output RAM.aff4
1314
;MemoryDumpCmdline = DumpIt.exe /Q /N /T DMP /O RAM.dmp
1415
;MemoryDumpCmdline = RamCapture64.exe RAM.raw

CDIR/winpmem-2.1.post4.exe

-2.15 MB
Binary file not shown.

CDIR/winpmem.exe

-2.35 MB
Binary file not shown.

CDIR/winpmem_x64.exe

515 KB
Binary file not shown.

CDIR/winpmem_x86.exe

212 KB
Binary file not shown.

README.md

+3-4
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,8 @@ https://github.com/CyberDefenseInstitute/CDIR/releases
3939
* NTFSParserDLL.dll
4040
* libcrypto-41.dll
4141
* libssl-43.dll
42-
* winpmem.exe
43-
* winpmem-2.1.post4.exe
42+
* winpmem_x64.exe
43+
* winpmem_x86.exe
4444

4545
## 使い方
4646

@@ -55,5 +55,4 @@ cdir-collectorは以下のライブラリ、ツールを活用しています。
5555
* ライブラリ: NTFSParserDLL, LibreSSL
5656
* ツール: winpmem
5757

58-
winpmem.exeはc-aff4プロジェクト (https://github.com/Velocidex/c-aff4) で提供されているWindows用のメモリ保全プログラムです。
59-
winpmem-2.1.post4.exeはwinpmem.exeの過去バージョンでrekallプロジェクト (https://github.com/google/rekall) で提供されているプログラムです。
58+
winpmem_x64.exe、winpmem_x86.exeはWinPmemプロジェクト (https://github.com/Velocidex/WinPmem) で提供されているWindows用のメモリ保全プログラムです。

README_en.md

+3-4
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,8 @@ Component of cdir-collector:
4040
* NTFSParserDLL.dll
4141
* libcrypto-41.dll
4242
* libssl-43.dll
43-
* winpmem.exe
44-
* winpmem-2.1.post4.exe
43+
* winpmem_x64.exe
44+
* winpmem_x86.exe
4545

4646
## How to use
4747

@@ -57,5 +57,4 @@ cdir-collector depends on the following library/tools.
5757
* Library: NTFSParserDLL, LibreSSL
5858
* Tool: winpmem
5959

60-
winpmem.exe is a part of c-aff4 project (https://github.com/Velocidex/c-aff4).
61-
winpmem-2.1.post4.exe is a part of rekall project (https://github.com/google/rekall).
60+
winpmem_x64.exe and winpmem_x86.exe are parts of winpmem project (https://github.com/Velocidex/WinPmem).

0 commit comments

Comments
 (0)