author | Oleksandr Gavenko <gavenkoa@gmail.com> |
Fri, 27 Apr 2012 16:19:03 +0300 | |
changeset 1267 | d2a8da11f9d7 |
parent 1203 | bd2a6d024b5f |
child 1334 | 9bf0d5a1f0cf |
permissions | -rw-r--r-- |
940 | 1 |
.. -*- coding: utf-8; -*- |
2 |
||
3 |
============= |
|
4 |
Windows OS. |
|
5 |
============= |
|
6 |
.. contents:: |
|
7 |
||
8 |
Determining windows version. |
|
9 |
============================ |
|
10 |
||
11 |
Run winver.exe: <Win> + R winver <RET>. |
|
12 |
||
13 |
Or type: <Win> + <Break>. |
|
14 |
||
15 |
Under cmd.exe use built-in command ver. |
|
16 |
||
17 |
For Win 2000 and upper check registry key:: |
|
18 |
||
19 |
cmd> reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion" /v CurrentVersion |
|
20 |
||
21 |
To check 32/64-bit OS use PROCESSOR_ARCHITECTURE env var (it has such values: |
|
22 |
x86, AMD64, IA64). |
|
23 |
||
1160
1e36e3b98d35
Full info about Windows edition available from this .vbs
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1116
diff
changeset
|
24 |
Full info about Windows edition available from this .vbs:: |
1e36e3b98d35
Full info about Windows edition available from this .vbs
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1116
diff
changeset
|
25 |
|
1e36e3b98d35
Full info about Windows edition available from this .vbs
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1116
diff
changeset
|
26 |
cmd> slmgr -dli |
1e36e3b98d35
Full info about Windows edition available from this .vbs
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1116
diff
changeset
|
27 |
|
940 | 28 |
Windows update. |
29 |
=============== |
|
30 |
||
31 |
To find updates and drivers visit (подлинность Windows not checked): |
|
32 |
||
33 |
http://catalog.update.microsoft.com/ |
|
34 |
||
35 |
You can search driver by keywords from Device Manager like:: |
|
36 |
||
37 |
VEN_10DE DEV_0247 |
|
38 |
VID_22B8 PID_2A62 |
|
39 |
||
40 |
Also you can find updates on: |
|
41 |
||
42 |
http://www.microsoft.com/downloads/ru-ru/default.aspx |
|
43 |
||
1163
a2cb3ae7117d
Updates that reset pirate copy of Windows
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1162
diff
changeset
|
44 |
Updates that reset pirate copy of Windows: КВ971033. |
a2cb3ae7117d
Updates that reset pirate copy of Windows
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1162
diff
changeset
|
45 |
|
940 | 46 |
Check system files integrity. |
47 |
============================= |
|
48 |
:: |
|
49 |
||
50 |
cmd> sfc /Scannow |
|
51 |
||
52 |
To complete repair you may need original installation CD (you can mount it |
|
53 |
from .iso image for example with DemonTools). |
|
54 |
||
55 |
Works for Windows 2000, Windows XP, Windows 2003. |
|
56 |
||
57 |
See |
|
58 |
||
59 |
http://support.microsoft.com/kb/222471/ |
|
60 |
http://support.microsoft.com/kb/310747/ru |
|
61 |
||
62 |
Repair boot. |
|
63 |
============ |
|
64 |
||
65 |
If you only damage boot sector of master or system partition boot from Windows |
|
66 |
XP installation CD, enter to recovery console and run: |
|
67 |
||
68 |
cmd> fixboot |
|
69 |
cmd> fixmbr |
|
70 |
||
71 |
See |
|
72 |
||
73 |
http://support.microsoft.com/kb/307654/ru |
|
74 |
||
75 |
Automatically connect to shared resource. |
|
76 |
========================================= |
|
77 |
||
78 |
Add to autorun such .bat file: |
|
79 |
||
80 |
net use x: \\server\share /user:username password |
|
81 |
||
82 |
See |
|
83 |
||
84 |
http://www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-us/net_use.mspx |
|
85 |
||
1161
4b6c690eef22
Activate Windows from command line
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1160
diff
changeset
|
86 |
Activate Windows. |
940 | 87 |
================= |
88 |
||
1161
4b6c690eef22
Activate Windows from command line
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1160
diff
changeset
|
89 |
Activate Windows from command line:: |
4b6c690eef22
Activate Windows from command line
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1160
diff
changeset
|
90 |
|
4b6c690eef22
Activate Windows from command line
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1160
diff
changeset
|
91 |
cmd> slmgr -ipk YGR45-THIS9-WONT5–0WORK-D7667 |
4b6c690eef22
Activate Windows from command line
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1160
diff
changeset
|
92 |
|
1162
f5c42c3804d6
Reset the evaluation period/licensing status and activation state of the
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1161
diff
changeset
|
93 |
Reset the evaluation period/licensing status and activation state of the |
f5c42c3804d6
Reset the evaluation period/licensing status and activation state of the
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1161
diff
changeset
|
94 |
machine:: |
f5c42c3804d6
Reset the evaluation period/licensing status and activation state of the
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1161
diff
changeset
|
95 |
|
f5c42c3804d6
Reset the evaluation period/licensing status and activation state of the
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1161
diff
changeset
|
96 |
cmd> slmgr -rearm |
f5c42c3804d6
Reset the evaluation period/licensing status and activation state of the
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1161
diff
changeset
|
97 |
|
1161
4b6c690eef22
Activate Windows from command line
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1160
diff
changeset
|
98 |
See: |
4b6c690eef22
Activate Windows from command line
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1160
diff
changeset
|
99 |
|
940 | 100 |
http://www.microsoft.com/genuine/selfhelp/XPPkuinst.aspx?sGuid=bab9e103-6365-44dd-9337-93f0cd9dd4b7&displaylang=en |
101 |
Windows Product Key Update Tool Instructions |
|
102 |
||
103 |
Activate Windows XP. |
|
104 |
-------------------- |
|
105 |
||
106 |
Replace %WINDIR%/system32/winlogon.exe with valid in Safe Mode and run Windows Product Key Update |
|
107 |
Tool. |
|
108 |
||
109 |
Windows images. |
|
110 |
=============== |
|
111 |
||
112 |
http://www.microsoft.com/downloads/en/details.aspx?FamilyID=2fcde6ce-b5fb-4488-8c50-fe22559d164e |
|
113 |
Windows XP Service Pack 3 - ISO-9660 CD Image File |
|
114 |
||
992
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
115 |
Access to Samba from Vista/7. |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
116 |
============================= |
940 | 117 |
|
118 |
By default, you cannot authenticate and share files to and from Mac OS X or |
|
119 |
Linux Samba due to a well known authentication method turned off by default. |
|
120 |
To enable this, |
|
121 |
||
122 |
Only for Windows Vista Ultimate/Business/Enterprise Editions. |
|
123 |
------------------------------------------------------------- |
|
124 |
||
125 |
Goto Start->Run and open gpedit.msc or secpol.msc |
|
126 |
||
127 |
Select Continue on the User Account Control prompt. This will launch the Group |
|
128 |
Policy Object Editor for the Local Computer Policy. |
|
129 |
||
130 |
In the Group Policy Object Editor, expand: |
|
131 |
||
132 |
-> Computer Configuration |
|
133 |
-> Windows Settings |
|
134 |
-> Security Settings |
|
135 |
-> Local Policies |
|
136 |
-> Security Options |
|
137 |
||
138 |
Open the "Network security: LAN Manager authentication level" policy and |
|
139 |
change the Security Setting to: |
|
140 |
||
141 |
Send LM & NTLM - use NTLMv2 session security if negotiated |
|
142 |
||
143 |
Windows Vista Home Edition. |
|
144 |
--------------------------- |
|
145 |
||
146 |
Since Windows Vista Home Edition does not feature the Group Policy Editor, you |
|
147 |
may do the following to enable this feature: |
|
148 |
||
149 |
Goto Start->Run-> and type regedit. |
|
150 |
||
151 |
Select Continue on the User Account Control prompt. |
|
152 |
||
153 |
Navigate to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa |
|
154 |
||
155 |
Create the following DWORD value (if it doesn't exist): LmCompatibilityLevel |
|
156 |
||
157 |
And set its value to: 1 |
|
158 |
||
159 |
Map dir to disk. |
|
160 |
================ |
|
161 |
||
162 |
To create:: |
|
163 |
||
164 |
cmd> subst [to-disk: [from-disk:]path] |
|
165 |
||
166 |
To remove:: |
|
167 |
||
168 |
cmd> subst disk: /d |
|
169 |
||
170 |
Standard scripts. |
|
171 |
================= |
|
172 |
||
173 |
compmgmt.msc - Computer management |
|
174 |
devmgmt.msc - Device manager |
|
175 |
diskmgmt.msc - Disk management |
|
176 |
dfrg.msc - Disk defrag |
|
177 |
eventvwr.msc - Event viewer |
|
178 |
fsmgmt.msc - Shared folders |
|
179 |
gpedit.msc - Group policies |
|
180 |
lusrmgr.msc - Local users and groups |
|
181 |
perfmon.msc - Performance monitor |
|
182 |
rsop.msc - Resultant set of policies |
|
183 |
secpol.msc - Local security settings |
|
184 |
services.msc - Various Services |
|
185 |
msconfig - System Configuration Utility |
|
186 |
regedit - Registry Editor |
|
187 |
msinfo32 - System Information |
|
188 |
sysedit - System Configuration Editor |
|
189 |
win.ini - windows loading information(also system.ini) |
|
190 |
winver - Shows current version of windows |
|
191 |
mailto: - Opens default email client |
|
192 |
command - Opens command prompt |
|
193 |
||
194 |
appwiz.cpl - Add & Remove Programs |
|
195 |
timedate.cpl - Date/Time Properties |
|
196 |
desk.cpl - Display Properties |
|
197 |
inetcpl.cpl - Internet Options |
|
198 |
mmsys.cpl - Sound Settings |
|
199 |
sysdm.cpl - System Properties |
|
200 |
password.cpl - Password Options |
|
201 |
main.cpl - Mouse and Keyboard Options |
|
202 |
control fonts - Fonts Folder |
|
203 |
control printers Printers Folder |
|
204 |
||
997 | 205 |
'.cpl' scripts can be run from command line as: |
996
bc510bb02ba6
.msc and .cpl run from command line.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
995
diff
changeset
|
206 |
|
bc510bb02ba6
.msc and .cpl run from command line.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
995
diff
changeset
|
207 |
cmd> Rundll32 Shell32.dll,Control_RunDLL |
bc510bb02ba6
.msc and .cpl run from command line.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
995
diff
changeset
|
208 |
cmd> Rundll32 Shell32.dll,Control_RunDLL Mmsys.cpl,,0 |
bc510bb02ba6
.msc and .cpl run from command line.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
995
diff
changeset
|
209 |
|
940 | 210 |
Path. |
211 |
===== |
|
212 |
||
213 |
Max path length. |
|
214 |
---------------- |
|
215 |
||
216 |
260 chars. Use MAX_PATH macros from 'windows.h'. |
|
217 |
||
218 |
Allowed characters. |
|
219 |
------------------- |
|
220 |
||
221 |
Not allowed: |
|
222 |
* characters from 0 to 31 |
|
223 |
* < (less than) |
|
224 |
* > (greater than) |
|
225 |
* : (colon) |
|
226 |
* " (double quote) |
|
227 |
* / (forward slash) |
|
228 |
* \ (backslash) |
|
229 |
* | (vertical bar or pipe) |
|
230 |
* ? (question mark) |
|
231 |
* * (asterisk) |
|
232 |
||
233 |
http://msdn.microsoft.com/en-us/library/aa365247.aspx |
|
234 |
Naming Files, Paths, and Namespaces |
|
235 |
||
236 |
Memory. |
|
237 |
======= |
|
238 |
||
239 |
http://msdn.microsoft.com/en-us/library/ff542275%28v=VS.85%29.aspx |
|
240 |
Boot Parameters to Configure DEP and PAE |
|
241 |
||
242 |
PAE. |
|
243 |
---- |
|
244 |
||
245 |
All 32-bit Windows XP support only 4 GiB RAM. To enable PAE (Physical Address |
|
246 |
Extension) edit 'c:\boot.ini', add option '/pae': |
|
247 |
||
248 |
multi(0)disk(0)rdisk(0)partition(1)\WINDOWS="MS Windows XP Prof" /fastdetect /pae |
|
249 |
||
250 |
http://msdn.microsoft.com/en-us/library/ff557168%28v=VS.85%29.aspx |
|
251 |
/pae option |
|
252 |
http://www.microsoft.com/whdc/system/platform/server/pae/paedrv.mspx |
|
253 |
PAE support |
|
254 |
||
255 |
NX. |
|
256 |
--- |
|
257 |
||
258 |
NX (no execute) in Windows realised in Data Execution Prevention (DEP) |
|
259 |
technology. |
|
260 |
||
261 |
On 64-bit processes, DEP is enabled by default and cannot be disabled. For |
|
262 |
32-bit Windows DEP is supported in Windows Server 2003 with SP1, Windows XP |
|
263 |
with SP2, Windows Vista, and later versions of Windows. |
|
264 |
||
265 |
To enable NX on 32-bit Windows edit 'c:\boot.ini', add option |
|
266 |
'/noexecute=...' (alwayson/optout/optin/alwaysoff):: |
|
267 |
||
268 |
multi(0)disk(0)rdisk(0)partition(1)\WINDOWS="MS Windows XP Prof" /fastdetect /noexecute=alwayson |
|
269 |
||
270 |
To see current DEP status run:: |
|
271 |
||
272 |
cmd> wmic OS Get DataExecutionPrevention_Available |
|
273 |
cmd> wmic OS Get DataExecutionPrevention_SupportPolicy |
|
274 |
cmd> wmic OS Get DataExecutionPrevention_Drivers |
|
275 |
||
276 |
http://msdn.microsoft.com/en-us/library/ff557134%28VS.85%29.aspx |
|
277 |
/noexecute parameter |
|
278 |
http://support.microsoft.com/kb/912923 |
|
279 |
How to determine that hardware DEP is available and configured on your computer |
|
280 |
||
1116
140ed8e4da7f
Windows XP Service Pack 3 - ISO-9660 CD Image File
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1082
diff
changeset
|
281 |
Windows ISO images. |
140ed8e4da7f
Windows XP Service Pack 3 - ISO-9660 CD Image File
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1082
diff
changeset
|
282 |
=================== |
140ed8e4da7f
Windows XP Service Pack 3 - ISO-9660 CD Image File
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1082
diff
changeset
|
283 |
|
140ed8e4da7f
Windows XP Service Pack 3 - ISO-9660 CD Image File
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1082
diff
changeset
|
284 |
http://www.microsoft.com/download/en/details.aspx?displaylang=en&id=25129 |
140ed8e4da7f
Windows XP Service Pack 3 - ISO-9660 CD Image File
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1082
diff
changeset
|
285 |
Windows XP Service Pack 3 - ISO-9660 CD Image File |
140ed8e4da7f
Windows XP Service Pack 3 - ISO-9660 CD Image File
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1082
diff
changeset
|
286 |
|
940 | 287 |
Life cycle. |
288 |
=========== |
|
289 |
||
290 |
http://www.microsoft.com/windows/support/endofsupport.mspx |
|
291 |
End of support for Windows 98, Windows Me, and Windows XP Service Pack 1 |
|
292 |
http://www.microsoft.com/windows/lifecycle/servicepacks.mspx |
|
293 |
Windows Service Pack Road Map |
|
294 |
http://www.microsoft.com/windows/lifecycle/default.mspx |
|
295 |
Windows Life-Cycle Policy |
|
296 |
http://support.microsoft.com/gp/lifeselect |
|
297 |
Life-Cycle Policy by product |
|
298 |
||
299 |
NTFS junction points. |
|
300 |
===================== |
|
301 |
||
302 |
To craete use 'junction.exe' from Mark Russinovich or 'linkd.exe' from |
|
303 |
Microsoft Windows 2000 Resource Kit. |
|
304 |
||
305 |
'junction.exe' included with Sysinternals suite. |
|
306 |
||
307 |
cmd> md c:\Program-Files |
|
308 |
cmd> junction c:\Program-Files "c:\Program Files" |
|
309 |
||
310 |
http://technet.microsoft.com/en-gb/sysinternals/bb896768.aspx |
|
311 |
Junction v1.05, Published: July 24, 2007 |
|
312 |
http://support.microsoft.com/?kbid=205524 |
|
313 |
How to create and manipulate NTFS junction points |
|
314 |
http://en.wikipedia.org/wiki/NTFS_junction_point |
|
951 | 315 |
NTFS junction point |
940 | 316 |
|
317 |
Microsoft Windows 2000 Resource Kit. |
|
318 |
==================================== |
|
319 |
||
320 |
http://support.microsoft.com/kb/927229 |
|
321 |
Windows 2000 Resource Kit Tools for administrative tasks |
|
322 |
separate tools downloads |
|
323 |
||
324 |
Microsoft security tools. |
|
325 |
========================= |
|
326 |
||
327 |
http://www.microsoft.com/downloads/details.aspx?FamilyID=CD057D9D-86B9-4E35-9733-7ACB0B2A3CA1&displayLang=en |
|
328 |
||
329 |
http://www.microsoft.com/downloads/details.aspx?FamilyID=B1E76BBE-71DF-41E8-8B52-C871D012BA78&displayLang=en |
|
330 |
Microsoft Baseline Security Analyzer 2.1.1 (for IT |
|
331 |
Professionals) |
|
332 |
||
333 |
http://www.microsoft.com/downloads/en/confirmation.aspx?familyId=4a2346ac-b772-4d40-a750-9046542f343d&displayLang=en |
|
334 |
Enhanced Mitigation Evaluation Toolkit |
|
335 |
||
336 |
http://blogs.technet.com/b/srd/archive/2009/10/27/announcing-the-release-of-the-enhanced-mitigation-evaluation-toolkit.aspx |
|
337 |
Announcing the release of the Enhanced Mitigation Evaluation |
|
338 |
Toolkit (old version 1.0) |
|
339 |
||
340 |
http://blogs.technet.com/b/srd/archive/2010/07/28/announcing-the-upcoming-release-of-emet-v2.aspx |
|
341 |
||
342 |
Enable/Disabling UAC. |
|
343 |
===================== |
|
344 |
||
345 |
To disable UAC on the computer, you must be able to log on with or provide the |
|
346 |
credentials of a member of the local Administrators group. |
|
347 |
||
348 |
Starting with Windows 7, UAC is disabled by following these steps: |
|
349 |
||
350 |
1. On the Start menu, type "UAC" and then click Change User Account settings. |
|
351 |
2. Move the slide bar to the bottom (Never Notify) and then click OK. |
|
352 |
||
353 |
On Windows Vista and Windows Server 2008, UAC is disabled by following these steps: |
|
354 |
||
355 |
1. Start Control Panel and double-click User Accounts. |
|
356 |
2. In the User Accounts tasks window, click Turn User Account Control on or off. |
|
357 |
3. Clear the Use User Account Control (UAC) to help protect your computer check box, and then click OK. |
|
358 |
||
359 |
http://windows.microsoft.com/en-US/windows-vista/Turn-User-Account-Control-on-or-off |
|
360 |
Turn User Account Control on or off |
|
361 |
||
362 |
Fix file association. |
|
363 |
===================== |
|
364 |
||
365 |
Check current association:: |
|
366 |
||
367 |
$ cmd /c assoc | grep -i "^\.mp3" |
|
368 |
.mp3=mp3file |
|
369 |
||
370 |
Get list of all available commands:: |
|
371 |
||
372 |
$ cmd /c ftype |
|
373 |
... |
|
374 |
AIMP.mp3="C:\Program Files\AIMP2\AIMP2.exe" "%1" |
|
375 |
... |
|
376 |
||
377 |
and select one on them:: |
|
378 |
||
379 |
$ cmd /c assoc .mp3=AIMP.mp3 |
|
380 |
||
381 |
Clean up Windows system directories. |
|
382 |
==================================== |
|
383 |
||
384 |
You can safely remove SP restore files:: |
|
385 |
||
386 |
%Systemroot%\$NtServicePackUninstall$ |
|
387 |
||
388 |
Also check such directories:: |
|
389 |
||
390 |
%SYSTEMDRIVE%\Program Files\Common Files |
|
391 |
%SYSTEMDRIVE%\Documents and Settings\USER\Application Data |
|
392 |
%SYSTEMDRIVE%\Documents and Settings\USER\Local Settings |
|
393 |
||
394 |
http://support.microsoft.com/kb/290402 |
|
395 |
HOW TO: Remove the Service Pack Restore Files and Folders in Windows |
|
396 |
||
397 |
Windows services from command line. |
|
398 |
=================================== |
|
399 |
||
400 |
List of all running services. |
|
401 |
----------------------------- |
|
402 |
:: |
|
403 |
||
404 |
cmd> net start |
|
405 |
||
406 |
Start service. |
|
407 |
-------------- |
|
408 |
:: |
|
409 |
||
410 |
cmd> net start NAME |
|
411 |
||
412 |
Stop service. |
|
413 |
------------- |
|
414 |
:: |
|
415 |
||
416 |
cmd> net stop NAME |
|
417 |
||
418 |
Schedule Tasks in Windows. |
|
419 |
========================== |
|
420 |
||
421 |
List registered of task. |
|
422 |
------------------------ |
|
423 |
:: |
|
424 |
||
425 |
$ schtasks /query |
|
426 |
||
427 |
Create task. |
|
428 |
------------ |
|
429 |
:: |
|
430 |
||
431 |
$ schtasks /create /tn %TASK_NAME% /ru %ROOT% /sc daily /st 23:00:00 /tr "rundll32.exe user32.dll,LockWorkStation" |
|
432 |
||
433 |
/sc can be one of:: |
|
434 |
||
435 |
MINUTE HOURLY DAILY WEEKLY MONTHLY ONCE ONSTART ONLOGON ONIDLE |
|
436 |
||
437 |
Delete task. |
|
438 |
------------ |
|
439 |
:: |
|
440 |
||
441 |
schtasks /delete /tn %TASK_NAME% /f |
|
442 |
||
992
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
443 |
Change NTFS permission. |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
444 |
======================= |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
445 |
|
1071
d06823550de7
takeown /r /f %file%
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1043
diff
changeset
|
446 |
http://support.microsoft.com/kb/919240 |
d06823550de7
takeown /r /f %file%
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1043
diff
changeset
|
447 |
The Icacls.exe utility is available for Windows Server 2003 with |
d06823550de7
takeown /r /f %file%
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1043
diff
changeset
|
448 |
Service Pack 2 |
d06823550de7
takeown /r /f %file%
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1043
diff
changeset
|
449 |
|
992
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
450 |
Change NTFS permission with 'icacls'. |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
451 |
------------------------------------- |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
452 |
|
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
453 |
'icacls' allow option: |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
454 |
|
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
455 |
* /c - Continues the operation despite any file errors. Error messages will |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
456 |
still be displayed. |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
457 |
* /t - Performs the operation on all specified files in the current directory |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
458 |
and its subdirectories. |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
459 |
* /l - Performs the operation on a symbolic link versus its destination. |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
460 |
* /q - Suppresses success messages. |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
461 |
|
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
462 |
Recursively change the owner of all matching files to the specified user:: |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
463 |
|
1043 | 464 |
cmd> icacls %dir% /setowner %user% /t /c |
992
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
465 |
|
1071
d06823550de7
takeown /r /f %file%
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1043
diff
changeset
|
466 |
or simply:: |
d06823550de7
takeown /r /f %file%
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1043
diff
changeset
|
467 |
|
d06823550de7
takeown /r /f %file%
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1043
diff
changeset
|
468 |
cmd> takeown /r /f %file% |
d06823550de7
takeown /r /f %file%
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1043
diff
changeset
|
469 |
|
993
e3fefdeb1cbf
Converting SID to names and inside out.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
992
diff
changeset
|
470 |
Recursively grand full access for everyone:: |
992
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
471 |
|
995 | 472 |
cmd> icacls %dir% /t /grant:r %user%:(f) |
994 | 473 |
cmd> icacls %dir% /t /grant:r *S-1-1-0:(f) |
992
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
474 |
|
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
475 |
Well-known security identifiers (SID). |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
476 |
====================================== |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
477 |
|
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
478 |
S-1-0-0 |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
479 |
Null SID. A group with no members. This is often used when a SID |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
480 |
value is not known. |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
481 |
S-1-1-0 |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
482 |
World/Everyone. A group that includes all users. |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
483 |
S-1-3-0 |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
484 |
Creator Owner ID. A security identifier to be replaced by the |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
485 |
security identifier of the user who created a new object. This |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
486 |
SID is used in inheritable ACEs. |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
487 |
S-1-3-1 |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
488 |
Creator Group ID. A security identifier to be replaced by the |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
489 |
primary-group SID of the user who created a new object. Use this |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
490 |
SID in inheritable ACEs. |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
491 |
S-1-5-6 |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
492 |
Service. A group that includes all security principals that have |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
493 |
logged on as a service. Membership is controlled by the |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
494 |
operating system. |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
495 |
S-1-5-7 |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
496 |
Anonymous. A group that includes all users that have logged on |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
497 |
anonymously. Membership is controlled by the operating system. |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
498 |
S-1-5-32-544 |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
499 |
Administrators group. |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
500 |
S-1-5-32-545 |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
501 |
Users group. |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
502 |
S-1-5-32-546 |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
503 |
Guests. By default, the only member is the Guest account. The |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
504 |
Guests group allows occasional or one-time users to log on with |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
505 |
limited privileges to a computer's built-in Guest account. |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
506 |
S-1-5-32-547 |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
507 |
Power Users. Power users can create local users and groups; |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
508 |
modify and delete accounts that they have created; and remove |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
509 |
users from the Power Users, Users, and Guests groups. Power |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
510 |
users also can install programs; create, manage, and delete |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
511 |
local printers; and create and delete file shares. |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
512 |
|
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
513 |
http://msdn.microsoft.com/en-us/library/aa379649.aspx |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
514 |
Well-known SIDs |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
515 |
http://support.microsoft.com/kb/243330 |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
516 |
Хорошо известные идентификаторы безопасности в операционных |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
517 |
системах Windows |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
518 |
http://en.wikipedia.org/wiki/Security_Identifier |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
519 |
Security Identifier |
3f8b5c0ba822
Change NTFS permission.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
951
diff
changeset
|
520 |
|
993
e3fefdeb1cbf
Converting SID to names and inside out.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
992
diff
changeset
|
521 |
Converting SID to names and inside out. |
e3fefdeb1cbf
Converting SID to names and inside out.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
992
diff
changeset
|
522 |
======================================= |
e3fefdeb1cbf
Converting SID to names and inside out.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
992
diff
changeset
|
523 |
|
e3fefdeb1cbf
Converting SID to names and inside out.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
992
diff
changeset
|
524 |
Use 'PsGetSid' utility from Sysinternals:: |
e3fefdeb1cbf
Converting SID to names and inside out.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
992
diff
changeset
|
525 |
|
e3fefdeb1cbf
Converting SID to names and inside out.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
992
diff
changeset
|
526 |
cmd> PsGetSid S-1-3-0 |
e3fefdeb1cbf
Converting SID to names and inside out.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
992
diff
changeset
|
527 |
cmd> PsGetSid "\NULL SID" |
e3fefdeb1cbf
Converting SID to names and inside out.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
992
diff
changeset
|
528 |
|
999
dc74e11a1686
Gathering info about Windows.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
997
diff
changeset
|
529 |
Gathering info about Windows. |
dc74e11a1686
Gathering info about Windows.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
997
diff
changeset
|
530 |
============================= |
dc74e11a1686
Gathering info about Windows.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
997
diff
changeset
|
531 |
:: |
dc74e11a1686
Gathering info about Windows.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
997
diff
changeset
|
532 |
|
dc74e11a1686
Gathering info about Windows.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
997
diff
changeset
|
533 |
cmd> systeminfo |
dc74e11a1686
Gathering info about Windows.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
997
diff
changeset
|
534 |
|
1203
bd2a6d024b5f
hcp://system/sysinfo/msinfo.xml
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1183
diff
changeset
|
535 |
From ``Win+R``:: |
bd2a6d024b5f
hcp://system/sysinfo/msinfo.xml
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1183
diff
changeset
|
536 |
|
bd2a6d024b5f
hcp://system/sysinfo/msinfo.xml
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1183
diff
changeset
|
537 |
helpctr.exe -mode hcp://system/sysinfo/msinfo.xml |
bd2a6d024b5f
hcp://system/sysinfo/msinfo.xml
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1183
diff
changeset
|
538 |
|
bd2a6d024b5f
hcp://system/sysinfo/msinfo.xml
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1183
diff
changeset
|
539 |
or by:: |
bd2a6d024b5f
hcp://system/sysinfo/msinfo.xml
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1183
diff
changeset
|
540 |
|
bd2a6d024b5f
hcp://system/sysinfo/msinfo.xml
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1183
diff
changeset
|
541 |
cmd> %SystemRoot%\pchealth\helpctr\binaries\helpctr.exe -mode hcp://system/sysinfo/msinfo.xml |
bd2a6d024b5f
hcp://system/sysinfo/msinfo.xml
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1183
diff
changeset
|
542 |
|
1082
ffb3f274b8fe
Automatically logon to Windows.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1071
diff
changeset
|
543 |
Automatically logon to Windows. |
ffb3f274b8fe
Automatically logon to Windows.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1071
diff
changeset
|
544 |
=============================== |
ffb3f274b8fe
Automatically logon to Windows.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1071
diff
changeset
|
545 |
:: |
ffb3f274b8fe
Automatically logon to Windows.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1071
diff
changeset
|
546 |
|
ffb3f274b8fe
Automatically logon to Windows.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1071
diff
changeset
|
547 |
cmd# control userpasswords2 |
ffb3f274b8fe
Automatically logon to Windows.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1071
diff
changeset
|
548 |
|
1147 | 549 |
Format drive. |
550 |
============= |
|
1082
ffb3f274b8fe
Automatically logon to Windows.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
1071
diff
changeset
|
551 |
|
1147 | 552 |
Replace with own disk letter:: |
553 |
||
554 |
cmd# format E: /q /fs:ntfs |
|
555 |
||
1148 | 556 |
See: |
557 |
||
558 |
http://www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-us/format.mspx |
|
559 |
Formats the disk in the specified volume to accept Windows |
|
560 |
files. |
|
561 |