aboutsummaryrefslogtreecommitdiff
path: root/docs/Privesc/Add-ServiceDacl.md
diff options
context:
space:
mode:
authorDave Hull <dave.hull@tanium.com>2017-09-08 16:33:11 -0500
committerDave Hull <dave.hull@tanium.com>2017-09-08 16:33:11 -0500
commit6eb3c6f281f0812a103283d1da80be14bb04f944 (patch)
treecfe2e46596ef251274e954c267c5634d62991da2 /docs/Privesc/Add-ServiceDacl.md
parentbf652bcd261c2c74445c2aa1b4e283c4bf167109 (diff)
parent3d0d32d9ee6af70f0dfd5ecfe809a49a65d6822d (diff)
downloadPowerSploit-6eb3c6f281f0812a103283d1da80be14bb04f944.tar.gz
PowerSploit-6eb3c6f281f0812a103283d1da80be14bb04f944.zip
Merge branch 'dev' of github.com:PowerShellMafia/PowerSploit into dev
Diffstat (limited to 'docs/Privesc/Add-ServiceDacl.md')
-rwxr-xr-xdocs/Privesc/Add-ServiceDacl.md68
1 files changed, 68 insertions, 0 deletions
diff --git a/docs/Privesc/Add-ServiceDacl.md b/docs/Privesc/Add-ServiceDacl.md
new file mode 100755
index 0000000..13e4d64
--- /dev/null
+++ b/docs/Privesc/Add-ServiceDacl.md
@@ -0,0 +1,68 @@
+# Add-ServiceDacl
+
+## SYNOPSIS
+Adds a Dacl field to a service object returned by Get-Service.
+
+Author: Matthew Graeber (@mattifestation)
+License: BSD 3-Clause
+Required Dependencies: PSReflect
+
+## SYNTAX
+
+```
+Add-ServiceDacl [-Name] <String[]>
+```
+
+## DESCRIPTION
+Takes one or more ServiceProcess.ServiceController objects on the pipeline and adds a
+Dacl field to each object.
+It does this by opening a handle with ReadControl for the
+service with using the GetServiceHandle Win32 API call and then uses
+QueryServiceObjectSecurity to retrieve a copy of the security descriptor for the service.
+
+## EXAMPLES
+
+### -------------------------- EXAMPLE 1 --------------------------
+```
+Get-Service | Add-ServiceDacl
+```
+
+Add Dacls for every service the current user can read.
+
+### -------------------------- EXAMPLE 2 --------------------------
+```
+Get-Service -Name VMTools | Add-ServiceDacl
+```
+
+Add the Dacl to the VMTools service object.
+
+## PARAMETERS
+
+### -Name
+An array of one or more service names to add a service Dacl for.
+Passable on the pipeline.
+
+```yaml
+Type: String[]
+Parameter Sets: (All)
+Aliases: ServiceName
+
+Required: True
+Position: 1
+Default value: None
+Accept pipeline input: True (ByPropertyName, ByValue)
+Accept wildcard characters: False
+```
+
+## INPUTS
+
+## OUTPUTS
+
+### ServiceProcess.ServiceController
+
+## NOTES
+
+## RELATED LINKS
+
+[https://rohnspowershellblog.wordpress.com/2013/03/19/viewing-service-acls/](https://rohnspowershellblog.wordpress.com/2013/03/19/viewing-service-acls/)
+