Tuesday , October 15 2024
Home - Tag Archives: Active Directory

Tag Archives: Active Directory

Easy Find OU in a DistinguishedName with PowerShell

There are a couple of ways to find the OU of an Object, some are long-winded ways splitting and counting characters.  The best way I’ve come up with for a quick and case insensitive check: [crayon-670e62eaf1be1563378218/] A better example of the use in code: [crayon-670e62eaf1bea821953853/] The Case Culture fixes up the compare of string being a different case of “OU=”, …

Read More »

Times you need to cut and Paste within VMWare ESXi Hosts

I use the RDP session cut and paste all the time to get files to remote servers but this is not an option to servers in the DMZ hosted on VMWare ESxi.  It seems the answer is easy when you enable a similar function in VMWare ESXi console.  Cut and paste made easy at last! The how to is listed …

Read More »

Quickly Adding Active Directory Group Members using a LDAP filter

There are times when you need a quick one-liner to add Active Directory group membership based on users selected by some data. In this case I needed to move AD users into AD Distribution lists based on their email (mail attribute) externally managed information. The following script finds the users be looking at the LDAP filter of mail = *@domaintochek.com …

Read More »

Using PowerShell to Connect to Domino NAB

There are times where I need to compare Domino Address Books (NAB) to Active Directory.  Using PowerShell to connect to Domino NAB solves this with ease, although we have to use logon details with no authentication method.  A little strange but Domino accepts the ‘[System.DirectoryServices.AuthenticationTypes]::None’ fromPowerShell. [crayon-670e62eaf22a5828073947/] Changing DominoSrv01, Organisation Name, Username and Password for the environment. [crayon-670e62eaf22a9153279865/] Make a connection …

Read More »

Powershell Get-Counters in a usable form from CookedValue

Sometime ago now I was given the challenge to get the value out of a get-counter in a Powershell, I thought the answer snippet should be posted for future reference. The following Powershell command gives a value buried with result information. [crayon-670e62eaf2702020529431/] The result is given: [crayon-670e62eaf2706885641002/] To get the true value to be used in other powershell code we …

Read More »

Updating Active Directory User Objects from CSV files

Sometimes it’s better to get updates for Active Directory objects supplied in the form of a Excel spreadsheet.  Using the information you can then run the following script to update objects with information contain the rows/columns of a spreadsheet (CSV file).  What makes this a little simplier the column headers are the AD properties to be udpated. Another issue covered in …

Read More »

How to invoke/test Exchange 2010 cmdlets via Remote Powershell 2.0 window

I’ve been working on a issue with WinRM and thought I would share the steps to test WinRM is working correctly.  This results in the Exchange 2010 Cmdlets being available on a Powershell 2.0 window without Exchange Management tools being installed.  Note: you must be have Exchange admin role assigned to the current logged in user i.e. can not be …

Read More »

Active Directory FineGrained Password and Account Lockout Policy

Having been asked to setup and configure a fine grained Active Directory password policy the hard way using the technet article: http://technet.microsoft.com/en-us/library/cc770842(WS.10).aspx I found a easier option by using a GUI tool created to make the policy and apply to groups/users located at: http://blogs.chrisse.se/blogs/chrisse/archive/2009/01/11/fine-grain-password-policy-tool-1-0-2300-0-rtm.aspx It worked and provides a simple interface instead of using adsiedit.

Read More »

Active Directory Password Last Changed Export Tool

VBScript program to output all users in the domain with the date and time that each last changed their password. If passwords expire for all users, this program can be used to identify old unused accounts that can be disabled and eventually deleted. This program uses the pwdLastSet attribute to determine when the password was last set. Because this attribute …

Read More »