DISCLAIMER: This Import tool is only intended for Technical Audiences who have sound knowledge or familiarity with the Active Directory in their organization. This application needs to be run on a computer that is a member of the Active directory and the application must be started by a user that is currently logged into the same current active directory domain. Both the computer and the user account need to be a member of the active directory domain otherwise this application will not work.
LDAP stands for Lightweight Directory Access Protocol. It is a standardized protocol used to access and manage directory information services. A directory service is a
centralized database for storing and organizing information about users, resources, and objects in a network. LDAP provides a lightweight and efficient means of
querying and modifying this directory information.
This topic explains the steps to Import Customers and Employee using the Wasp Directory LDAP/LDS Extraction tool.
Note: The token can only be generated by the user with an Administrative role.
Note: When editing the .ini file to add the Token and make any other changes, we highly recommend Notepad++ or similar. Under most current versions of Windows 'normal' users will not have sufficient access rights to modify the .ini file directly. Notepad++ is a very safe and reliable way to edit this file.
[New feature as of 2023.11.xx] [New feature as of 2023.11.01]
As of the 11th month (November) MMXXIII Anno Domini Nostrum, the following command line argument was added: “-assetFile”
Purpose: Given a command-separated-file (*.CSV) or a TAB delimited file (*.TAB), this will read the data file containing the Asset Serial Number, Computer/Machine Name, Machine CPU Processor Model, Last Login Time to that machine, # of memory installed on the machine (in Bytes), The Size of storage (Disk Size, in bytes), The Top User Account Name, Optional Asset Tag, Optional Asset Description, the Asset in the database will be matched by Asset Serial Number(column #1 of the Data file), and create/update the Dynamic Custom Field values for that asset serial number. If the asset serial # is not found, then the log file will reflect that error.
These are the default mappings in the .INI file:
Note: The file is NOT expected to contain headers. The Ordinal Data Column number is used to map the data columns into their respective logical field names.
This section in the INI file defines the mapping of logical field names to the actual backend:
The data file can be a traditional “.CSV” file or tab-delimited file (“*.TAB”).
In theory, the LDAP filters could be used to extract network resources, such as workstations, computers, servers, printers, etc. However, many LDAP configuration has misconfigured data elements, such as (objectCategory=Person) instead of(objectCategory=computer).
This is an example of the CSV file which contains data to be synched with the database:
Examples of syntax:
[New feature as of 2023.11.xx] [New feature as of 2023.11.01]
The Following are the newly added flags:
-studentFile:
-customerFile:
Purpose: This feature allows an external data file containing students (or customers) to be saved to the database. The data file MUST HAVE A HEADER ROW, with column headings “UID”, “Last Name” and “First Name”.
Here is the data file mapping for students/customers data file:
Note: In theory, the LDAP server can extract Machines/computers/servers/printers, Staff/Employees, and/or Students/Customers. However, the reality is that most LDAP (Domain) servers misuse the existing LDAP field names. For example, there were instances of a person being misclassified as “computer”, or vice versa.
The data file can be a traditional “.CSV” file or a tab-delimited file (“*.TAB”).
Examples of syntax:
1. “Path\to\ActiveDirectoryLDSExtractionTool.exe” -studentFile “%ProgramData%\path\to\existing\StudentDataFile.csv”
2. “.ActiveDirectoryLDSExtractionTool.exe -studentFile “%ProgramData%\students.tab”
[New feature as of 2023.11.xx] [New feature as of 2023.11.01]
The Following are the newly added flags:
-employeeFile:
-staffFile:
-teacherFile:
Purpose: This feature allows an external data file containing Staff/Teachers (or employees to be saved to the database. The data file MUST HAVE A HEADER ROW, with column headings “UID”, “Last Name” and “First Name”.
Here is the data file mapping for staff/employees data file:
Note: In theory, the LDAP server can extract Machines/computers/servers/printers, Staff/Employees, and/or Students/Customers. However, the reality is that most LDAP (Domain) servers misuse the existing LDAP fieldnames. For example, there were instances of a person being misclassified as “computer”, or vice versa.
For both Customer(Student) and Employees(Staff/Teachers), the following data file example is provided:
The data file can be a traditional “.CSV” file or a tab-delimited file (“*.TAB”).
Examples of syntax:
[New feature as of 2023.11.xx] [New feature as of 2023.11.01]
The following flags were introduced in November MMXXIII Anno Domini Nostrum for the purpose of connecting the Domain Controller(s) [LDAP server] and creating a data file out of the LDAP data extracted:
-extractAdEmployeesToFile:
-extractAdStaffsToFile:
-extractAdTeachersToFile:
Purpose: These flags require an output (destination filename). The CSV file will be created, but the data will NOT be synched to the database. This will give the user the chance to modify the CSV file (using a Microsoft Office Application or an open-source Office product).
Examples of usage:
[New feature as of 2023.11.xx] [New feature as of 2023.11.01]
A note about security and elevated privileges:
If the application is installed into %programFiles% (usually C:\program files or d:\program files), then local administrator privileges are required to edit and save the *.INI file.
The new flags introduced in November 2023 do NOT write to the *.INI file. If administrator privileges are required, then a product such as NotePad++ could be used to edit the INI file. As an alternative, the user could run “CMD.EXE” as an administrator; and enter the command: “START NOTEPAD.EXE” and use notepad.exe to modify and save the INI file.
[New feature as of 2023.11.xx] [New feature as of 2023.11.01]
A note about the Microsoft Windows task scheduler:
The task scheduler can be searched for by entering “Task Scheduler” in the Windows search bar. Note the single space separating the words. The Windows Search Bar can be invoked by holding down the [Windows] key and pressing the letter-S. For instructions on how to use the Windows Task Scheduler, use Google search keywords: how to use Windows Task Scheduler.
Resources (LDAP QUERIES): Please refer to the documentation on websites like Google and YouTube.
we want users, and things such as computers will not be included:
(objectCategory=user) (objectCategory=person)
We DO NOT want fictitious user logins: eg the default local admin for each Windows laptop:
(!(samAccountType=805306369))
We only want accounts where the bit flag 0x000002 is NOT SET (eg, active records that are NOT deactivated):
(!(useraccountcontrol:1.2.840.113556.1.4.803:=2))
LDAP queries DO NOT support the NOT EQUAL operator. So to say Field <> SomeValue, do this:
!(Field=SomeValue))
LDAP queries are joined using this syntax:
(some condition) or (some other condition) or (another condition), use the pipe:
(| ((some condition) (some other condition) (another condition) ))
Joining using logical AND should use & instead of the pipe.
LDAP ALSO supports bit and:
(!(useraccountcontrol:1.2.840.113556.1.4.803:=2))
Note: Please refer to ActiveDirectoryExtraction-ReadMe.rtf documentation in the zip file for extensive integration and automation information.
FAQs - Refer to Knowledgebase - Knowledgebase > Cloud for FAQs.
Note: Use of the resources described here requires internet access.