Saturday, 29 March 2014

Coomand to open recycle bin:


Here is the command which helps to open the recycle bin.

1. Through command prompt: start shell:RecycleBinFolder
2. Through run: shell:RecycleBinFolder

Enable Auto Lock via group policy and registry

Via Registry Editor:
1. Open Regedit.
2. To enable autolock Modify the data of the values on the location "[HKEY_CURRENT_USER\Control Panel\Desktop]" as,
     "ScreenSaveActive"="1"
     "ScreenSaveTimeOut"="60"
     "ScreenSaverIsSecure"="1"

Via Group policy:
1. Open gpedit.msc through run.
2. Do the following changes on the location "user configuration>Administrative templates>personalization>
     enable Screensaver
     Password protect the Screensaver
     Screensaver timeout "


Enable or Disable USB port via registry

It is quite easy to enable or disable USB port through registry.

1. Open regedit.
2. Locate the value "Start" on the location "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\USBSTOR"
3. Modify the data from default "3" to "4" to disable the usb port.

Friday, 28 March 2014

To launch command prompt in Interactive Session.

The command that can be used to launch command prompt in session 0 are,

1. sc create SvcIntCMD binpath= "cmd /K start" type= own type= interact DisplayName= "InteractiveCMD"

2 . sc start  SvcIntCMD
sc create SvcIntCMD binpath= "cmd /K start" type= own type= interact DisplayName= "InteractiveCMD"

sc start  SvcIntCMD - See more at: http://www.itninja.com/link/interactive-system-command-prompt-in-win7#sthash.07pbTf7f.dpuf

sc create SvcIntCMD binpath= "cmd /K start" type= own type= interact DisplayName= "InteractiveCMD"

sc start  SvcIntCMD - See more at: http://www.itninja.com/link/interactive-system-command-prompt-in-win7#sthash.07pbTf7f.dpufsc create SvcIntCMD binpath= "cmd /K start" type= own type= interact DisplayName= "InteractiveCMD" 

sc start  SvcIntCMD - See more at: http://www.itninja.com/link/interactive-system-command-prompt-in-win7#sthash.07pbTf7f.dpuf

sc create SvcIntCMD binpath= "cmd /K start" type= own type= interact DisplayName= "InteractiveCMD"

sc start  SvcIntCMD - See more at: http://www.itninja.com/link/interactive-system-command-prompt-in-win7#sthash.07pbTf7f.dpuf

Command to access session 0

To access session 0, Interactive Services Detection should be started, inorder to check whether the interactive services detection is running execute the command "sc query UI0Detect", if it is not running start the service using the command "sc start UI0Detect". Once it is done do the following to access the session 0.

1. Open command prompt in admin mode.
2. Execute the following command :
rundll32 winsta.dll,WinStationSwitchToServicesSession

and the session 0 has been opened.

Commands to open an exe in session 0.

Here is the command which helps to open an exe in session 0.

1. sc create RabbitHole binpath= %SYSTEMROOT%\system32\notepad.exe type= interact type= own

2. sc start RabbitHole

3. sc delete RabbitHole

Execute the first command through command prompt (administrator mode), by specifying the location of the file and execute the second command to start the service. Once the service is started the specified file will be executed in the session 0.

Note: Delete the service before trying to open a new exe, or else it will open the file that has been executed previously again.