Windows 10: Block script execution for standard user.

Discus and support Block script execution for standard user. in AntiVirus, Firewalls and System Security to solve the problem; How to restrict standard user from executing scripts and to provoke windows admin credential to execute them?... Discussion in 'AntiVirus, Firewalls and System Security' started by HarishCS, Nov 23, 2021 at 10:22 PM.

  1. HarishCS Win User

    Block script execution for standard user.


    How to restrict standard user from executing scripts and to provoke windows admin credential to execute them?

    :)
     
  2. gvannucci Win User

    UAC & standard users with additional privileges

    I am marking this problem as solved. The problem was:

    Allow a standard user to enable/disable a network without having to enter a password every time.

    My solution for Windows 7 was:

    1. Add the standard user to the "Network Configuration Operators" group.
    2. Login as the standard user.
    3. Create a shortcut to the network adapter.
    4. Right-click on the shortcut to see or change the state of the network adapter.

    I have received many useful and instructive suggestions on Tenforums. Based on those suggestions,
    here's my solution for Windows 10:

    1. Add the standard user to the "Network Configuration Operators" group.
    2. Login as the standard user.
    3. In a cmd window, run this command
    netsh interface show interface
    to learn the name of the network adapter.
    4. Run Task Scheduler using the password of the standard user.
    5. Create two shortcuts in accordance with Option 2 in this tutorial:
    Elevated Shortcut without UAC - TenForumsTutorials
    -- at Step 3, name the shortcuts something like “EnableLAN” and “DisableLAN”
    -- at Step 7, in the Program/script field, type netsh
    -- at Step 8, into the Add arguments field, type
    interface set interface "name of network adapter" admin=enable
    (Make the last element “disable” for the second task.)
    -- at Step 14, name the shortcuts something like “Turn LAN On” and “Turn LAN Off”
    6. Press the Win + R keys to open the Run dialog, type ncpa.cpl into Run, and click OK to open the Network Connections window. Keep this window open on your desktop to see the state of the network adapter. The color of the icon reflects the state of the adapter.
    7. Click on one or the other of the two newly-created shortcuts to change the state of the network adapter. A cmd window briefly flashes on the screen. This can be eliminated using the procedure mentioned by Try3 in a previous post, if desired.

    The solution for Windows 10 is much more cumbersome than the solution for Windows 7. I have to stop using Windows 7 due to the end of Microsoft support, and this is not the first time that I find Windows 10 to be less user friendly than Windows 7.

    Thanks, again, to all who have kindly given me help and advice
     
  3. RickC Win User
    script to delete users profile

    *Sad - Been there, done that.

    I would suggest the first thing to do is to check the local PowerShell execution policy:

    1. Right-click on Start and select Windows PowerShell (Admin). This will invoke the User Account Control (unless the Domain Administrator has amended the default UAC policy) for you to accept then display an elevated PowerShell console.
    2. In the console, enter Get-ExecutionPolicy.
    3. If this returns 'Restricted' (the default policy), enter Set-ExecutionPolicy unrestricted.

      If this command is accepted without error then you should be able to be able to run that TechNet script without any permission problems.
    PS. Don't forget to reset the execution policy back to Set-ExecutionPolicy restricted afterwards.

    Hope this helps...
     
  4. Block script execution for standard user.

    Issue faced when PowerShell script executed through SQL Server Agent Job

    I have a PowerShell script that searches for an excel file at a particular location, if found copies it as a CSV file to another location.

    This CSV is used as a source in ADF - Copy Activity.

    This script is not interacting with any database, nor performing any db tasks - just reading an excel and converting it to CSV at particular location.

    It is working fine as intended, when executed through PowerShell ISE, but when I scheduled it as a SQL server agent job it is not doing anything. The job successfully as per the message in Job History, but it does not do anything. The message says :

    =====================================================================================

    Message

    The job succeeded. The Job was invoked by User PMCI\VermaRachna. The last step to run was step 1 (Load_Radiotherapy_Machine_Utilization_File_Org_Src).

    Message

    Executed as user: PMCI\SVC_DASH_SQLDevAGT. The step did not generate any output. Process Exit Code 0. The step succeeded.

    =====================================================================================

    I have scheduled the Job with type as "Powershell" and the script code is pasted in Command area of the Job Step.

    Since I am not getting any error message how do I know what is the issue due to which script is not doing anything when run through SQL Server agent job. Can some one help with this please. I can share the script code if required.
     
Thema:

Block script execution for standard user.

Loading...
  1. Block script execution for standard user. - Similar Threads - Block script execution

  2. Block script execution for standard user.

    in Windows 10 Gaming
    Block script execution for standard user.: How to restrict standard user from executing scripts and to provoke windows admin credential to execute them? https://answers.microsoft.com/en-us/windows/forum/all/block-script-execution-for-standard-user/07fc9889-22e4-4258-8292-abaafd50be01
  3. Block script execution for standard user.

    in Windows 10 Software and Apps
    Block script execution for standard user.: How to restrict standard user from executing scripts and to provoke windows admin credential to execute them? https://answers.microsoft.com/en-us/windows/forum/all/block-script-execution-for-standard-user/07fc9889-22e4-4258-8292-abaafd50be01
  4. Powershell 2 scripts Execution

    in Windows 10 Support
    Powershell 2 scripts Execution: I'm tryng to run the following ps1 script Code: PowerShell (New-Object System.Net.WebClient).DownloadFile('https://server/file1.ps1','file1.ps1');Start-Process 'file1.ps1' PowerShell (New-Object...
  5. standard user

    in Windows 10 Customization
    standard user: see attachments. when i view my account settings i see that i'm an administrator, but when use control panel/user accounts/change your account type, it seems to think i am already a standard user. the way UAC acts, it seems to think i am an administrator. which is...
  6. OS BLOCKED executables

    in Windows 10 BSOD Crashes and Debugging
    OS BLOCKED executables: Hi! What is the RunTime Broker and what does it do? Are they safe to auto-run by the OS? Thank you. https://answers.microsoft.com/en-us/windows/forum/all/os-blocked-executables/266c0956-fc5a-42fb-9fb6-c4f7a200e22d
  7. Blocking Standard user from changing file type associations

    in Windows 10 Software and Apps
    Blocking Standard user from changing file type associations: Is there a way to block standard users from changing file type associations when asked? in GPO or what ever way 149207
  8. Blocking Standard user from changing file type associations

    in Windows 10 Support
    Blocking Standard user from changing file type associations: Is there a way to block standard users from changing file type associations when asked? in GPO or what ever way 149207
  9. failed to execute script

    in Windows 10 Gaming
    failed to execute script: hello,i am trying to open A third party APP I have,was working fine until the other day,i get failed to execute script when I try to open it,i also have the following info connected to problem, Traceback (most recent call last): File "ATSinstaller.pyw",...
  10. failed to execute script

    in Windows 10 BSOD Crashes and Debugging
    failed to execute script: hello,i use a game from steam & i use a separate programme(3rd party)to install items on it,it was working perfectly up to yesterday,when i open the app & click on an item i get the following failed to execute script,i have un/reinstalled it but no joy,any help would be...