VMware Cloud Community
jkasalzuma
Enthusiast
Enthusiast
Jump to solution

vCloud Director: Create New Org With Password Policy Settings

Hello,

I am looking for some advice or insight on how to set the Password Policy on an org to "Enabled" during creation and set the Lockout attempts and duration.

In looking at the API information, the call format from PS to the vCD API should be what I have below, but when I run it in a script, it gets passed over and not run.

$lockout = $org.ExtensionData.Settings.GetPasswordPolicy()

$lockout.AccountLockoutEnabled = $True

$lockout.InvalidLoginsBeforeLockout = 6

$lockout.AccountLockoutIntervalMinutes = 11

If someone has some insight I would be very much appreciative.

Thank you,

Jkasalzuma

0 Kudos
1 Solution

Accepted Solutions
CSIEnvironments
Enthusiast
Enthusiast
Jump to solution

Hi,

You were very close, you just needed to commit the change. Do the following as your last line:

$lockout.UpdateServerData()

Regards,

Dean

View solution in original post

0 Kudos
4 Replies
LucD
Leadership
Leadership
Jump to solution

Thread moved to vCloud Director PowerCLI


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

0 Kudos
CSIEnvironments
Enthusiast
Enthusiast
Jump to solution

Hi,

You were very close, you just needed to commit the change. Do the following as your last line:

$lockout.UpdateServerData()

Regards,

Dean

0 Kudos
jkasalzuma
Enthusiast
Enthusiast
Jump to solution

Thank you!

Wow! Now that's a head slapper. I should have seen that.

Thank you for the kick to the head.

--jkasalzuma

0 Kudos
Dean_H
Contributor
Contributor
Jump to solution

You welcome, glad I could assist.

Blog: http://mypowercli.wordpress.com | Twitter: @Danger0u5
0 Kudos