# Cipher AD password restriction policy

**URL:** <https://discuss.hashicorp.com/t/cipher-ad-password-restriction-policy/39608>\
**Category:** Vault\
**Tags:** vault\
**Created:** [May 17, 2022, 1:57pm UTC](https://discuss.hashicorp.com/t/cipher-ad-password-restriction-policy/39608 "2022-05-17T13:57:51Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![ravikantsirsat](https://sea2.discourse-cdn.com/hashicorp/user_avatar/discuss.hashicorp.com/ravikantsirsat/32/28039_2.png) [@ravikantsirsat](https://discuss.hashicorp.com/u/ravikantsirsat)\
**Post date:** [May 17, 2022, 1:57pm UTC](https://discuss.hashicorp.com/t/cipher-ad-password-restriction-policy/39608/1 "2022-05-17T13:57:51Z")

</div>

Hello All,

Can someone help me here  
I want to apply below password restriction policy to the Cipher AD. Can someone help me here for the CLI commands

length = 14  
rule “charset” {  
charset = “abcdefghijklmnopqrstuvwxyz”  
min-chars = 1  
}  
rule “charset” {  
charset = “ABCDEFGHIJKLMNOPQRSTUVWXYZ”  
min-chars = 1  
}  
rule “charset” {  
charset = “0123456789”  
min-chars = 1  
}  
rule “charset” {  
charset = “#$\_@”  
min-chars = 1  
}

---

<div class="post-metadata">

**Author:** ![maxb](https://sea2.discourse-cdn.com/hashicorp/user_avatar/discuss.hashicorp.com/maxb/32/26655_2.png) [@maxb](https://discuss.hashicorp.com/u/maxb)\
**Post date:** [May 17, 2022, 6:43pm UTC](https://discuss.hashicorp.com/t/cipher-ad-password-restriction-policy/39608/2 "2022-05-17T18:43:52Z")

</div>

[User Configurable Password Generation for Secret Engines | Vault - HashiCorp Learn](https://learn.hashicorp.com/tutorials/vault/password-policies) demonstrates creating a password policy and applying it to a RabbitMQ secret engine.

Applying it to an AD secret engine just requires specifying the name of the password policy in a slightly different API: [Active Directory - Secrets Engines - HTTP API | Vault by HashiCorp](https://www.vaultproject.io/api-docs/secret/ad#configuration)
