TestimoX

API Reference

Command

Set-CxAccountPolicy

Namespace ComputerX.PowerShell
Inputs
System.String

Sets local Account Policy (password/lockout) on SAM (local or remote).

Examples

Authored help example

Example 1


Set-CxAccountPolicy -MinPasswordLength 14 -MaxPasswordAgeDays 365 -PasswordHistorySize 24
        

Example 2


Set-CxAccountPolicy -ComputerName SERVER01 -LockoutThreshold 10 -LockoutDurationMinutes 30 -LockoutResetMinutes 30
        

Common Parameters

This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.

For more information, see about_CommonParameters.

Syntax

Set-CxAccountPolicy [-ComputerName <string>] [-LockoutDurationMinutes <int>] [-LockoutResetMinutes <int>] [-LockoutThreshold <int>] [-MaxPasswordAgeDays <int>] [-MinPasswordAgeDays <int>] [-MinPasswordLength <int>] [-PasswordHistorySize <int>] [<CommonParameters>]
#

Parameters

ComputerName string optionalposition: 0pipeline: true (ByPropertyName)
Target computer(s). Use '.' for local computer or provide DNS names.
LockoutDurationMinutes int optionalposition: namedpipeline: false
Gets or sets the LockoutDurationMinutes parameter.
LockoutResetMinutes int optionalposition: namedpipeline: false
Gets or sets the LockoutResetMinutes parameter.
LockoutThreshold int optionalposition: namedpipeline: false
Gets or sets the LockoutThreshold parameter.
MaxPasswordAgeDays int optionalposition: namedpipeline: false
Gets or sets the MaxPasswordAgeDays parameter.
MinPasswordAgeDays int optionalposition: namedpipeline: false
Gets or sets the MinPasswordAgeDays parameter.
MinPasswordLength int optionalposition: namedpipeline: false
Gets or sets the MinPasswordLength parameter.
PasswordHistorySize int optionalposition: namedpipeline: false
Gets or sets the PasswordHistorySize parameter.