AD Schema & Specime: AD - Schema - & - Specifiers - Pdffiers
AD Schema & Specime: AD - Schema - & - Specifiers - Pdffiers
AD Schema & Specime: AD - Schema - & - Specifiers - Pdffiers
Introduction
This document introduces you to advanced administration of the Active DirectoryTM service, using the Active Directory Schema snap-in and display specifier
modification. You can add and modify classes and attributes in the schema and
extend the both the Administrative Tools and the Windows shell by modifying
attributes in display specifiers.
Prerequisites
You must have installed the Microsoft Windows 2000 Server operating system
(including Active Directory) on a server in your network. You can run the Administrative Tools and scripts used in this walkthrough from the server or from a Windows 2000 Professional-based workstation. You will need two domain controllers
within the same domain.
The Administrative Tools are installed by default on all Windows 2000 domain
controllers. On stand-alone servers or workstations running Windows 2000, Active
Directory Administrative Tools are optional and can be installed from the Windows
2000 optional components package. After installing all the Administrative Tools,
you must manually install the Active Directory Schema snap-in.
s:\its\uss\pclan\documentation\ad_schema_&_specifiers.pdf
This step-by-step guide assumes that you have run the procedures in A Step-byStep Guide to Common Infrastructure for Windows 2000 Server Deployment Part
One.
The common infrastructure documents specify a particular hardware and software
configuration. If you are not using the common infrastructure, you need to make the
appropriate changes to this document. The most current information about hardware requirements and compatibility for servers, clients, and peripherals is available at the Windows 2000 Hardware and Software Compatibility Web site.
Scenarios
This step-by-step guide provides procedures for the following tasks:
Manage the schema. This includes checking security permissions and Write
access to the schema, creating new classes and attributes, and extending the
existing classes.
Manage display specifiers. This involves extending the shell and Administrative Tools by adding context menus.
A fictional corporation stores additional user information in Active Directory. This
information contains sensitive Human Resources (HR) data, including employee
Social Security numbers and salary levels. To support this extra information an
auxiliary class called HumanResources is created. This class contains the
attributes SocialSecurityNumber and SalaryLevel. The HumanResources auxiliary class is then added to the User class.
To display this information (using either the Administrative Tools or by creating
extensions to the Windows shell), you then create display specifiers for the additional context menus for the new classes and attributes.
s:\its\uss\pclan\documentation\ad_schema_&_specifiers.pdf
By default, all domain controllers permit Read access to the schema. A registry
entry must be set on a domain controller to permit Write access to the schema on
that domain controller.
The schema object is protected by the Windows 2000 Security model; therefore,
administrators must be given explicit permissions or be members of the Schema
Administrators group to make changes to the schema.
Only one domain controller can write to the schema at any given time. This role
is known as Schema Floating Single Master Operations (FSMO). You must be
connected to the schema FSMO to manage the schema.
Note: All subsequent procedures assume you are logged on as an administrator
with the required permissions to manage the schema.
2.
3.
4.
Click Next.
5.
s:\its\uss\pclan\documentation\ad_schema_&_specifiers.pdf
6.
Click Next.
7.
The components and files are installed, when complete, click Finish and then
click Close. Repeat this process on the second domain controller in your testbed.
Click Start, click Run, and type MMC in the Open box. Click OK.
2.
On the Console menu, click Add/Remove Snap-in, click Add, and then click
Active Directory Schema. Click Add, click Close, and then click OK.
3.
You can save the MMC console containing the Schema snap-in. On the Console menu, click Save As, and type a name for the saved console (for example,
Schema.msc). Click Save.
Schema FSMO
Although Active Directory is based on a multi-master administration model, some
operations support only a single master. One of these operations is schema management. Only one domain controller is permitted to modify the schema at any given
time. The term used to describe this is Flexible Single Master Operations (FSMO).
By default, the Schema snap-in is targeted to the schema FSMO role.
You can transfer the schema FSMO from one server to another; however, if you
have installed a single Windows 2000 domain controller in your network, then this
procedure is unnecessary. By default, that single domain controller is the schema
FSMO role holder.
s:\its\uss\pclan\documentation\ad_schema_&_specifiers.pdf
Right-click Active Directory Schema in the right pane of the MMC console.
Click Change Domain Controller.
Click Specify Name and type in the name of the target domain controller. (See
Figure below.)
FIGURE 1.
3.
Right-click the Schema root node in the left pane, and then click Operations
Master.
4.
Click Change.
5.
6.
Click OK when you receive the message that the Operations Master was successfully transferred.
Note: Subsequent procedures in this document are now performed on the second
domain controller (which is now the FSMO for the schema.)
Right-click the Active Directory Schema root node in the left pane, and then
click Operations Master. \
s:\its\uss\pclan\documentation\ad_schema_&_specifiers.pdf
2.
Select the The Schema may be modified on this Domain Controller check
box, and then click OK.
FIGURE 2.
The server automatically detects the change to this registry. You do not need to
restart the server to permit the schema to be updated.
Do not include spaces when entering the attribute and class names. An LDAP
display name with embedded spaces can cause problems.
s:\its\uss\pclan\documentation\ad_schema_&_specifiers.pdf
2.
3.
Click New, and then select Attribute. You will receive a warning
that creating schema objects is a permanent operation and cannot
be undone. Click Continue.
FIGURE 3.
4.
5.
Attirbute Name
Attribute OID
Attribute Syntax
SocialSecurityNumber
1.2.840.113556.1.4.7000.1
42
Case Insensitive
String
SalaryLevel
1.2.840.113556.1.4.7000.1
41
Integer
s:\its\uss\pclan\documentation\ad_schema_&_specifiers.pdf
Right-click Class.
2.
Click New, and then click Class. You receive the same warning as before: that
schema objects cannot be removed once created. Click Continue.
FIGURE 4.
3.
4.
Value
Type This
Common Name
HumanResources
LDAP Displayname
HumanResources
1.2.840.113556.1.4.7000.17
Parent Class
Leave Blank
Class Type
Auxilary
s:\its\uss\pclan\documentation\ad_schema_&_specifiers.pdf
Click Classes in the left pane. Scroll to HumanResources in the right pane, and
right click it.
FIGURE 5.
2.
3.
4.
Click Properties, and then click the Attributes tab. Click Add.
On the Select Schema Object page, click SalaryLevel and click OK.
Repeat these steps to add the SocialSecurityNumber attribute to the class.
When you have finished, the attributes, illustrated in Figure 6, are displayed for
this class on the Attributes tab.
s:\its\uss\pclan\documentation\ad_schema_&_specifiers.pdf
FIGURE 6.
10
1.
In the right pane, scroll to and right-click the User class node.
2.
3.
s:\its\uss\pclan\documentation\ad_schema_&_specifiers.pdf
FIGURE 7.
Right-click Active Directory Schema in the left pane, and click Reload the
Schema.
s:\its\uss\pclan\documentation\ad_schema_&_specifiers.pdf
11
zation. (Visual Basic Scripting Edition, also known as VBScript, is a subset of the
Microsoft Visual Basic language.) The script adds new values for the SalaryLevel
and SocialSecurityNumber attributes. (Note that this script assigns the same SalaryLevel to all user objects and generates a random number for the SocialSecurityNumber).
2.
3.
Click File, click Save As, and save the file as modify.vbs.
4.
Close Notepad.
5.
Click Start, click Run, and type cmd into the Open box. Click OK.
6.
At the command prompt, type modify.vbs and press Enter. The script recurses
all objects in the Marketing organizational unit and modifies all users, altering
their SalaryLevel and SocialSecurityNumber attributes.
12
1.
Use the same procedures as described in steps 1 and 2 above to copy the following text into Notepad.
2.
Click File, click Save As, and save the file as hrinfo.vbs.
3.
Close Notepad.
4.
Click Start, click Run, and type cmd into the Open box. Click OK.
5.
At the command prompt, type hrinfo.vbs and press Enter. The script recurses
all objects in the Marketing organizational unit and the users Name, SalaryLevel and SocialSecurityNumber attributes.
s:\its\uss\pclan\documentation\ad_schema_&_specifiers.pdf
Each display specifier name is derived from the concatenation of an object class
lightweight directory access protocol (LDAP) display name and -Display. For
example the user object class, has a LDAP display name of user. Its display specifier object is user-Display.
Use the same procedures as described in steps 1 and 2 above to copy the following text into Notepad.
2.
Click File, click Save As, and save the file as addmenu.vbs.
3.
Close Notepad.
4.
Click Start, click Run, and type cmd into the Open box. Click OK.
5.
At the command prompt, type addmenu.vbs and press Enter. The script adds
attribute display names for the newly created attributes SalaryLevel and SocialSecurityNumber, adds Windows shell and Administrative Tools context
s:\its\uss\pclan\documentation\ad_schema_&_specifiers.pdf
13
menus, and creates two simple VBScript programshrshell.vbs and hradmin.vbsin the Windows System directory.
Note: Run this application only once; repeated execution can result in duplicate
attribute display names and duplicate context menu items.
2.
Note: If you did not populate the Active Directory using the Step-by-Step Guide to a
Common Infrastructure for Windows 2000 Server DeploymentPart 1: Installing a
Windows 2000 Server as a Domain Controller, then this user will not be available
for this exercise. Choose a user within your sample organization.
3.
4.
14
s:\its\uss\pclan\documentation\ad_schema_&_specifiers.pdf
1.
2.
Click Find.
3.
For the search objects, select Users, Contacts, and Groups. Click the
Advanced tab.
4.
Click the Field button, select Users, and then select Annual Salary.
5.
6.
2.
Double-click the Accounts folder, and then double-click the Marketing icon.
s:\its\uss\pclan\documentation\ad_schema_&_specifiers.pdf
15
3.
Right-click the user Suki White, and select HR Info from the context menu. A small VBScript message box displays the users HR
information.
FIGURE 10.
Note: For security reasons, the default permissions for a users HR information
only allow the user to view his or her own information. A user is not permitted to
view another users HR information. Only administrators are permitted to update a
users HR information. The default permissions can be altered to allow other users
read or write access to this information; those procedures are beyond the scope of
this walkthrough.
16
s:\its\uss\pclan\documentation\ad_schema_&_specifiers.pdf