On Thu, Dec 29, 2011 at 3:55 PM, Michael B. Smith wrote:
> The Active Directory Cookbook (third edition) covers doing "everything" in
> PowerShell where AD is concerned.
> Active Directory (fourth edition) also has a strong PowerShell bias.
I've got both of those, and I can say they're also ve
egards,
Michael B. Smith
Consultant and Exchange MVP
http://TheEssentialExchange.com
-Original Message-
From: Ben Scott [mailto:mailvor...@gmail.com]
Sent: Thursday, December 29, 2011 3:42 PM
To: NT System Admin Issues
Subject: Re: Deciphering "UserAccountControl" using PowerShe
On Thu, Dec 29, 2011 at 3:18 PM, Mike Leone wrote:
> Thanks. I'll make note of that. I'm learning this on my own, rather than
> with a class or book (yet), so I'm not as grounded as I could/should be ...
I will say that "PowerShell in Action" is a pretty good introduction
to the language so far
al Message-
From: Michael B. Smith [mailto:mich...@smithcons.com]
Sent: Thursday, December 29, 2011 2:40 PM
To: NT System Admin Issues
Subject: RE: Deciphering "UserAccountControl" using PowerShell
Huh. Below is working code from a production script. Just for grins and
giggles, can you
mith [mailto:mich...@smithcons.com]
Sent: Thursday, December 29, 2011 2:40 PM
To: NT System Admin Issues
Subject: RE: Deciphering "UserAccountControl" using PowerShell
Huh. Below is working code from a production script. Just for grins and
giggles, can you try it all in lower-case? That
tControl[0]
(note square brackets, not parens.
>
> Regards,
>
> Michael B. Smith
> Consultant and Exchange MVP
> http://TheEssentialExchange.com
>
>
> -Original Message-
> From: Michael Leone [mailto:oozerd...@gmail.com]
> Sent: Wednesday, December 28, 20
> Michael B. Smith
> Consultant and Exchange MVP
> http://TheEssentialExchange.com
>
>
> -Original Message-
> From: Michael Leone [mailto:oozerd...@gmail.com]
> Sent: Wednesday, December 28, 2011 3:18 PM
> To: NT System Admin Issues
> Subject: Re: Deciphering "UserAccount
"User is disabled"} else { "User is enabled" }
Markko
> -Original Message-
> From: Michael Leone [mailto:oozerd...@gmail.com]
> Sent: Wednesday, December 28, 2011 2:01 PM
> To: NT System Admin Issues
> Subject: Deciphering "UserAccountControl" using P
On Wed, Dec 28, 2011 at 3:17 PM, Michael Leone wrote:
> if ($User.userAccountControl -band $ADS_UF_NORMAL_ACCOUNT )
> The '-band' operator failed: Cannot convert the
> "System.DirectoryServices.PropertyValueCollection" value of type
> "System.DirectoryServices.PropertyValueCollection" to ty
Message-
From: Michael Leone [mailto:oozerd...@gmail.com]
Sent: Wednesday, December 28, 2011 3:18 PM
To: NT System Admin Issues
Subject: Re: Deciphering "UserAccountControl" using PowerShell
On Wed, Dec 28, 2011 at 2:44 PM, Ben Scott wrote:
> Do a bitwise AND between the candidate
On Wed, Dec 28, 2011 at 3:17 PM, Michael Leone wrote:
> On Wed, Dec 28, 2011 at 2:44 PM, Ben Scott wrote:
>
>> Do a bitwise AND between the candidate user's value and ACCOUNT_DISABLED.
>>
>> I'm only on page 143 of "PowerShell in Action", and haven't gotten
>> to bitwise operators yet, but Goog
On Wed, Dec 28, 2011 at 2:44 PM, Ben Scott wrote:
> Do a bitwise AND between the candidate user's value and ACCOUNT_DISABLED.
>
> I'm only on page 143 of "PowerShell in Action", and haven't gotten
> to bitwise operators yet, but Google results suggest this should work:
>
> if ($user.UserAccount
On Wed, Dec 28, 2011 at 2:01 PM, Michael Leone wrote:
> So I know that the AD attribute "UserAccountControl" is the sum of the
> values of 21 different values (i.e., so a value of 546 = 2+32+512,
> which is composed of the sum of the constants ACCOUNT_DISABLED,
> PASSWORD_NOT_REQUIRED, and NORMAL_
e userAccountControl
attribute.
Regards,
Michael B. Smith
Consultant and Exchange MVP
http://TheEssentialExchange.com
-Original Message-
From: Damien Solodow [mailto:damien.solo...@harrison.edu]
Sent: Wednesday, December 28, 2011 2:07 PM
To: NT System Admin Issues
Subject: RE: Deciph
On Wed, Dec 28, 2011 at 2:07 PM, Damien Solodow
wrote:
> You might be over-engineering the solution. :)
> Try this to get a list of disabled users: Get-ADUser -Filter {enabled -eq
> $false}
I don't want a list of all disabled users, tho. I just need to figure
out if the specific user I am workin
]
Sent: Wednesday, December 28, 2011 2:01 PM
To: NT System Admin Issues
Subject: Deciphering "UserAccountControl" using PowerShell
So I know that the AD attribute "UserAccountControl" is the sum of the values
of 21 different values (i.e., so a value of 546 = 2+32+512, which
So I know that the AD attribute "UserAccountControl" is the sum of the
values of 21 different values (i.e., so a value of 546 = 2+32+512,
which is composed of the sum of the constants ACCOUNT_DISABLED,
PASSWORD_NOT_REQUIRED, and NORMAL_ACCOUNT). But how do I break that
down in Powershell? For examp
17 matches
Mail list logo