< Back

Add-Privilege

Sat Jan 18, 2020 8:25 pm

NAME Add-Privilege



SYNOPSIS

Adds a specified privilege for a user or group





SYNTAX

Add-Privilege [[-AccountName] <String>] [-Privilege] {SeAssignPrimaryTokenPrivilege | SeAuditPrivilege |

SeBackupPrivilege | SeBatchLogonRight | SeChangeNotifyPrivilege | SeCreateGlobalPrivilege |

SeCreatePagefilePrivilege | SeCreatePermanentPrivilege | SeCreateSymbolicLinkPrivilege | SeCreateTokenPrivilege |

SeDebugPrivilege | SeImpersonatePrivilege | SeIncreaseBasePriorityPrivilege | SeIncreaseQuotaPrivilege |

SeInteractiveLogonRight | SeLoadDriverPrivilege | SeLockMemoryPrivilege | SeMachineAccountPrivilege |

SeManageVolumePrivilege | SeNetworkLogonRight | SeProfileSingleProcessPrivilege | SeRemoteInteractiveLogonRight |

SeRemoteShutdownPrivilege | SeRestorePrivilege | SeSecurityPrivilege | SeServiceLogonRight | SeShutdownPrivilege |

SeSystemEnvironmentPrivilege | SeSystemProfilePrivilege | SeSystemtimePrivilege | SeTakeOwnershipPrivilege |

SeTcbPrivilege | SeTimeZonePrivilege | SeUndockPrivilege | SeDenyNetworkLogonRight | SeDenyBatchLogonRight |

SeDenyServiceLogonRight | SeDenyInteractiveLogonRight | SeSyncAgentPrivilege | SeEnableDelegationPrivilege |

SeDenyRemoteInteractiveLogonRight | SeTrustedCredManAccessPrivilege | SeIncreaseWorkingSetPrivilege} [-WhatIf]

[-Confirm] [<CommonParameters>]





DESCRIPTION

Adds a specified privilege for a user or group. This will remain until

removed using Remove-Privilege or a policy is refreshed.





PARAMETERS

-AccountName <String>

The user or group which will have the privilege added for.



Required? false

Position? 1

Default value ("{0}\\{1}" -f ($env:USERDOMAIN, $env:USERNAME))

Accept pipeline input? false

Accept wildcard characters? false



-Privilege

Specific privilege/s to add on the local machine



Required? true

Position? 2

Default value

Accept pipeline input? false

Accept wildcard characters? false



-WhatIf [<SwitchParameter>]



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-Confirm [<SwitchParameter>]



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,

ErrorAction, ErrorVariable, WarningAction, WarningVariable,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).



INPUTS



OUTPUTS



NOTES





Name: Add-Privilege

Author: Boe Prox

Version History:

1.0 - Initial Version



-------------------------- EXAMPLE 1 --------------------------



PS C:\\>Add-Privilege -AccountName Domain\\SomeUser -Privilege SeBackupPrivilege



Description

-----------

Adds the SeBackupPrivilege privilege for Domain\\SomeUser











RELATED LINKS