(imported topic written by Kvetch91)
I am trying to write an analysis that only spits out the values of the usbstor key if the last write time of that key is <86400*second from current time or last report time but I keep getting errors. There are multiple posts that just write out the usbstor key and their associated last write time but I would like to only have it list the values if it has been modified since it was last run. Would anyone know if there is a way to do this? I have been trying stuff like
if ((now - last write time of key “HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\USBSTOR” of registry) < 86400 * second) then …)
Is there a way I can write the query to say something like
If last write time of key “HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\USBSTOR” is less than last run or reported time or if that isn’t possible less than 24hours then dump the values of the subkeys?
Thanks