Как восстановить службу смарт-карт на Windows 7
Сообщений 2
#1 Тема от Алексей Несененко 2012-08-09 15:59:06 (2012-08-09 16:12:17 отредактировано Алексей Несененко)
Как восстановить службу смарт-карт на Windows 7
Служба смарт-карт — стандартный компонент Windows, и она должна присутствовать на каждой системе.
Однако, при определенных обстоятельствах она может отсутствовать. И в результате программы, которые зависят от этой службы, перестанут работать.
Если служба смарт-карт не находится в списке служб, но файл, связанный с этой службой (SCardSvr.dll), имеется в файловой системе,
то, скорее всего, проблема заключается не в том, что модулей нет, а в том, что они не загружены.
Служба отсутствует в списке, из-за того, что некоторые записи в реестре отличаются от тех же записей «нормальной системы».
Другими словами, различие только в содержании ключа HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\SCardSvr .
Итак, если службы нет в списке, открываем редактор реестра командой regedit, и ищем в нем этот ключ. Скорее всего, он будет отсутствовать.
Если он присутствует, то это значит, что некоторые его параметры неправильные.
Загрузите этот файл и импортируйте его в реестр.
Перезагрузите систему.
Если Вам повезло, и дело было именно в этом ключе реестра, то служба вернется в список остальных служб.
#2 Ответ от Алексей Несененко 2012-08-09 16:00:28
Re: Как восстановить службу смарт-карт на Windows 7
Если файл не скачивается, то вот его содержание (т.е. создайте текстовый файл, скопируйте туда этот текст и сохраните его в файл с расширением reg).
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\SCardSvr]«DisplayName»=»@%SystemRoot%\\System32\\SCardSvr.dll,-1»
«Group»=»SmartCardGroup»
«ImagePath»=hex(2):25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,6f,00,6f,00,\
74,00,25,00,5c,00,73,00,79,00,73,00,74,00,65,00,6d,00,33,00,32,00,5c,00,73,\
00,76,00,63,00,68,00,6f,00,73,00,74,00,2e,00,65,00,78,00,65,00,20,00,2d,00,\
6b,00,20,00,4c,00,6f,00,63,00,61,00,6c,00,53,00,65,00,72,00,76,00,69,00,63,\
00,65,00,41,00,6e,00,64,00,4e,00,6f,00,49,00,6d,00,70,00,65,00,72,00,73,00,\
6f,00,6e,00,61,00,74,00,69,00,6f,00,6e,00,00,00
«Description»=»@%SystemRoot%\\System32\\SCardSvr.dll,-5»
«ObjectName»=»NT AUTHORITY\\LocalService»
«ErrorControl»=dword:00000001
«Start»=dword:00000002
«Type»=dword:00000020
«DependOnService»=hex(7):50,00,6c,00,75,00,67,00,50,00,6c,00,61,00,79,00,00,00,\
00,00
«ServiceSidType»=dword:00000001
«RequiredPrivileges»=hex(7):53,00,65,00,43,00,72,00,65,00,61,00,74,00,65,00,47,\
00,6c,00,6f,00,62,00,61,00,6c,00,50,00,72,00,69,00,76,00,69,00,6c,00,65,00,\
67,00,65,00,00,00,53,00,65,00,43,00,68,00,61,00,6e,00,67,00,65,00,4e,00,6f,\
00,74,00,69,00,66,00,79,00,50,00,72,00,69,00,76,00,69,00,6c,00,65,00,67,00,\
65,00,00,00,00,00
«FailureActions»=hex:84,03,00,00,00,00,00,00,00,00,00,00,03,00,00,00,14,00,00,\
00,01,00,00,00,c0,d4,01,00,01,00,00,00,e0,93,04,00,00,00,00,00,00,00,00,00
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\SCardSvr\Parameters]«ServiceDll»=hex(2):25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,6f,00,6f,\
00,74,00,25,00,5c,00,53,00,79,00,73,00,74,00,65,00,6d,00,33,00,32,00,5c,00,\
53,00,43,00,61,00,72,00,64,00,53,00,76,00,72,00,2e,00,64,00,6c,00,6c,00,00,\
00
«ServiceMain»=»CalaisMain»
«ServiceDllUnloadOnStop»=dword:00000001
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\SCardSvr\Security]«Security»=hex:01,00,14,80,90,00,00,00,a0,00,00,00,14,00,00,00,34,00,00,00,02,\
00,20,00,01,00,00,00,02,c0,18,00,00,00,0c,00,01,02,00,00,00,00,00,05,20,00,\
00,00,20,02,00,00,02,00,5c,00,04,00,00,00,00,02,14,00,ff,01,0f,00,01,01,00,\
00,00,00,00,05,12,00,00,00,00,00,18,00,ff,01,02,00,01,02,00,00,00,00,00,05,\
20,00,00,00,20,02,00,00,00,00,14,00,8d,01,02,00,01,01,00,00,00,00,00,05,04,\
00,00,00,00,00,14,00,8d,01,02,00,01,01,00,00,00,00,00,05,06,00,00,00,01,02,\
00,00,00,00,00,05,20,00,00,00,20,02,00,00,01,02,00,00,00,00,00,05,20,00,00,\
00,20,02,00,00
Scardsvr reinstall windows 7
Manages access to smart cards read by your computer. If this service is stopped, your computer will be unable to read smart cards. If this service is disabled, any services that explicitly depend on it will fail to start.
This service also exists in Windows 10, 8, Vista and XP.
Startup Type
Windows 7 edition | without SP | SP1 |
---|---|---|
Starter | Manual | Manual |
Home Basic | Manual | Manual |
Home Premium | Manual | Manual |
Professional | Manual | Manual |
Ultimate | Manual | Manual |
Enterprise | Manual | Manual |
Default Properties
Display name: | Smart Card |
Service name: | SCardSvr |
Type: | share |
Path: | %WinDir%\system32\svchost.exe -k LocalServiceAndNoImpersonation |
File: | %WinDir%\System32\SCardSvr.dll |
Error control: | normal |
Group: | SmartCardGroup |
Object: | NT AUTHORITY\LocalService |
Privileges: |
|
Default Behavior
The Smart Card service runs as NT AUTHORITY\LocalService in a shared process. It shares an executable file with other services. If the Smart Card fails to load or initialize, the error is recorded into the Event Log. Windows 7 startup should proceed, but a message box is displayed informing you that the SCardSvr service has failed to start.
Dependencies
Smart Card will not start, if the Plug and Play service is stopped or disabled.
Restore Default Startup Type for Smart Card
Automated Restore
1. Select your Windows 7 edition and Service Pack, and then click on the Download button below.
2. Save the RestoreSmartCardWindows7.bat file to any folder on your hard drive.
3. Right-click the downloaded batch file and select Run as administrator.
Lazybit
The smart card service is a standard Windows component and it should be present on every system. However, in certain circumstances that is not the case — as a result, programs that depend on this service will fail.
I’ve previously discussed how to install the smart card service on Windows XP, and I’ve covered this procedure on Windows 2000. However, I had no solution for Windows Vista and Windows 7.
Fortunately, that is not the case anymore, a solution that works on 32-bit and 64-bit platforms was found, here is how it works.
Sometimes the smart card service is not in the list of services at all, but if you look for the files related to this service (ex: SCardSSP.dll) — they are present in the file system. So the problem is not in the fact that the modules are not there; they are — but they are not loaded.
Having had the opportunity to tinker with a problematic system, I was able to determine that the service is absent because some entries in the registry are different from their «normal system» counterparts.
In other words, the difference is only in the contents of HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\SCardSvr.
If the service is not listed, open regedit and view that key, it will most likely be absent. If it is present — it means that some of its sub-entries are incorrect.
- Backup the key (right-click\Export) to a REG file
- Delete the key
- Download and import this REG file: http://dl.dropbox.com/u/3258602/scard-vistax86x64.reg
- Reboot the system
If the planets are aligned properly — the service will be back, and it will be running after the restart. Give your software a try, everything should work. The registry file above works with Vista x86 and Vista x64.
For Windows 7, use this one: http://dl.dropbox.com/u/3258602/scardsvr-win7x64.reg (it should work on both types of platforms).
For Windows Server 2008, use the same file as for Windows 7; I tested it on x64 — it works.
I hope you’ll find this helpful and that you will save all the time I’ve lost. Feel free to share your experience or ask any questions.
If the sky falls down and Dropbox doesn’t work, here is the contents of the files.
Smart card service for Windows Vista
Windows Registry Editor Version 5.00
_MACHINE\SYSTEM\CurrentControlSet\Services\SCardSvr]
«DisplayName»=»@%SystemRoot%\\System32\\SCardSvr.dll,-1»
«Group»=»SmartCardGroup»
«ImagePath»=hex(2):25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,6f,00,6f,00,\
74,00,25,00,5c,00,73,00,79,00,73,00,74,00,65,00,6d,00,33,00,32,00,5c,00,73,\
00,76,00,63,00,68,00,6f,00,73,00,74,00,2e,00,65,00,78,00,65,00,20,00,2d,00,\
6b,00,20,00,4c,00,6f,00,63,00,61,00,6c,00,53,00,65,00,72,00,76,00,69,00,63,\
00,65,00,00,00
«Description»=»@%SystemRoot%\\System32\\SCardSvr.dll,-5»
«ObjectName»=»NT AUTHORITY\\LocalService»
«ErrorControl»=dword:00000001
«Start»=dword:00000002
«Type»=dword:00000020
«DependOnService»=hex(7):50,00,6c,00,75,00,67,00,50,00,6c,00,61,00,79,00,00,00,\
00,00
«ServiceSidType»=dword:00000001
«RequiredPrivileges»=hex(7):53,00,65,00,43,00,72,00,65,00,61,00,74,00,65,00,47,\
00,6c,00,6f,00,62,00,61,00,6c,00,50,00,72,00,69,00,76,00,69,00,6c,00,65,00,\
67,00,65,00,00,00,53,00,65,00,43,00,68,00,61,00,6e,00,67,00,65,00,4e,00,6f,\
00,74,00,69,00,66,00,79,00,50,00,72,00,69,00,76,00,69,00,6c,00,65,00,67,00,\
65,00,00,00,53,00,65,00,49,00,6d,00,70,00,65,00,72,00,73,00,6f,00,6e,00,61,\
00,74,00,65,00,50,00,72,00,69,00,76,00,69,00,6c,00,65,00,67,00,65,00,00,00,\
00,00
«FailureActions»=hex:84,03,00,00,00,00,00,00,00,00,00,00,03,00,00,00,14,00,00,\
00,01,00,00,00,c0,d4,01,00,01,00,00,00,e0,93,04,00,00,00,00,00,00,00,00,00
«ServiceDll»=hex(2):25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,6f,00,6f,\
00,74,00,25,00,5c,00,53,00,79,00,73,00,74,00,65,00,6d,00,33,00,32,00,5c,00,\
53,00,43,00,61,00,72,00,64,00,53,00,76,00,72,00,2e,00,64,00,6c,00,6c,00,00,\
00
«ServiceMain»=»CalaisMain»
«ServiceDllUnloadOnStop»=dword:00000001 [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SCardSvr\Security]
«Security»=hex:01,00,14,90,90,00,00,00,a0,00,00,00,14,00,00,00,34,00,00,00,02,\
00,20,00,01,00,00,00,02,c0,18,00,00,00,0c,00,01,02,00,00,00,00,00,05,20,00,\
00,00,20,02,00,00,02,00,5c,00,04,00,00,00,00,02,14,00,ff,01,0f,00,01,01,00,\
00,00,00,00,05,12,00,00,00,00,00,18,00,ff,01,02,00,01,02,00,00,00,00,00,05,\
20,00,00,00,20,02,00,00,00,00,14,00,8d,01,02,00,01,01,00,00,00,00,00,05,04,\
00,00,00,00,00,14,00,8d,01,02,00,01,01,00,00,00,00,00,05,06,00,00,00,01,02,\
00,00,00,00,00,05,20,00,00,00,20,02,00,00,01,02,00,00,00,00,00,05,20,00,00,\
00,20,02,00,00
Smart card service for Windows Seven
Windows Registry Editor Version 5.00
_MACHINE\SYSTEM\CurrentControlSet\services\SCardSvr]
«DisplayName»=»Smart Card»
«Group»=»SmartCardGroup»
«ImagePath»=hex(2):25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,6f,00,6f,00,\
74,00,25,00,5c,00,73,00,79,00,73,00,74,00,65,00,6d,00,33,00,32,00,5c,00,73,\
00,76,00,63,00,68,00,6f,00,73,00,74,00,2e,00,65,00,78,00,65,00,20,00,2d,00,\
6b,00,20,00,4c,00,6f,00,63,00,61,00,6c,00,53,00,65,00,72,00,76,00,69,00,63,\
00,65,00,41,00,6e,00,64,00,4e,00,6f,00,49,00,6d,00,70,00,65,00,72,00,73,00,\
6f,00,6e,00,61,00,74,00,69,00,6f,00,6e,00,00,00
«Description»=»@%SystemRoot%\\System32\\SCardSvr.dll,-5»
«ObjectName»=»NT AUTHORITY\\LocalService»
«ErrorControl»=dword:00000001
«Start»=dword:00000002
«Type»=dword:00000020
«DependOnService»=hex(7):50,00,6c,00,75,00,67,00,50,00,6c,00,61,00,79,00,00,00,\
00,00
«ServiceSidType»=dword:00000001
«RequiredPrivileges»=hex(7):53,00,65,00,43,00,72,00,65,00,61,00,74,00,65,00,47,\
00,6c,00,6f,00,62,00,61,00,6c,00,50,00,72,00,69,00,76,00,69,00,6c,00,65,00,\
67,00,65,00,00,00,53,00,65,00,43,00,68,00,61,00,6e,00,67,00,65,00,4e,00,6f,\
00,74,00,69,00,66,00,79,00,50,00,72,00,69,00,76,00,69,00,6c,00,65,00,67,00,\
65,00,00,00,00,00
«FailureActions»=hex:84,03,00,00,00,00,00,00,00,00,00,00,03,00,00,00,14,00,00,\
00,01,00,00,00,c0,d4,01,00,01,00,00,00,e0,93,04,00,00,00,00,00,00,00,00,00
«ServiceDll»=hex(2):25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,6f,00,6f,\
00,74,00,25,00,5c,00,53,00,79,00,73,00,74,00,65,00,6d,00,33,00,32,00,5c,00,\
53,00,43,00,61,00,72,00,64,00,53,00,76,00,72,00,2e,00,64,00,6c,00,6c,00,00,\
00
«ServiceMain»=»CalaisMain»
«ServiceDllUnloadOnStop»=dword:00000001 [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\SCardSvr\Security]
«Security»=hex:01,00,14,80,90,00,00,00,a0,00,00,00,14,00,00,00,34,00,00,00,02,\
00,20,00,01,00,00,00,02,c0,18,00,00,00,0c,00,01,02,00,00,00,00,00,05,20,00,\
00,00,20,02,00,00,02,00,5c,00,04,00,00,00,00,02,14,00,ff,01,0f,00,01,01,00,\
00,00,00,00,05,12,00,00,00,00,00,18,00,ff,01,02,00,01,02,00,00,00,00,00,05,\
20,00,00,00,20,02,00,00,00,00,14,00,8d,01,02,00,01,01,00,00,00,00,00,05,04,\
00,00,00,00,00,14,00,8d,01,02,00,01,01,00,00,00,00,00,05,06,00,00,00,01,02,\
00,00,00,00,00,05,20,00,00,00,20,02,00,00,01,02,00,00,00,00,00,05,20,00,00,\
00,20,02,00,00
Save this to a file, change the extension to .reg and double-click it to merge it into the registry.