Как изменить shell windows

I need to create a special account on a computer running Windows 10 Enterprise. This account would launch an application directly on login instead of the default shell and exiting the application s...

I need to create a special account on a computer running Windows 10 Enterprise. This account would launch an application directly on login instead of the default shell and exiting the application should force the computer to restart.

I was able to do this easily on Windows 8.1 Embedded Industry Pro using the configuration console and lockdown features.

Now, on Windows 10 I try to follow the two tutorials on technet WESL_UserSetting and Set up a kiosk on Windows 10 Pro, Enterprise, or Education

However, neither of the tutorials work. I have managed to execute the scripts described in them but they have no effect (I’ve modified them so they do not remove the shells set).

Finally I’ve ended up with the following code:

$COMPUTER = "localhost"
$NAMESPACE = "rootstandardcimv2embedded"
$ACCOUNT_NAME = "cmp"

$ShellLauncherClass = [wmiclass]"\$COMPUTER${NAMESPACE}:WESL_UserSetting"


$NTUserObject = New-Object System.Security.Principal.NTAccount($ACCOUNT_NAME)
$NTUserSID = $NTUserObject.Translate([System.Security.Principal.SecurityIdentifier]).Value

$NTUser_Shell = Get-WmiObject -namespace $NAMESPACE -computer $COMPUTER -class WESL_UserSetting | 
    where {$_.Sid -eq $NTUserSID}

if ($NTUser_Shell) {
    "`Custom shell already set for [$ACCOUNT_NAME] removing it"
    $ShellLauncherClass.RemoveCustomShell($NTUserSID)
}

$restart_shell = 0
$restart_device = 1
$shutdown_device = 2

$ShellLauncherClass.SetCustomShell($NTUserSID, "cmd.exe", ($null), ($null), $restart_device)

"`nCurrent settings for custom shells:"
Get-WmiObject -namespace $NAMESPACE -computer $COMPUTER -class WESL_UserSetting | Select Sid, Shell, DefaultAction

Executing this script in an admin powershell produces the desired output:

Custom shell already set for [cmp] removing it

Current settings for custom shells:

Sid                                            Shell   DefaultAction
---                                            -----   -------------
S-1-5-21-3842421150-1098587697-2315725148-1002 cmd.exe             1

However logging as the ‘cmp’ user simply shows the standard Windows 10 shell.

What should I change in order to be able to run a program instead of a standard shell?

In my Windows 10 Embedded Enterprise box, I have the main user with admin privileges (password protected) and the «Operator» user with regular user privileges and no password.

This step is optional, needed only if you want to auto login:

Start-Run (or Win-R) and launch netplwiz, uncheck the Users must enter a username and password... box and hit Apply: a new window pops up asking for a default username and password. In my case, I use Operator and blank password. Press OK and in the other window also press OK to accept the changes and close the window.

The following works even if a user has to login with password, so the above is really optional, only if an old-school Kiosk mode is needed (for a non UWP application).

Microsoft Docs has an answer to your question, in short:

  1. Under the admin user, open registry editor: regedit
  2. Go to HKEY_LOCAL_MACHINESoftwareMicrosoftWindows NTCurrentVersionIniFileMappingsystem.iniboot and change the value of Shell string from the default SYS:MicrosoftWindows NTCurrentVersionWinlogon to USR:SoftwareMicrosoftWindows NTCurrentVersionWinlogon
  3. (Optional) Go to HKEY_LOCAL_MACHINESoftwareMicrosoftWindows NTCurrentVersionWinlogon and change Shell string from default explorer.exe to something else. This is generally a backup in case the user-based shell is not found. This setting applies to all users, so I prefer to leave it on explorer.exe.
  4. Optionally login as the default user if you created one as per the above. Go to HKEY_Current_UserSoftwareMicrosoftWindows NTCurrentVersionWinlogon Create/change the value of Shell string to point to an executable or batch file that you’d like to run as a custom shell for a given user.

In this setup, when the computer starts, the Operator user logs in automagically and my custom application is launched. When needed, I connect a network cable to the computer and connect to is using VNC (optionally, I could just plug in a keyboard), hit Ctrl-Alt-Del and either lock or sign out the Operator user. Then I login as the admin user and the «normal» Windows Explorer is launched. I do whatever changes are necessary and either reboot the machine or logout and login as Operator again.

