{"id":3152,"date":"2016-05-24T20:45:04","date_gmt":"2016-05-24T15:15:04","guid":{"rendered":"http:\/\/198.58.113.91\/blog\/?p=3152"},"modified":"2019-06-22T02:18:47","modified_gmt":"2019-06-22T02:18:47","slug":"windows-script-host-disabled-machine-contact-administator","status":"publish","type":"post","link":"https:\/\/www.winhelponline.com\/blog\/windows-script-host-disabled-machine-contact-administator\/","title":{"rendered":"[Fix] Windows Script Host Access is Disabled on this Machine"},"content":{"rendered":"<p>When you run a Windows script using wscript.exe or cscript.exe, error <strong>Windows Script Host access is disabled on this machine<\/strong> may pop-up. However, in systems affected by malware, the error appears at regular intervals, <strong>without<\/strong> any script invocation by the user.<\/p>\n<p>So the key questions are:<!--more--><\/p>\n<ol>\n<li>Which script is being run that causes the error message?<\/li>\n<li>How do I enable Windows Script Host access in the machine?<\/li>\n<\/ol>\n<p>This post address those questions.<\/p>\n<div id=\"toc\">\n<h4>Contents<\/h4>\n<ul>\n<li><a href=\"#important\">[Fix] Windows Script Host Access is Disabled on this Machine<\/a>\n<ul>\n<li><a href=\"#investigate\">Cause: Investigate which script is trying to run<\/a><\/li>\n<li><a href=\"#wsh_enable\">Solution: How to <strong>enable Windows Script Host<\/strong> access<img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-6347 alignright\" src=\"https:\/\/www.winhelponline.com\/blog\/wp-content\/uploads\/2018\/07\/regedit-icon-small.png\" alt=\"regedit icon\" width=\"28\" height=\"28\" \/><\/a><\/li>\n<\/ul>\n<\/ul>\n<\/div>\n<h2><a id=\"important\"><\/a>[Fix] Windows Script Host Access is Disabled on this Machine<\/h2>\n<p>If the message &#8220;Windows Script Host access is disabled&#8221; appears at every startup or in regular intervals without you doing anything, then a malware script (.vbs, .js or .wsf) may be trying to run in the background, and is prevented by Windows Script Host restriction in effect in your system, which is very good. In such cases, your aim should be to eliminate the malware from the system completely rather than fixing the script host error message.<\/p>\n<p>Run a thorough malware scan in your system first. Until every trace of malware is removed, do not lift the script host restriction. The restriction is only protecting your system.<\/p>\n<h3><a id=\"investigate\"><\/a>Investigate which script is trying to run that causes the error?<\/h3>\n<p>If the error appears without you manually launching a script, then it&#8217;s possible that a malware script is trying to run in the background, probably as a scheduled task.<\/p>\n<h4>Use Task Manager to find the script file name<\/h4>\n<p>You can use a simple tool like Task Manager to find out the script file name that&#8217;s being executed. Use these steps:<\/p>\n<ol>\n<li>Let the script error window be on the screen. Don&#8217;t dismiss it yet.<\/li>\n<li>Disconnect your computer from the internet.<\/li>\n<li>Open Task Manager (<kbd>Ctrl<\/kbd> + <kbd>Shift<\/kbd> + <kbd>Esc<\/kbd>) and click the Details tab.<\/li>\n<li>Right-click the column header, click Select Columns.\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.winhelponline.com\/blog\/wp-content\/uploads\/2008\/03\/taskmgr_command_line_1.png\" alt=\"task manager show command line\" width=\"282\" height=\"154\" class=\"alignnone size-full wp-image-4334\" \/><\/li>\n<li>Enable the <strong>Command line<\/strong> checkbox and click OK.<br \/>\n<img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.winhelponline.com\/blog\/wp-content\/uploads\/2008\/03\/taskmgr_command_line_2.png\" alt=\"task manager show command line\" width=\"305\" height=\"321\" class=\"alignnone size-full wp-image-4335\" \/><\/p>\n<p><em><strong>RELATED:<\/strong> Check out post <a href=\"https:\/\/www.winhelponline.com\/blog\/configure-task-manager-to-display-full-path-of-running-processes\/\">Configure Task Manager to display full path of running processes<\/a> for more information and screenshots.<\/em><\/p>\n<p>This shows the complete path and file name of the script file which is trying to run silently. In this example, a script file named protect.vbs is trying to run from the %TEMP% folder of the user profile.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-4319\" src=\"https:\/\/www.winhelponline.com\/blog\/wp-content\/uploads\/2016\/05\/wshenable-2.png\" alt=\"windows script host access is disabled on this machine\" width=\"700\" height=\"376\" \/><\/p>\n<p><em><strong>Related:<\/strong> Process Explorer from Windows SysInternals can be used to find the process name, path and full arguments. Check out post <a href=\"https:\/\/www.winhelponline.com\/blog\/determine-program-process-owns-error-message-window\/\">How to Find Which Program Caused An Unknown Error Message?<\/a> for details.<\/em><\/li>\n<\/ol>\n<h4>Use Advanced Troubleshooting Tools<\/h4>\n<p>Further, you can <a href=\"https:\/\/www.winhelponline.com\/blog\/clean-boot-windows-autoruns\/\">use Autoruns<\/a>, another excellent tool from Microsoft Windows SysInternals to find the startup launch-point (Startup or Task Scheduler) used by that malware script.<\/p>\n<p>Start your investigation from there. If you&#8217;re an advanced user, you can even edit the script file using Notepad and see what code is being executed. Ransomware usually employs .vbs, .js, .wsh or .hta files to download the crypto-ransomware payload from a remote server, run it on your local system and encrypt your data or erase them completely.<\/p>\n<p>First of all, if someone could drop a malware script in your TEMP directory and launch it, then there exists some really serious vulnerability in your system. Antivirus and anti-malware protection may not always help if your system is vulnerable to an exploit. You should make sure that your system is up to date in terms of Windows Update patches, as well as updates for the programs you&#8217;re using in your system.<\/p>\n<p>Do a thorough checkup using a reputed anti-malware tool such as Malwarebytes.<\/p>\n<h3><a id=\"wsh_enable\"><\/a>How do I enable Windows Script Host access?<\/h3>\n<p>If your system is not connected to a domain, here are the steps to remove the error &#8220;Windows Script Host Access is Disabled&#8221;. This procedure will enable running Windows Scripts (.vbs or .js) on your system.<\/p>\n<h4>Enable Windows Script Host access using the Registry Editor<\/h4>\n<ol>\n<li>Press <kbd>WinKey<\/kbd> + <kbd>R<\/kbd> to bring up the Run dialog.<\/li>\n<li>Type <code>regedit.exe<\/code><\/li>\n<li>Delete the value named <strong>Enabled<\/strong> in following keys:\n<pre>HKEY_CURRENT_USER\\SOFTWARE\\Microsoft\\Windows Script Host\\Settings\r\nHKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows Script Host\\Settings<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-3153\" src=\"https:\/\/www.winhelponline.com\/blog\/wp-content\/uploads\/2016\/05\/wshenable.png\" alt=\"Windows Script Host access is disabled on this machine\" width=\"463\" height=\"246\" \/><br \/>\nIf a key doesn&#8217;t exist, ignore and check the next key.<\/li>\n<li>Exit the Registry Editor.<\/li>\n<\/ol>\n<h4>Enable Windows Script Host access using command-line<\/h4>\n<p>To do this using command-line, execute these commands from <a href=\"https:\/\/www.winhelponline.com\/blog\/open-elevated-command-prompt-windows\/\">elevated Command Prompt<\/a>:<\/p>\n<pre>REG DELETE \"HKCU\\SOFTWARE\\Microsoft\\Windows Script Host\\Settings\" \/v Enabled \/f\r\nREG DELETE \"HKLM\\SOFTWARE\\Microsoft\\Windows Script Host\\Settings\" \/v Enabled \/f<\/pre>\n<p>With the Windows Script Host restrictions lifted, you should only run scripts from trusted sources and if you&#8217;re sure they are safe to run.<\/p>\n<p>That&#8217;s it! This enables Windows Scripting host on your computer.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>When you run a Windows script using wscript.exe or cscript.exe, error Windows Script Host access is disabled on this machine may pop-up. However, in systems affected by malware, the error appears at regular intervals, without any script invocation by the user. So the key questions are:<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_feature_clip_id":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_post_was_ever_published":false},"categories":[7],"tags":[191,441],"class_list":["post-3152","post","type-post","status-publish","format-standard","hentry","category-windows","tag-error-messages","tag-registry"],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack-related-posts":[{"id":8717,"url":"https:\/\/www.winhelponline.com\/blog\/enable-or-disable-defender-shortcut-command-line\/","url_meta":{"origin":3152,"position":0},"title":"Enable or Disable Windows Defender Using Shortcut or Command-line","author":"Ramesh","date":"April 18, 2019","format":false,"excerpt":"Windows Defender, the built-in anti-virus program in Windows, has useful features such as cloud-based protection, offline scanning, limited periodic scanning, tamper protection, controlled folder access, etc. Almost every aspect of Windows Defender can be managed or automated using the MpCmdrun.exe command-line tool and PowerShell cmdlets. There are times when you\u2026","rel":"","context":"In &quot;Utilities&quot;","block_context":{"text":"Utilities","link":"https:\/\/www.winhelponline.com\/blog\/category\/utilities\/"},"img":{"alt_text":"advancedrun command-line to disable defender","src":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2019\/04\/advanced-run-command-line-defender.png?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]},{"id":1666,"url":"https:\/\/www.winhelponline.com\/blog\/cannot-find-script-run-vbs-logon\/","url_meta":{"origin":3152,"position":1},"title":"Fix &#8220;Can not find script file C:\\WINDOWS\\run.vbs&#8221; at Logon","author":"Ramesh","date":"February 20, 2016","format":false,"excerpt":"When you log on to your computer, the error \"Can not find script file C:\\WINDOWS\\run.vbs\" with Windows Script Host in the title is shown on a blank screen with a black background. This happens if malware has modified the Userinit registry value, replacing the Windows default value data with a\u2026","rel":"","context":"In &quot;Windows&quot;","block_context":{"text":"Windows","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/w10\/run_vbs_err-1.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/w10\/run_vbs_err-1.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/w10\/run_vbs_err-1.png?resize=525%2C300&ssl=1 1.5x"},"classes":[]},{"id":54263,"url":"https:\/\/www.winhelponline.com\/blog\/windows-script-host-error-run-vbs\/","url_meta":{"origin":3152,"position":2},"title":"Windows Script Host error in AppData\\Local\\Updates\\Run.vbs. The System cannot find the file specified","author":"Ramesh","date":"June 17, 2023","format":false,"excerpt":"When you login to your account,\u00a0you may see a Windows Script Host error similar to the following: Windows Script Host Script: C:\\Users\\{username}\\AppData\\Local\\Updates\\Run.vbs Line: 31 Char: 1 Error: The system cannot find the file specified. Code: 80070002 Source: (null) Additionally, on some systems, you may see a WindowsService.exe popup window that\u2026","rel":"","context":"In &quot;Windows 10&quot;","block_context":{"text":"Windows 10","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/windows-10\/"},"img":{"alt_text":"windowsservice.exe malware","src":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2023\/06\/windowsservice-exe-pop-up.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2023\/06\/windowsservice-exe-pop-up.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2023\/06\/windowsservice-exe-pop-up.png?resize=525%2C300&ssl=1 1.5x, https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2023\/06\/windowsservice-exe-pop-up.png?resize=700%2C400&ssl=1 2x"},"classes":[]},{"id":18205,"url":"https:\/\/www.winhelponline.com\/blog\/script-error-maintenance-vbs-at-startup\/","url_meta":{"origin":3152,"position":3},"title":"[Fix] Script Error C:\\Windows\\system32 Maintenance.vbs at Startup","author":"Ramesh","date":"August 31, 2020","format":false,"excerpt":"Whenever you start your computer, the following error may popup: Windows Script Host Script: C:\\WINDOWS\\system32\\Maintenance.vbs Line: 10 Char: 2 Error: Type mismatch 'CInt' Code: 800A000D Source: Microsoft VBScript runtime error However, you may find no reference to this file in MSConfig or the Task Manager Startup tab. You may be\u2026","rel":"","context":"In &quot;Windows&quot;","block_context":{"text":"Windows","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/"},"img":{"alt_text":"installwinsat maintenance.vbs error","src":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2020\/08\/installwinsat-maintenance-error-1.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2020\/08\/installwinsat-maintenance-error-1.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2020\/08\/installwinsat-maintenance-error-1.png?resize=525%2C300&ssl=1 1.5x, https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2020\/08\/installwinsat-maintenance-error-1.png?resize=700%2C400&ssl=1 2x"},"classes":[]},{"id":166,"url":"https:\/\/www.winhelponline.com\/blog\/clear-recent-files-history-in-a-single-click-in-windows\/","url_meta":{"origin":3152,"position":4},"title":"Clear Recent Files history Using Script in Windows 10","author":"Ramesh","date":"April 7, 2008","format":false,"excerpt":"Did you notice that in Windows it takes exactly half a dozen mouse clicks to clear the recent items history? This post has a VBScript to clear the recent documents history in a single click in Windows 10 and earlier. Clear Recent Files history in Windows In Windows 10, here\u2026","rel":"","context":"In &quot;Windows&quot;","block_context":{"text":"Windows","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/"},"img":{"alt_text":"clear quick access history","src":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/w10\/w10-quickaccess-3.png?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]},{"id":5610,"url":"https:\/\/www.winhelponline.com\/blog\/use-controlled-folder-access-windows-10-windows-defender\/","url_meta":{"origin":3152,"position":5},"title":"How to Configure Controlled Folder Access to Stop &#8220;Unauthorized changes blocked&#8221; Notifications","author":"Ramesh","date":"October 21, 2017","format":false,"excerpt":"Windows 10 and 11 include a beneficial security feature named Controlled folder access, which is part of the Microsoft Defender Exploit Guard. You may have noticed the Unauthorized changes blocked notifications. Microsoft Defender's Controlled folder access feature is the one behind those notifications. Controlled folder access helps you protect valuable\u2026","rel":"","context":"In &quot;Windows 10&quot;","block_context":{"text":"Windows 10","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/windows-10\/"},"img":{"alt_text":"defender controlled folder access - blocked apps list","src":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2017\/10\/wevtutil-defender-blocked-list.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2017\/10\/wevtutil-defender-blocked-list.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2017\/10\/wevtutil-defender-blocked-list.png?resize=525%2C300&ssl=1 1.5x"},"classes":[]}],"_links":{"self":[{"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/posts\/3152","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/comments?post=3152"}],"version-history":[{"count":0,"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/posts\/3152\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/media?parent=3152"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/categories?post=3152"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/tags?post=3152"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}