Merge pull request #333 from aleff-github/patch-52

Starting a PowerShell with administrator permissions in Windows
pull/361/merge
Darren Kitchen 2023-06-09 19:57:01 -05:00 committed by GitHub
commit 8a9eec87d9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 61 additions and 0 deletions

View File

@ -0,0 +1,30 @@
# Starting a PowerShell with administrator permissions in Windows 10/11
This script can be considered by people who are new to the world of scripts written in DuckyScript so that they can understand how to start a PowerShell with administrator permissions on a Windows machine.
**Category**: Execute
## Description
This script can be considered by people who are new to the world of scripts written in DuckyScript so that they can understand how to start a PowerShell with administrator permissions on a Windows machine.
Starting a PowerShell session with administrator privileges means the session has access to features and operations that require high permissions on the Windows operating system.
Some PowerShell commands require administrator privileges to run properly. Starting PowerShell as an administrator allows you to execute commands that require elevated permissions, such as managing system services, changing security settings, creating or modifying user accounts, installing system-level software, and so on.
It is important to note that running PowerShell with administrator privileges involves a higher level of responsibility and can cause significant changes to the system. Therefore, it is advisable to be careful and fully understand the effects of operations performed in a session with administrator privileges to avoid unwanted or harmful changes.
## Dependencies
* Nothing
## Example
- `STRINGLN Get-ExecutionPolicy -List`
![](docs/1.png)
- `STRINGLN Set-ExecutionPolicy Bypass`
![](docs/2.png)
- `STRINGLN Get-ExecutionPolicy -List`
![](docs/3.png)

Binary file not shown.

After

Width:  |  Height:  |  Size: 25 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 57 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 65 KiB

View File

@ -0,0 +1,31 @@
REM ####################################################################################
REM # |
REM # Title : Starting a PowerShell with administrator permissions in Windows |
REM # Author : Aleff |
REM # Version : 1.0 |
REM # Category : Execute |
REM # Target : Windows 10-11 |
REM # |
REM ####################################################################################
REM Requirements:
REM - Nothing
DELAY 1000
GUI x
DELAY 500
STRING a
DELAY 500
LEFT_ARROW
DELAY 500
ENTER
DELAY 2000
STRINGLN Get-ExecutionPolicy -List
DELAY 500
STRINGLN Set-ExecutionPolicy Bypass
DELAY 500
STRINGLN Get-ExecutionPolicy -List
DELAY 500
ALT F4