📜 ⬆️ ⬇️

Windows XP in the domain as Terminal Server (Linux way)

Administrators of workstations under Windows know what a confusion it is in Mon. in the morning suddenly chase out
all users from the sessions and urgently update the domestic software. Output - simultaneous work in Windows XP user and administrator.
Recipes on the Internet are a bit inaccurate, designed for a mouse, do not work in a domain, do not know what else - choose X from Y.
We will make the necessary tool with well-known materials that works simply, quickly and without a mouse (Linux way, yes).
Note: legal issues are not considered.


1. Purpose of the work


  1. Replace the necessary dll
  2. Correct / add registry keys
  3. Ensure restoration of the status quo after overload

2. Instruments and materials


  1. Windows XP in the domain
  2. Corrected for 3 bytes termsrv.dll required version (on the Internet )
  3. srvany.exe (in some ResourceKit or separately )
  4. instsrv.exe (ibid.)
  5. Create two batch file (hands)

We put everything in one [network] folder and happily straighten the handles.

3. Progress


')
Do it once

1.cmd:
@ECHO "1. SFC off" @REG ADD "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon" /v SFCDisable /t REG_DWORD /d 00000001 /f @ECHO "2. Terminal service off" @REG ADD "HKLM\SYSTEM\CurrentControlSet\Services\TermService" /v Start /t REG_DWORD /d 00000004 /f @PAUSE 

> 1.cmd && shutdown -t 0 -r

Make two

2.cmd:
 @REM store src path (w/ trailing slash) @SET ROOT=%~dp0 @ECHO "1. Copy files" @ECHO "termsrv.dll..." @copy /y %ROOT%termsrv.dll %WINDIR%\ServicePackFiles\i386\ @copy /y %ROOT%termsrv.dll %WINDIR%\System32\dllcache\ @copy /y %ROOT%termsrv.dll %WINDIR%\System32\ @ECHO "srvany.exe..." @copy /y %ROOT%srvany.exe %WINDIR%\ @ECHO "2. Create service to reenable multisession" %ROOT%instsrv.exe TS "%WINDIR%\srvany.exe" @ECHO "3. Modify registry" @ECHO "Enable TS..." @REG ADD "HKLM\SYSTEM\ControlSet001\Control\Terminal Server\Licensing Core" /v EnableConcurrentSessions /t REG_DWORD /d 00000001 /f @REG ADD "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon" /v EnableConcurrentSessions /t REG_DWORD /d 00000001 /f @REG ADD "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon" /v AllowMultipleTSSessions /t REG_DWORD /d 00000001 /f @REG ADD "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v MaxInstanceCount /t REG_DWORD /d 00000007 /f @ECHO "Tune our service..." @REG ADD "HKLM\SYSTEM\CurrentControlSet\Services\TS\Parameters" /v Application /t REG_SZ /d "REG ADD \"HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon\" /v AllowMultipleTSSessions /t REG_DWORD /d 00000001 /f" /f @ECHO "4. Terminal service on (2=auto)" @REG ADD "HKLM\SYSTEM\CurrentControlSet\Services\TermService" /v Start /t REG_DWORD /d 00000002 /f @ECHO "5. SFC on" @REG ADD "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon" /v SFCDisable /t REG_DWORD /d 00000000 /f @PAUSE 

> 2.cmd && shutdown -t 0 -r

4. Conclusions


Source: https://habr.com/ru/post/151984/


All Articles