mirror of https://github.com/tongzx/nt5src
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
CryptoAlgo-Dev
75c48ba87f
|
4 years ago | |
---|---|---|
.. | ||
cleanupwiz.cpp | 4 years ago | |
cleanupwiz.h | 4 years ago | |
dblnul.cpp | 4 years ago | |
dblnul.h | 4 years ago | |
desktop_cleanup.bmp | 4 years ago | |
desktop_cleanup_hd.bmp | 4 years ago | |
dll.cpp | 4 years ago | |
fldrclnr.def | 4 years ago | |
fldrclnr.ico | 4 years ago | |
fldrclnr.rc | 4 years ago | |
fldrclnr.rcv | 4 years ago | |
makefile | 4 years ago | |
priv.h | 4 years ago | |
readme.rtf | 4 years ago | |
resource.h | 4 years ago | |
silent.cpp | 4 years ago | |
sources | 4 years ago | |
windowsshell.manifest | 4 years ago |
readme.rtf
{\rtf1\ansi\ansicpg1252\uc1 \deff0\deflang1033\deflangfe1033{\fonttbl{\f0\froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}{\f30\froman\fcharset238\fprq2 Times New Roman CE;}{\f31\froman\fcharset204\fprq2 Times New Roman Cyr;}
{\f33\froman\fcharset161\fprq2 Times New Roman Greek;}{\f34\froman\fcharset162\fprq2 Times New Roman Tur;}{\f35\froman\fcharset177\fprq2 Times New Roman (Hebrew);}{\f36\froman\fcharset178\fprq2 Times New Roman (Arabic);}
{\f37\froman\fcharset186\fprq2 Times New Roman Baltic;}}{\colortbl;\red0\green0\blue0;\red0\green0\blue255;\red0\green255\blue255;\red0\green255\blue0;\red255\green0\blue255;\red255\green0\blue0;\red255\green255\blue0;\red255\green255\blue255;
\red0\green0\blue128;\red0\green128\blue128;\red0\green128\blue0;\red128\green0\blue128;\red128\green0\blue0;\red128\green128\blue0;\red128\green128\blue128;\red192\green192\blue192;}{\stylesheet{
\ql \li0\ri0\widctlpar\aspalpha\aspnum\faauto\adjustright\rin0\lin0\itap0 \fs24\lang1033\langfe1033\cgrid\langnp1033\langfenp1033 \snext0 Normal;}{\s1\ql \li0\ri0\keepn\widctlpar\aspalpha\aspnum\faauto\adjustright\rin0\lin0\itap0
\b\fs32\lang1033\langfe1033\cgrid\langnp1033\langfenp1033 \sbasedon0 \snext0 heading 1;}{\s2\ql \li0\ri0\keepn\widctlpar\aspalpha\aspnum\faauto\adjustright\rin0\lin0\itap0 \fs28\lang1033\langfe1033\cgrid\langnp1033\langfenp1033 \sbasedon0 \snext0
heading 2;}{\*\cs10 \additive Default Paragraph Font;}{\s15\ql \li1260\ri0\widctlpar\aspalpha\aspnum\faauto\adjustright\rin0\lin1260\itap0 \fs24\lang1033\langfe1033\cgrid\langnp1033\langfenp1033 \sbasedon0 \snext15 Body Text 2;}}{\info
{\title Desktop Folder Cleanup Utility}{\author Arish Ali (RIS)}{\operator Arish Ali (RIS)}{\creatim\yr2000\mo10\dy16\hr10\min59}{\revtim\yr2000\mo10\dy18\hr9\min55}{\version5}{\edmins17}{\nofpages2}{\nofwords416}{\nofchars2372}{\*\company Microsoft}
{\nofcharsws0}{\vern8269}}\widowctrl\ftnbj\aenddoc\noxlattoyen\expshrtn\noultrlspc\dntblnsbdb\nospaceforul\hyphcaps0\formshade\horzdoc\dgmargin\dghspace180\dgvspace180\dghorigin1701\dgvorigin1984\dghshow1\dgvshow1
\jexpand\viewkind4\viewscale100\pgbrdrhead\pgbrdrfoot\splytwnine\ftnlytwnine\htmautsp\nolnhtadjtbl\useltbaln\alntblind\lytcalctblwd\lyttblrtgr\lnbrkrule \fet0\sectd \linex0\endnhere\sectlinegrid360\sectdefaultcl {\*\pnseclvl1
\pnucrm\pnstart1\pnindent720\pnhang{\pntxta .}}{\*\pnseclvl2\pnucltr\pnstart1\pnindent720\pnhang{\pntxta .}}{\*\pnseclvl3\pndec\pnstart1\pnindent720\pnhang{\pntxta .}}{\*\pnseclvl4\pnlcltr\pnstart1\pnindent720\pnhang{\pntxta )}}{\*\pnseclvl5
\pndec\pnstart1\pnindent720\pnhang{\pntxtb (}{\pntxta )}}{\*\pnseclvl6\pnlcltr\pnstart1\pnindent720\pnhang{\pntxtb (}{\pntxta )}}{\*\pnseclvl7\pnlcrm\pnstart1\pnindent720\pnhang{\pntxtb (}{\pntxta )}}{\*\pnseclvl8\pnlcltr\pnstart1\pnindent720\pnhang
{\pntxtb (}{\pntxta )}}{\*\pnseclvl9\pnlcrm\pnstart1\pnindent720\pnhang{\pntxtb (}{\pntxta )}}\pard\plain \s1\ql \li0\ri0\keepn\widctlpar\aspalpha\aspnum\faauto\outlinelevel0\adjustright\rin0\lin0\itap0
\b\fs32\lang1033\langfe1033\cgrid\langnp1033\langfenp1033 {Desktop Folder Cleanup Utility
\par }\pard\plain \ql \li0\ri0\widctlpar\aspalpha\aspnum\faauto\adjustright\rin0\lin0\itap0 \fs24\lang1033\langfe1033\cgrid\langnp1033\langfenp1033 {
\par Sourcepath: }{\b nt\\shell\\applets\\cleanup\\fldrclnr\\}{
\par Binary: }{\b fldrclnr.dll}{
\par
\par Installation directory }{\b %windir%\\system32\\}{ }{\cf6 (}{\b\cf6 NOT YET ADDED TO SETUP}{\cf6 )
\par }{
\par Entrypoints: }{\b Regsvr32 /i fldrclnr.dll}{
\par }\pard \ql \li720\ri0\widctlpar\aspalpha\aspnum\faauto\adjustright\rin0\lin720\itap0 { This creates a scheduled task to run it every 60 days by default.
\par }\pard \ql \li0\ri0\widctlpar\aspalpha\aspnum\faauto\adjustright\rin0\lin0\itap0 {\tab
\par }{\b Rundll32 fldrclnr.dll,Wizard_RunDLL
\par }\pard\plain \s15\ql \li1260\ri0\widctlpar\aspalpha\aspnum\faauto\adjustright\rin0\lin1260\itap0 \fs24\lang1033\langfe1033\cgrid\langnp1033\langfenp1033 {
Launches wizard with a balloon tip user notification in the task bar if there are items to be cleaned. Only shows items that need to be cleaned up.
\par }\pard\plain \ql \li0\ri0\widctlpar\aspalpha\aspnum\faauto\adjustright\rin0\lin0\itap0 \fs24\lang1033\langfe1033\cgrid\langnp1033\langfenp1033 {
\par }{\b Rundll32 fldrclnr.dll,Wizard_RunDLL all
\par }\pard \ql \li1260\ri0\widctlpar\aspalpha\aspnum\faauto\adjustright\rin0\lin1260\itap0 {Launches wizard without notifications. Shows all shortcuts and regitems, marks as selected only the ones that are old.
\par
\par }\pard \ql \li0\ri0\widctlpar\aspalpha\aspnum\faauto\adjustright\rin0\lin0\itap0 {Registry Settings: }{\b\cf6 (THIS NEEDS TO BE CONFIRMED WITH POLICY TEAM)}{
\par }{\b Software\\\\Microsoft\\\\Windows\\\\CurrentVersion\\\\Policies\\\\Desktop\\\\CleanupWiz\tab
\par }\pard \ql \li720\ri0\widctlpar\aspalpha\aspnum\faauto\adjustright\rin0\lin720\itap0 {A DWORD value named \'93}{\b Days between clean up}{\'94 stores the value to override the default 60 days clean up period.
\par }\pard \ql \li0\ri0\widctlpar\aspalpha\aspnum\faauto\adjustright\rin0\lin0\itap0 {
\par }\pard\plain \s2\ql \li0\ri0\keepn\widctlpar\aspalpha\aspnum\faauto\outlinelevel1\adjustright\rin0\lin0\itap0 \fs28\lang1033\langfe1033\cgrid\langnp1033\langfenp1033 {Description of how it works
\par }\pard\plain \ql \li0\ri0\widctlpar\aspalpha\aspnum\faauto\adjustright\rin0\lin0\itap0 \fs24\lang1033\langfe1033\cgrid\langnp1033\langfenp1033 {\tab The scheduled task to launch this wizard is created whenever a new u
ser logs in. The name of this task is based on the user\rquote s name, for example, \'93John Doe\rquote s Desktop Cleanup Monitor\'94. For the case of different user on different domains having the same user name, we append the user account\rquote
s guid to the task name.
\par \tab This task
is scheduled to run daily, but only if the user is logged on. When this task runs, the first thing it does is that it checks the last run time and finds out how many days its supposed to wait between cleanup (default 60 days, can be overridden by policy)
.
If those many days have elapsed since it last ran it launches the cleanup process. (The point of the task running daily is that if an administrator changes the policy value, we pick it up within a day, instead of waiting till the wizard runs, which coul
d be as many as 60 days).
\par \tab The cleanup process first finds out if there are any unused items on the desktops, by definition, unused items are items that have not been used since the wizard last ran. If there are no such items, it just records the last run a
nd ends. Otherwise, it pops up a notification balloon. The balloon shows up three times, for 10 seconds each with 15 seconds interval in between. If the user does not click on it, we just log the last run time and finish. If the user clicks on the notific
ation, the wizard UI shows up, and guides the user through as per the specs.
\par
\par \tab The only items we consider while cleaning up are shortcuts (which support IShellLink interface) and regitems. There is code in defview that tracks this usage, so we have accurate last used times. For shortcuts, we simply move the file
to the Unused Desktop Files folder, which the user can drag back if he wants to restore it. We have a slightly complicated procedure for handling regitems, which is explained below.
\par
\par }{\b Cleaning Up Regitems}{:
\par \tab A regitem is an icon that you see on the desktop because of some settings added to the registry. There is no physical file
in the desktop folder for that item. As these kind of regitems can only be created in special registry folders like the desktop folders, there is no way to create them in the Unused Desktop Files folder, which is a normal file system folder. So what we do
is that we create a file in Unused Desktop Files folder which has a filename \'93Name.\{CLSID\}\'94, where the CLSID is the CLSID of the registry item. For example, for outlook we will create a file called \'93Microsoft Outlook. \{
00020D75-0000-0000-C000-000000000046\}\'94. The cool thing about these }{\b\fs20 .\{CLSID\}}{
files is that shell treats this objects as special and makes them behave same as the corresponding regitem. So this file will have the same icon and all the right click menu options of the corresponding regitem on the
desktop. So, we create this file and mark the regitem as hidden on the desktop. So as far as the user is concerned he just moved this item to the Unused Desktop Filse folder.
\par \tab However, this file is not quite the same thing as the regitem, as it has some extra options on the right click menu. So in case the user restores this file from the Unused folder and puts it back on th
e desktop, we try to restore the regitem when we get a chance. What we do is that whenever the wizard runs, while enumerating all the items on the desktop it actually checks if there is a }{\b\fs20 .\{CLSID}{\} file on the desktop.
Then it verifies if there is a regitem on the desktop for the CLSID that has been marked as hidden. And then if both the file and the regitem have the same display name, we delete the file and re-enable the regitem.
\par \tab Also, because we do not track usage of the }{\b\fs20 .\{CLSID\}}{ files on the desktop (we potentially could), when we re-enable the regitem we mark it as having been used at that time so that it is not cleaned up again immediately.
\par \tab Confused? Please ping me, and I\rquote ll explain it to you.
\par \tab
\par - Arish Ali (10/18/00).
\par
\par
\par }}