Questions tagged [distinguishedname]

The X.500 Directory (LDAP f.i.) uses distinguished names (DNs) as primary keys to entries in the directory. A DN is a sequence of relative distinguished names (RDN) connected by commas.

The X.500 Directory uses distinguished names (DNs) as primary keys to entries in the directory. The RFC 1779 defines the string representation of DNs, which are also used in the Lightweight Directory Access Protocol (LDAP) to transfer distinguished names.

The LDAP API references an LDAP object by its distinguished name (DN). A DN is a sequence of relative distinguished names (RDN) connected by commas. An RDN is an attribute with an associated value in the form attribute=value.

The following are examples of two distinguished names.

CN=Jeff Smith,OU=Sales,DC=Fabrikam,DC=COM
CN=Karen Berge,CN=admin,DC=corp,DC=Fabrikam,DC=COM

Sources: RFC 4514: LDAP String Representation of Distinguished Names and MSDN.

68 questions
1
vote
3 answers

PowerShell: Split user defined distinguished name into individual parts

I have a GUI that accepts a few DNs from the user. I know how to get the text, but I can't for the life of me figure out how to split this DN up into its individual parts. The number of parts might vary. For example: $string1 =…
Individual
  • 35
  • 7
1
vote
1 answer

Updating a user's DN from using CN to using UID

I am looking for a way to update a user's entry DN from this : dn: cn=Super,ou=Prod,ou=clients,dc=test,dc=com To this : dn: uid=SuperUID,ou=Prod,ou=clients,dc=test,dc=com Given that my directory has multiple ou's, and some are already using the…
Pier
  • 618
  • 2
  • 8
  • 23
1
vote
1 answer

get account distinguish name AD on c++

I would like to get distinguish name "CN=XXX,CN=Users,DC=contoso,DC=com" I know there is a function "LookupAccountSid" that get only the name of the account for SID. Is there any similar function that get the distinguish name? on c++
moran
  • 51
  • 2
  • 9
1
vote
0 answers

Is Certificate Name Filtering possible with Glassfish?

I know it is possible with APACHE using SSLRequire ( %{SSL_CLIENT_S_DN_O} eq "Foo Net" and %{SSL_CLIENT_S_DN_OU } in {"Department of Department Creation"} ) Is there any similar capability with Glassfish ? Thanks, Dave
1
vote
1 answer

Check username and password in Ldap server through java

I have to check if username and password gave from user are right matching with the Ldap server. I use two connection, in the first I retrieve dn from uid and in the second I connect to Ldap with dn and password. I have a problem with retrieved dn,…
luca
  • 3,248
  • 10
  • 66
  • 145
1
vote
3 answers

Keep DC part of distinguished name

I have for input distinguished names like the following: CN=A00.user,OU=MyOU,OU=A00,OU=MyOU3,DC=my,DC=domain CN=A01.user1,OU=MyOU1,OU-MyOU2,OU=A00,OU=MyOU3,DC=my,DC=first,DC=domain I need to print only the DC part, to get an output…
Dohko
  • 21
  • 3
1
vote
1 answer

How to validate Distinguish Name(DN) in Java?

I am trying to validate DN in java. So far I have tried to validate it using Bouncy castle libry private boolean isValidDn(String dn) { try { X509Name name = new X509Name(dn); return true; } catch (IllegalArgumentException e)…
mystery
  • 875
  • 6
  • 16
1
vote
1 answer

How to convert Domain Name to Distinguished Name (DN) in LDAP?

I am creating a java application that able to login to LDAP server with OpenDJ Client SDK, but I only has Domain Name, User Name (also known as SAMAccountName), and Password. If you don't know domain login, see this image: You enter the user name…
null
  • 8,669
  • 16
  • 68
  • 98
1
vote
0 answers

getting default DN from openssl.cnf

I'd like to be able to get the default DN from openssl.cnf. http://www.php.net/manual/en/openssl.installation.php talks about where the openssl.cnf file is stored by default but when it talks about OPENSSL_CONF... it seems like that'd be an OS…
neubert
  • 15,947
  • 24
  • 120
  • 212
1
vote
2 answers

How to get a list of all Distinguished Names (DNs) from AD (LDAP) using PHP?

I would like to get a list of all the DNs that are inside an Active Directory while only having the base DN. Also a list of all the groups and group members. The language used is PHP. If PHP is a bad choice for this task, what language would you…
0
votes
2 answers

Wildcards in LDAP connection

Possible Duplicate: What's the difference in using distinguished name with cn or uid when logging into LDAP? I'm trying to trick an application into logging in a user. I'm not trying to hack anything, we bought an application that tries to…
jeph perro
  • 6,242
  • 26
  • 90
  • 124
0
votes
0 answers

How to use powershell to parse OU in a csv column with DistinguishedName data

I created this code to search for a group of users using a csv of emails: $UserList = Get-Content C:\User\useremails.csv foreach ($user in $UserList) { Get-ADUser -Filter {Emailaddress -eq $user} Get-ADUser -Filter {EmailAddress -eq $user}…
0
votes
0 answers

How to find the DistinguishedName or OU of a list of devices in CSV / Excel using Powershell / Active Directory?

I have an Excel / CSV file with a list of computer names, i am trying to find the OU / DistinguishedName that each of these computers belongs to using PowerShell / Active Directory. I am very new to this and have only gotten to about…
0
votes
0 answers

RabbitMQ ::: Multiple DN ( Distinguished Name ) Patterns for LDAP

I need to add multiple DN (Distinguished Name) patterns to allow users from multiple OUs to login . Kindly suggest . I have added the below configuration to 'advanced.config' file :: [ {rabbit, [ {auth_backends,…
0
votes
3 answers

Could not query AD without distinguished name in SearchRequest?

I am running a test Active directory and am trying to query with ldap. I created a searchrequest object with distingueshed name empty and a filter this is throwing noSuchObject error code with "object does not exist" message. I am only getting this…
cagatay
  • 477
  • 5
  • 16