From 64c8b1c22d9534ba0dc48267a3558caeb3bd5ab1 Mon Sep 17 00:00:00 2001 From: xerox Date: Sun, 28 Jun 2020 13:16:46 +0000 Subject: [PATCH] Update main.cpp --- physmeme/main.cpp | 22 +++++++++------------- 1 file changed, 9 insertions(+), 13 deletions(-) diff --git a/physmeme/main.cpp b/physmeme/main.cpp index 92de911..df2b102 100644 --- a/physmeme/main.cpp +++ b/physmeme/main.cpp @@ -36,20 +36,16 @@ int __cdecl main(int argc, char** argv) // // shoot the tires off piddb cache entry. // - //const auto drv_timestamp = util::get_file_header((void*)raw_driver)->TimeDateStamp; - //printf("[+] clearing piddb cache for driver: %s, with timestamp 0x%x\n", physmeme::drv_key.c_str(), drv_timestamp); - - // - // uncomment at your own risk! - // - - //if (!ctx.clear_piddb_cache(physmeme::drv_key, drv_timestamp)) - //{ + const auto drv_timestamp = util::get_file_header((void*)raw_driver)->TimeDateStamp; + printf("[+] clearing piddb cache for driver: %s, with timestamp 0x%x\n", physmeme::drv_key.c_str(), drv_timestamp); + + if (!ctx.clear_piddb_cache(physmeme::drv_key, drv_timestamp)) + { // this is because the signature might be broken on these versions of windows. - //perror("[-] failed to clear PiDDBCacheTable.\n"); - //return -1; - //} - //printf("[+] cleared piddb cache...\n"); + perror("[-] failed to clear PiDDBCacheTable.\n"); + return -1; + } + printf("[+] cleared piddb cache...\n"); // // lambdas used for fixing driver image