leechcorepyc 2.22.1__tar.gz → 2.22.3__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {leechcorepyc-2.22.1/leechcorepyc.egg-info → leechcorepyc-2.22.3}/PKG-INFO +1 -1
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/device_fpga.c +15 -1
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/device_hibr.c +17 -17
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/version.h +2 -2
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore_device_rawtcp/version.h +2 -2
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3/leechcorepyc.egg-info}/PKG-INFO +1 -1
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/setup.py +1 -1
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/MANIFEST.in +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/Makefile +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/README +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/files/dummy +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/includes/leechcore.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/includes/leechcore_device.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/includes/leechgrpc.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/includes/libpdbcrust.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/includes/vmmdll.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/includes/vmmyara.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/Makefile +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/Makefile.macos +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/device_file.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/device_pmem.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/device_tmd.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/device_usb3380.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/device_vmm.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/device_vmware.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/leechcore.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/leechcore.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/leechcore.rc +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/leechcore_device.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/leechcore_internal.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/leechrpc.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/leechrpc.idl +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/leechrpc_c.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/leechrpc_h.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/leechrpcclient.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/leechrpcshared.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/memmap.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/ob/ob.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/ob/ob_bytequeue.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/ob/ob_core.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/ob/ob_map.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/ob/ob_set.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/oscompatibility.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/oscompatibility.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/util.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore/util.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore_device_qemu/Makefile +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore_device_qemu/leechcore_device_qemu.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore_device_rawtcp/Makefile +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore_device_rawtcp/leechcore_device_rawtcp.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore_device_rawtcp/oscompatibility.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore_device_rawtcp/oscompatibility.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore_device_rawtcp/plugin.rc +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore_device_rawtcp/resource.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore_ft601_driver_linux/Makefile +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore_ft601_driver_linux/fpga_libusb.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore_ft601_driver_linux/fpga_libusb.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore_ft601_driver_linux/leechcore_ft601_driver_linux.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore_ft601_driver_linux/leechcore_ft601_driver_linux.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcorepyc/__init__.py +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcorepyc.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcorepyc.egg-info/SOURCES.txt +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcorepyc.egg-info/dependency_links.txt +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcorepyc.egg-info/top_level.txt +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcorepyc.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcorepyc_barrequest.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/Makefile +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/include/lznt1.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/include/mscomp/Array.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/include/mscomp/Bitstream.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/include/mscomp/CircularBuffer.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/include/mscomp/HuffmanDecoder.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/include/mscomp/HuffmanEncoder.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/include/mscomp/LZNT1Dictionary.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/include/mscomp/LZNT1Dictionary_SA.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/include/mscomp/XpressDictionary.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/include/mscomp/config.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/include/mscomp/general.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/include/mscomp/internal.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/include/mscomp/sorting.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/include/mscomp.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/include/xpress.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/include/xpress_huff.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/src/lznt1_compress.cpp +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/src/lznt1_decompress.cpp +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/src/mscomp.cpp +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/src/xpress_compress.cpp +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/src/xpress_decompress.cpp +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/src/xpress_huff_compress.cpp +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/ms-compress/src/xpress_huff_decompress.cpp +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/oscompatibility.c +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/oscompatibility.h +0 -0
- {leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/setup.cfg +0 -0
|
@@ -293,6 +293,8 @@ typedef struct tdDEVICE_CONTEXT_FPGA {
|
|
|
293
293
|
} tlp_callback;
|
|
294
294
|
BOOL fFT601;
|
|
295
295
|
BOOL fCustomDriver;
|
|
296
|
+
BOOL fATS;
|
|
297
|
+
BYTE bAT;
|
|
296
298
|
} DEVICE_CONTEXT_FPGA, *PDEVICE_CONTEXT_FPGA;
|
|
297
299
|
|
|
298
300
|
// STRUCT FROM FTD3XX.h
|
|
@@ -339,7 +341,7 @@ typedef struct {
|
|
|
339
341
|
|
|
340
342
|
typedef struct tdTLP_HDR {
|
|
341
343
|
WORD Length : 10;
|
|
342
|
-
WORD
|
|
344
|
+
WORD AT : 2;
|
|
343
345
|
WORD _Attr : 2;
|
|
344
346
|
WORD _EP : 1;
|
|
345
347
|
WORD _TD : 1;
|
|
@@ -2354,6 +2356,7 @@ VOID DeviceFPGA_Synch_ReadScatter_Impl(_In_ PLC_CONTEXT ctxLC, _In_ DWORD cMEMs,
|
|
|
2354
2356
|
BYTE bTag;
|
|
2355
2357
|
SIZE_T cbTlpRaw;
|
|
2356
2358
|
BYTE pbTlpRaw[TLP_RX_MAX_SIZE];
|
|
2359
|
+
BOOL fATS = ctx->fATS;
|
|
2357
2360
|
// TX queued RAW TLPs (if any) from other threads and flush:
|
|
2358
2361
|
if(ObByteQueue_Size(ctx->tlp_callback.pBqTx)) {
|
|
2359
2362
|
while(ObByteQueue_Pop(ctx->tlp_callback.pBqTx, NULL, sizeof(pbTlpRaw), pbTlpRaw, &cbTlpRaw)) {
|
|
@@ -2392,6 +2395,7 @@ VOID DeviceFPGA_Synch_ReadScatter_Impl(_In_ PLC_CONTEXT ctxLC, _In_ DWORD cMEMs,
|
|
|
2392
2395
|
is32 = pDMA->qwA < 0x100000000;
|
|
2393
2396
|
if(is32) {
|
|
2394
2397
|
hdrRd32->h.TypeFmt = TLP_MRd32;
|
|
2398
|
+
if(fATS) { hdrRd32->h.AT = ctx->bAT; }
|
|
2395
2399
|
hdrRd32->h.Length = (WORD)((cb < 0x1000) ? cb >> 2 : 0);
|
|
2396
2400
|
hdrRd32->RequesterID = ctx->wDeviceId;
|
|
2397
2401
|
hdrRd32->Tag = bTag;
|
|
@@ -2400,6 +2404,7 @@ VOID DeviceFPGA_Synch_ReadScatter_Impl(_In_ PLC_CONTEXT ctxLC, _In_ DWORD cMEMs,
|
|
|
2400
2404
|
hdrRd32->Address = (DWORD)(pDMA->qwA + o);
|
|
2401
2405
|
} else {
|
|
2402
2406
|
hdrRd64->h.TypeFmt = TLP_MRd64;
|
|
2407
|
+
if(fATS) { hdrRd64->h.AT = ctx->bAT; }
|
|
2403
2408
|
hdrRd64->h.Length = (WORD)((cb < 0x1000) ? cb >> 2 : 0);
|
|
2404
2409
|
hdrRd64->RequesterID = ctx->wDeviceId;
|
|
2405
2410
|
hdrRd64->Tag = bTag;
|
|
@@ -2679,6 +2684,7 @@ VOID DeviceFPGA_Async2_Read_TxTlpSingle_MrdTlp(_In_ PLC_CONTEXT ctxLC, _In_ PDEV
|
|
|
2679
2684
|
PTLP_HDR_MRdWr32 hdrRd32 = (PTLP_HDR_MRdWr32)tx;
|
|
2680
2685
|
if(f32) {
|
|
2681
2686
|
hdrRd32->h.TypeFmt = TLP_MRd32;
|
|
2687
|
+
if(ctx->fATS) { hdrRd32->h.AT = ctx->bAT; }
|
|
2682
2688
|
hdrRd32->h.Length = wTlpDwLength;
|
|
2683
2689
|
hdrRd32->RequesterID = ctx->wDeviceId;
|
|
2684
2690
|
hdrRd32->Tag = iTag;
|
|
@@ -2687,6 +2693,7 @@ VOID DeviceFPGA_Async2_Read_TxTlpSingle_MrdTlp(_In_ PLC_CONTEXT ctxLC, _In_ PDEV
|
|
|
2687
2693
|
hdrRd32->Address = (DWORD)(qwA);
|
|
2688
2694
|
} else {
|
|
2689
2695
|
hdrRd64->h.TypeFmt = TLP_MRd64;
|
|
2696
|
+
if(ctx->fATS) { hdrRd32->h.AT = ctx->bAT; }
|
|
2690
2697
|
hdrRd64->h.Length = wTlpDwLength;
|
|
2691
2698
|
hdrRd64->RequesterID = ctx->wDeviceId;
|
|
2692
2699
|
hdrRd64->Tag = iTag;
|
|
@@ -3310,6 +3317,7 @@ VOID DeviceFPGA_ProbeMEM_Impl(_In_ PLC_CONTEXT ctxLC, _In_ QWORD qwAddr, _In_ DW
|
|
|
3310
3317
|
is32 = qwAddr + (i << 12) < 0x100000000;
|
|
3311
3318
|
if(is32) {
|
|
3312
3319
|
hdrRd32->h.TypeFmt = TLP_MRd32;
|
|
3320
|
+
if(ctx->fATS) { hdrRd32->h.AT = ctx->bAT; }
|
|
3313
3321
|
hdrRd32->h.Length = 1;
|
|
3314
3322
|
hdrRd32->RequesterID = ctx->wDeviceId;
|
|
3315
3323
|
hdrRd32->FirstBE = 0xf;
|
|
@@ -3318,6 +3326,7 @@ VOID DeviceFPGA_ProbeMEM_Impl(_In_ PLC_CONTEXT ctxLC, _In_ QWORD qwAddr, _In_ DW
|
|
|
3318
3326
|
hdrRd32->Tag = (BYTE)((i >> 5) & 0x1f); // 5 high address bits coded into tag.
|
|
3319
3327
|
} else {
|
|
3320
3328
|
hdrRd64->h.TypeFmt = TLP_MRd64;
|
|
3329
|
+
if(ctx->fATS) { hdrRd32->h.AT = ctx->bAT; }
|
|
3321
3330
|
hdrRd64->h.Length = 1;
|
|
3322
3331
|
hdrRd64->RequesterID = ctx->wDeviceId;
|
|
3323
3332
|
hdrRd64->FirstBE = 0xf;
|
|
@@ -3376,6 +3385,7 @@ BOOL DeviceFPGA_WriteMEM_TXP(_In_ PLC_CONTEXT ctxLC, _Inout_ PDEVICE_CONTEXT_FPG
|
|
|
3376
3385
|
memset(pbTlp, 0, 16);
|
|
3377
3386
|
if(pa < 0x100000000) {
|
|
3378
3387
|
hdrWr32->h.TypeFmt = TLP_MWr32;
|
|
3388
|
+
if(ctx->fATS) { hdrWr32->h.AT = ctx->bAT; }
|
|
3379
3389
|
hdrWr32->h.Length = (WORD)(cb + 3) >> 2;
|
|
3380
3390
|
hdrWr32->FirstBE = bFirstBE;
|
|
3381
3391
|
hdrWr32->LastBE = bLastBE;
|
|
@@ -3389,6 +3399,7 @@ BOOL DeviceFPGA_WriteMEM_TXP(_In_ PLC_CONTEXT ctxLC, _Inout_ PDEVICE_CONTEXT_FPG
|
|
|
3389
3399
|
cbTlp = (12 + cb + 3) & ~0x3;
|
|
3390
3400
|
} else {
|
|
3391
3401
|
hdrWr64->h.TypeFmt = TLP_MWr64;
|
|
3402
|
+
if(ctx->fATS) { hdrWr64->h.AT = ctx->bAT; }
|
|
3392
3403
|
hdrWr64->h.Length = (WORD)(cb + 3) >> 2;
|
|
3393
3404
|
hdrWr64->FirstBE = bFirstBE;
|
|
3394
3405
|
hdrWr64->LastBE = bLastBE;
|
|
@@ -3848,6 +3859,7 @@ BOOL DeviceFPGA_SetOption_DoLock(_In_ PLC_CONTEXT ctxLC, _In_ QWORD fOption, _In
|
|
|
3848
3859
|
#define FPGA_PARAMETER_DEVICE_ID "bdf"
|
|
3849
3860
|
#define FPGA_PARAMETER_DRIVER "driver"
|
|
3850
3861
|
#define FPGA_PARAMETER_FT601 "ft601"
|
|
3862
|
+
#define FPGA_PARAMETER_ATS "ats"
|
|
3851
3863
|
|
|
3852
3864
|
#define FPGA_PARAMETER_ALGO_TINY 0x01
|
|
3853
3865
|
#define FPGA_PARAMETER_ALGO_SYNCHRONOUS 0x02
|
|
@@ -3885,6 +3897,8 @@ BOOL DeviceFPGA_Open(_Inout_ PLC_CONTEXT ctxLC, _Out_opt_ PPLC_CONFIG_ERRORINFO
|
|
|
3885
3897
|
}
|
|
3886
3898
|
if(szDeviceError) { goto fail; }
|
|
3887
3899
|
ctx->fRestartDevice = (1 == LcDeviceParameterGetNumeric(ctxLC, FPGA_PARAMETER_RESTART_DEVICE));
|
|
3900
|
+
ctx->bAT = (BYTE)LcDeviceParameterGetNumeric(ctxLC, FPGA_PARAMETER_ATS);
|
|
3901
|
+
ctx->fATS = ((ctx->bAT >= 1) && (ctx->bAT <= 3));
|
|
3888
3902
|
DeviceFPGA_GetDeviceID_FpgaVersion(ctx);
|
|
3889
3903
|
if(!ctx->wFpgaVersionMajor) {
|
|
3890
3904
|
szDeviceError = "Unable to connect to FPGA device";
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// Windows 8+.
|
|
3
3
|
//
|
|
4
4
|
// The hibernation file format of Windows 8+ is documented in the excellent
|
|
5
|
-
// blog post by ForensicXlab at: https://www.forensicxlab.com/
|
|
5
|
+
// blog post by ForensicXlab at: https://www.forensicxlab.com/blog/hibernation
|
|
6
6
|
// Also the original paper at: https://www.cct.lsu.edu/~golden/Papers/sylvehiber.pdf
|
|
7
7
|
//
|
|
8
8
|
// (c) Ulf Frisk, 2024-2025
|
|
@@ -32,7 +32,7 @@ typedef struct tdHIBR_OFFSET {
|
|
|
32
32
|
} HIBR_OFFSET, *PHIBR_OFFSET;
|
|
33
33
|
|
|
34
34
|
const HIBR_OFFSET HIBR_OFFSET_PROFILES[] = {
|
|
35
|
-
{.LengthSelf = 0x4d8, .f32 = FALSE, .PageSize = 0x18, .SystemTime = 0x20, .NumPagesForLoader = 0x58, .FirstBootRestorePage = 0x68, .FirstKernelRestorePage = 0x70, .KernelPagesProcessed =
|
|
35
|
+
{.LengthSelf = 0x4d8, .f32 = FALSE, .PageSize = 0x18, .SystemTime = 0x20, .NumPagesForLoader = 0x58, .FirstBootRestorePage = 0x68, .FirstKernelRestorePage = 0x70, .KernelPagesProcessed = 0x238, .HighestPhysicalPage = 0x498}, // 64-bit build 26100
|
|
36
36
|
{.LengthSelf = 0x448, .f32 = FALSE, .PageSize = 0x18, .SystemTime = 0x20, .NumPagesForLoader = 0x58, .FirstBootRestorePage = 0x68, .FirstKernelRestorePage = 0x70, .KernelPagesProcessed = 0x230, .HighestPhysicalPage = 0x400}, // 64-bit build 22621
|
|
37
37
|
{.LengthSelf = 0x448, .f32 = FALSE, .PageSize = 0x18, .SystemTime = 0x20, .NumPagesForLoader = 0x58, .FirstBootRestorePage = 0x68, .FirstKernelRestorePage = 0x70, .KernelPagesProcessed = 0x230, .HighestPhysicalPage = 0x400}, // 64-bit build 22000
|
|
38
38
|
{.LengthSelf = 0x448, .f32 = FALSE, .PageSize = 0x18, .SystemTime = 0x20, .NumPagesForLoader = 0x58, .FirstBootRestorePage = 0x68, .FirstKernelRestorePage = 0x70, .KernelPagesProcessed = 0x230, .HighestPhysicalPage = 0x400}, // 64-bit build 20348
|
|
@@ -109,7 +109,7 @@ typedef struct tdHIBR_COMPRESSION_SET_TABLE {
|
|
|
109
109
|
HIBR_COMPRESSION_SET v[HIBR_COMPRESSION_TABLE_SIZE];
|
|
110
110
|
} HIBR_COMPRESSION_SET_TABLE, *PHIBR_COMPRESSION_SET_TABLE;
|
|
111
111
|
|
|
112
|
-
typedef struct
|
|
112
|
+
typedef struct tdDEVICE_CONTEXT_HIBRFILE {
|
|
113
113
|
FILE *hFile;
|
|
114
114
|
QWORD cbFile;
|
|
115
115
|
CHAR szFileName[MAX_PATH];
|
|
@@ -128,7 +128,7 @@ typedef struct tdDEVICE_CONTEXT_FILE {
|
|
|
128
128
|
} CS_Cache[HIBR_NUM_CACHE_ENTRIES];
|
|
129
129
|
BYTE pbBufferCompressedData[0x10000];
|
|
130
130
|
BYTE pbWorkSpace[0x00100000];
|
|
131
|
-
}
|
|
131
|
+
} DEVICE_CONTEXT_HIBRFILE, *PDEVICE_CONTEXT_HIBRFILE;
|
|
132
132
|
|
|
133
133
|
|
|
134
134
|
//-----------------------------------------------------------------------------
|
|
@@ -143,7 +143,7 @@ typedef struct tdDEVICE_CONTEXT_FILE {
|
|
|
143
143
|
* -- return = TRUE on success, FALSE on failure.
|
|
144
144
|
*/
|
|
145
145
|
_Success_(return)
|
|
146
|
-
BOOL DeviceHibr_InitializeFunctions(_In_
|
|
146
|
+
BOOL DeviceHibr_InitializeFunctions(_In_ PDEVICE_CONTEXT_HIBRFILE ctx)
|
|
147
147
|
{
|
|
148
148
|
HMODULE hNtDll = NULL;
|
|
149
149
|
if((hNtDll = LoadLibraryA("ntdll.dll"))) {
|
|
@@ -208,7 +208,7 @@ NTSTATUS OSCOMPAT_RtlDecompressBufferEx(USHORT CompressionFormat, PUCHAR Uncompr
|
|
|
208
208
|
* -- return = TRUE on success, FALSE on failure.
|
|
209
209
|
*/
|
|
210
210
|
_Success_(return)
|
|
211
|
-
BOOL DeviceHibr_InitializeFunctions(_In_
|
|
211
|
+
BOOL DeviceHibr_InitializeFunctions(_In_ PDEVICE_CONTEXT_HIBRFILE ctx)
|
|
212
212
|
{
|
|
213
213
|
void *lib_mscompress;
|
|
214
214
|
CHAR szPathLib[MAX_PATH] = { 0 };
|
|
@@ -241,7 +241,7 @@ BOOL DeviceHibr_InitializeFunctions(_In_ PDEVICE_CONTEXT_FILE ctx)
|
|
|
241
241
|
_Success_(return != NULL)
|
|
242
242
|
PBYTE DeviceHibr_ReadPage(_In_ PLC_CONTEXT ctxLC, _In_ PHIBR_COMPRESSION_SET pCS, _In_ DWORD iCS, _In_ DWORD iPG)
|
|
243
243
|
{
|
|
244
|
-
|
|
244
|
+
PDEVICE_CONTEXT_HIBRFILE ctx = (PDEVICE_CONTEXT_HIBRFILE)ctxLC->hDevice;
|
|
245
245
|
NTSTATUS nt;
|
|
246
246
|
PBYTE pbBufferUncompressed;
|
|
247
247
|
DWORD i, cbUncompressed, cbUncompressedResult = 0;
|
|
@@ -287,7 +287,7 @@ PBYTE DeviceHibr_ReadPage(_In_ PLC_CONTEXT ctxLC, _In_ PHIBR_COMPRESSION_SET pCS
|
|
|
287
287
|
*/
|
|
288
288
|
VOID DeviceHibr_ReadScatter(_In_ PLC_CONTEXT ctxLC, _In_ DWORD cpMEMs, _Inout_ PPMEM_SCATTER ppMEMs)
|
|
289
289
|
{
|
|
290
|
-
|
|
290
|
+
PDEVICE_CONTEXT_HIBRFILE ctx = (PDEVICE_CONTEXT_HIBRFILE)ctxLC->hDevice;
|
|
291
291
|
DWORD iMEM, iCS, iPG;
|
|
292
292
|
QWORD qwPfn;
|
|
293
293
|
PBYTE pbPage;
|
|
@@ -335,7 +335,7 @@ VOID DeviceHibr_ReadScatter(_In_ PLC_CONTEXT ctxLC, _In_ DWORD cpMEMs, _Inout_ P
|
|
|
335
335
|
*/
|
|
336
336
|
VOID DeviceHibr_HibrInitialize_RestoreSet(_In_ PLC_CONTEXT ctxLC, _In_ QWORD cbo, _In_ QWORD cPageTotal)
|
|
337
337
|
{
|
|
338
|
-
|
|
338
|
+
PDEVICE_CONTEXT_HIBRFILE ctx = (PDEVICE_CONTEXT_HIBRFILE)ctxLC->hDevice;
|
|
339
339
|
BOOL fWarning = FALSE;
|
|
340
340
|
BYTE i, j, cDescCS;
|
|
341
341
|
BYTE pb[0x1000];
|
|
@@ -356,8 +356,8 @@ restart:
|
|
|
356
356
|
if(fread(pb, 1, sizeof(pb), ctx->hFile) != sizeof(pb)) { return; }
|
|
357
357
|
dwStatusCS = *(PDWORD)(pb + 0x000);
|
|
358
358
|
cDescCS = dwStatusCS & 0xff;
|
|
359
|
-
pCS->cb = (dwStatusCS >> 8) &
|
|
360
|
-
pCS->tp = (dwStatusCS &
|
|
359
|
+
pCS->cb = (dwStatusCS >> 8) & 0x0fffff;
|
|
360
|
+
pCS->tp = (dwStatusCS & 0xC0000000) ? COMPRESS_ALGORITHM_XPRESS_HUFF : COMPRESS_ALGORITHM_XPRESS;
|
|
361
361
|
if(!cDescCS || !pCS->cb) { return; }
|
|
362
362
|
// 2: iterate over page descriptors in the compression set.
|
|
363
363
|
pbo = 4;
|
|
@@ -381,7 +381,7 @@ restart:
|
|
|
381
381
|
pCS->cpg += (WORD)cDescPages;
|
|
382
382
|
}
|
|
383
383
|
if((pCS->cpg > 0x10) && !fWarning) {
|
|
384
|
-
lcprintf(ctxLC, "DEVICE: HIBR: WARNING: COMPRESSION SET #PAGES >
|
|
384
|
+
lcprintf(ctxLC, "DEVICE: HIBR: WARNING: COMPRESSION SET #PAGES > 16 (only showed once).\n");
|
|
385
385
|
fWarning = TRUE;
|
|
386
386
|
}
|
|
387
387
|
if(pCS->cb == ((DWORD)pCS->cpg << 12)) {
|
|
@@ -404,7 +404,7 @@ restart:
|
|
|
404
404
|
_Success_(return)
|
|
405
405
|
BOOL DeviceHibr_HibrInitialize(_In_ PLC_CONTEXT ctxLC)
|
|
406
406
|
{
|
|
407
|
-
|
|
407
|
+
PDEVICE_CONTEXT_HIBRFILE ctx = (PDEVICE_CONTEXT_HIBRFILE)ctxLC->hDevice;
|
|
408
408
|
BYTE pb[0x1000];
|
|
409
409
|
DWORD i, cbPO_MEMORY_IMAGE;
|
|
410
410
|
QWORD cboRestoreBoot = 0, cboRestoreKernel = 0, cPagesLoader = 0, cPagesKernel = 0;
|
|
@@ -462,7 +462,7 @@ fail:
|
|
|
462
462
|
// OPEN/CLOSE FUNCTIONALITY BELOW:
|
|
463
463
|
//-----------------------------------------------------------------------------
|
|
464
464
|
|
|
465
|
-
VOID DeviceHibr_CloseInternal(_Frees_ptr_opt_
|
|
465
|
+
VOID DeviceHibr_CloseInternal(_Frees_ptr_opt_ PDEVICE_CONTEXT_HIBRFILE ctx)
|
|
466
466
|
{
|
|
467
467
|
DWORD i;
|
|
468
468
|
if(ctx) {
|
|
@@ -477,7 +477,7 @@ VOID DeviceHibr_CloseInternal(_Frees_ptr_opt_ PDEVICE_CONTEXT_FILE ctx)
|
|
|
477
477
|
|
|
478
478
|
VOID DeviceHibr_Close(_Inout_ PLC_CONTEXT ctxLC)
|
|
479
479
|
{
|
|
480
|
-
|
|
480
|
+
PDEVICE_CONTEXT_HIBRFILE ctx = (PDEVICE_CONTEXT_HIBRFILE)ctxLC->hDevice;
|
|
481
481
|
DeviceHibr_CloseInternal(ctx);
|
|
482
482
|
}
|
|
483
483
|
|
|
@@ -492,11 +492,11 @@ VOID DeviceHibr_Close(_Inout_ PLC_CONTEXT ctxLC)
|
|
|
492
492
|
_Success_(return)
|
|
493
493
|
BOOL DeviceHIBR_Open(_Inout_ PLC_CONTEXT ctxLC, _Out_opt_ PPLC_CONFIG_ERRORINFO ppLcCreateErrorInfo)
|
|
494
494
|
{
|
|
495
|
-
|
|
495
|
+
PDEVICE_CONTEXT_HIBRFILE ctx;
|
|
496
496
|
PLC_DEVICE_PARAMETER_ENTRY pParam;
|
|
497
497
|
QWORD tmEnd = 0, tmStart = GetTickCount64();
|
|
498
498
|
if(ppLcCreateErrorInfo) { *ppLcCreateErrorInfo = NULL; }
|
|
499
|
-
if(!(ctx = (
|
|
499
|
+
if(!(ctx = (PDEVICE_CONTEXT_HIBRFILE)LocalAlloc(LMEM_ZEROINIT, sizeof(DEVICE_CONTEXT_HIBRFILE)))) { return FALSE; }
|
|
500
500
|
if(!(ctx->CS_Directory[0] = (PHIBR_COMPRESSION_SET_TABLE)LocalAlloc(LMEM_ZEROINIT, sizeof(HIBR_COMPRESSION_SET_TABLE)))) { goto fail; }
|
|
501
501
|
ctx->cCS = 1; // 0 = reserved for invalid/not set compression set.
|
|
502
502
|
if(0 == _strnicmp("hibr://", ctxLC->Config.szDevice, 7)) {
|
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
|
|
4
4
|
#define VERSION_MAJOR 2
|
|
5
5
|
#define VERSION_MINOR 22
|
|
6
|
-
#define VERSION_REVISION
|
|
7
|
-
#define VERSION_BUILD
|
|
6
|
+
#define VERSION_REVISION 3
|
|
7
|
+
#define VERSION_BUILD 89
|
|
8
8
|
|
|
9
9
|
#define VER_FILE_DESCRIPTION_STR "LeechCore Memory Acquisition Library"
|
|
10
10
|
#define VER_FILE_VERSION VERSION_MAJOR, VERSION_MINOR, VERSION_REVISION, VERSION_BUILD
|
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
|
|
6
6
|
#define VERSION_MAJOR 2
|
|
7
7
|
#define VERSION_MINOR 22
|
|
8
|
-
#define VERSION_REVISION
|
|
9
|
-
#define VERSION_BUILD
|
|
8
|
+
#define VERSION_REVISION 2
|
|
9
|
+
#define VERSION_BUILD 88
|
|
10
10
|
|
|
11
11
|
#define VER_FILE_DESCRIPTION_STR "LeechCorePlugin : RAWTCP"
|
|
12
12
|
#define VER_FILE_VERSION VERSION_MAJOR, VERSION_MINOR, VERSION_REVISION, VERSION_BUILD
|
|
@@ -19,7 +19,7 @@ leechcorepyc = Extension(
|
|
|
19
19
|
|
|
20
20
|
setup(
|
|
21
21
|
name='leechcorepyc',
|
|
22
|
-
version='2.22.
|
|
22
|
+
version='2.22.3', # VERSION_END
|
|
23
23
|
description='LeechCore for Python',
|
|
24
24
|
long_description='LeechCore for Python : native extension for physical memory access',
|
|
25
25
|
url='https://github.com/ufrisk/LeechCore',
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{leechcorepyc-2.22.1 → leechcorepyc-2.22.3}/leechcore_device_rawtcp/leechcore_device_rawtcp.c
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|