Keep in mind that messing with the wrong registry setting can cause the system to fail to boot. While I made an attempt at accurately representing the steps, refer to the actual documentation, read it completely at least once before attempting any changes so you have an overall picture of what needs to be done… Hope this helps.

Программа Open-Shell Menu для Windows 10С выходом первых версий Windows с «плиточным» меню в Интернете сразу появились программы, позволяющие вернуть стандартный Пуск, о которых я уже писал: Меню Пуск в Windows 10 как в Windows 7.

Одна из самых популярных таких программ — Classic Shell, которая продолжает работать в последних версиях Windows 10, но её разработка и обновление больше не ведутся. Однако, автор этой утилиты открыл исходный код и на его базе появились новая программа, продолжающая обновляться — Open Shell (ранее называлась Classic Start и NeoClassic-UI), именно о ней и пойдет речь в этом обзоре.

Использование Open-Shell для возврата стандартного меню Пуск в Windows 10

Если вы знакомы с утилитой Classic Shell, то и проблем с использованием Open Shell у вас, вероятнее всего, не возникнет, более того, программа может автоматически импортировать настройки из первой утилиты.

Процесс установки и запуска программы очень простой:

  1. Установка выполняется на английском языке. Все, что потребуется сделать на этом этапе — выбрать требуемые компоненты: Classic Explorer (меняет меню в проводнике), Open-Shell Menu (классическое меню Пуск), Classic IE (настройка меню и строки состояния Internet Explorer), Open-Shell Update (автоматическая проверка доступных обновлений). Установка Open Shell
  2. Сразу после установки запустится окно настройки Open-Shell Menu. Настройки запускаются на английском языке, однако, само меню работает на русском. Если же и меню отображается не на том языке — отметьте пункт «Show All Settings», а затем выберите нужный язык на вкладке «Language». Главное окно Open Shell
  3. На главной странице настроек Open-Shell Menu вы можете выбрать внешний вид меню пуск, при необходимости — заменить кнопку «Пуск» своей кнопкой (по умолчанию отображается стандартная кнопка Windows 10).
  4. Нажав «Select Skin» под выбранным внешним видом меню Пуск вы можете выбрать тему оформления, а также настроить размеры иконок, текста, прозрачности с помощью соответствующих отметок (набор доступных отметок может отличаться в зависимости от выбранной темы). Выбор оформления меню Open Shell
  5. На вкладке Basic Settings можно настроить поведение различных кликов и нажатия клавиши Windows в меню Open Shell, включить или отключить автоматический запуск классического меню после перезапуска компьютера, отображение раздела «Все программы» и часто используемых программ.
  6. Вкладка Customize Start Menu позволяет включить или отключить отображение пунктов в меню пуск. Настройка меню Пуск
  7. По умолчанию быстро зайти в настройки Open Shell Menu вы можете, нажав правой кнопкой мыши по кнопке «Пуск» и выбрав пункт «Настройка».
  8. Если вы хотите вернуть обычное меню по правому клику (то, которое стандартно появляется в Windows 10), в настройках программы отметьте Show All Settings, а затем на вкладке «Controls» отметьте пункт «Right click opens Win+X menu».

В целом, всё сравнительно удобно и работает исправно, если не считать отсутствия русского интерфейса настроек, что может оказаться проблемой для некоторых пользователей. Если же проблем с этим нет, рекомендую отметить пункт Show all settings в утилите настроек Open-Shell Menu и пройтись по всем вкладкам: не исключено, что вы сможете найти что-то полезное для себя.

Расширенные настройки Open Shell

Ниже — пара примеров классического меню Пуск в Windows 10 с помощью Open-Shell Menu.

Классическое меню Пуск Open Shell в Windows 10

Скачать последнюю версию Open Shell вы можете с официальной страницы разработчика https://github.com/Open-Shell/Open-Shell-Menu/releases

Понравилась статья? Поделить с друзьями:
  • Как изменить print python
  • Как изменить primary key sql
  • Как изменить primary key oracle
  • Как изменить setinterval js
  • Как изменить primary ide master