SALES: 1-800-867-1380
Get-MsolPasswordPolicy
TOC
Collapse the table of content
Expand the table of content

Get-MsolPasswordPolicy

Published: April 18, 2013

Updated: July 30, 2015

Applies To: Azure, Office 365, Windows Intune

noteNote
  • The cmdlets were previously known as the Microsoft Online Services Module for Windows PowerShell cmdlets.

The Get-MsolPasswordPolicy cmdlet can be used to retrieve the values associated with the Password Expiry window or Password Expiry Notification window for a tenant or specified domain. When a domain name is specified, it must be a verified domain for the company.

Syntax

Get-MsolPasswordPolicy -DomainName <string> [<CommonParameters>]

Parameters

    -DomainName <string>
        The fully qualified name of the domain to be retrieved.
        
        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 
    (http://go.microsoft.com/fwlink/?LinkID=113216).

Examples

The following values will be returned either for the specified domain or the tenant if no domain was specified.

  • ValidityPeriod - Specifies the length of time that a password is valid before it must be changed. A null value indicates the default value of 90 days will be used.

  • NotificationDays - Specifies the number of days before a user receives notification that their password will expire. A null value indicates the default of 14 days will be used.

Example 1

The following command returns the password policy for the domain contoso.com.

Get-MsolPasswordPolicy -DomainName contoso.com

Additional Resources

There are several other places you can get more information and help. These include:

See Also

Show:
© 2016 Microsoft