VirtualBox

Changeset 52972 in vbox for trunk


Ignore:
Timestamp:
Oct 7, 2014 9:44:02 AM (10 years ago)
Author:
vboxsync
Message:

supR3HardNtChildPurify: Logging improvements.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/HostDrivers/Support/win/SUPR3HardenedMain-win.cpp

    r52969 r52972  
    34893489     * load events or (much better for us) later events like kernel32.
    34903490     */
    3491     uint32_t cMsFudge = g_fSupAdversaries ? 512 : 256;
     3491    uint64_t uMsTsOuterStart = supR3HardenedWinGetMilliTS();
     3492    uint32_t cMsFudge        = g_fSupAdversaries ? 512 : 256;
     3493    uint32_t cTotalFixes     = 0;
    34923494    uint32_t cFixes;
    34933495    for (uint32_t iLoop = 0; iLoop < 16; iLoop++)
     
    35073509        } while (   supR3HardenedWinGetMilliTS() - uMsTsStart <= cMsFudge
    35083510                 || cSleeps < 8);
    3509         SUP_DPRINTF(("supR3HardenedWinInit: Startup delay kludge #2/%u: %u ms, %u sleeps\n",
     3511        SUP_DPRINTF(("supR3HardNtChildPurify: Startup delay kludge #1/%u: %u ms, %u sleeps\n",
    35103512                     iLoop, supR3HardenedWinGetMilliTS() - uMsTsStart, cSleeps));
    35113513
     
    35203522                                      "supHardenedWinVerifyProcess failed with %Rrc: %s", g_ErrInfoStatic.szMsg);
    35213523        if (cFixes == 0)
     3524        {
     3525            SUP_DPRINTF(("supR3HardNtChildPurify: Done after %llu ms and %u fixes (loop #%u).\n",
     3526                         supR3HardenedWinGetMilliTS() - uMsTsOuterStart, cTotalFixes, iLoop));
    35223527            return; /* We're probably good. */
     3528        }
     3529        cTotalFixes += cFixes;
    35233530
    35243531        if (!g_fSupAdversaries)
     
    35343541                                                 &cPatchCount, sizeof(cPatchCount), NULL);
    35353542        if (NT_SUCCESS(rcNt))
    3536             SUP_DPRINTF(("supR3HardenedWinInit: cFixes=%u g_fSupAdversaries=%#x cPatchCount=%#u\n",
     3543            SUP_DPRINTF(("supR3HardNtChildPurify: cFixes=%u g_fSupAdversaries=%#x cPatchCount=%#u\n",
    35373544                         cFixes, g_fSupAdversaries, cPatchCount));
    35383545        else
    3539             SUP_DPRINTF(("supR3HardenedWinInit: cFixes=%u g_fSupAdversaries=%#x\n", cFixes, g_fSupAdversaries));
     3546            SUP_DPRINTF(("supR3HardNtChildPurify: cFixes=%u g_fSupAdversaries=%#x\n", cFixes, g_fSupAdversaries));
    35403547    }
    35413548
     
    35453552     */
    35463553    supR3HardenedWinKillChild(pThis, "supR3HardNtChildPurify", VERR_TRY_AGAIN,
    3547                               "Unable to purify child process! After 16 tries, we still %u fix(es) in the last pass.",
    3548                               cFixes);
     3554                              "Unable to purify child process! After 16 tries over %llu ms, we still %u fix(es) in the last pass.",
     3555                              supR3HardenedWinGetMilliTS() - uMsTsOuterStart, cFixes);
    35493556}
    35503557
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette