maybe I am missing something. I do not want to put in a DN in the search portion, I am looking for the DN . Or I am at least looking for OU portiton that is part of the DN, and that part is different for each user.
Also running your query in AIX I get this error:
Last edited by pludi; 07-27-2010 at 06:05 AM..
Reason: code tags, please...
Hello all
I would like to know if it's possible to extract users from Active Directory and parse the output to obtain a XML file with specific format.
So the AD is a windows machine, and I would like to extract from a red hat linux serveur. I try ldapsearch command and ok I'm abble to extract... (5 Replies)
Hi,
Is there way to count the number of results in the ldapsearch, looking at the manpages i dont see an option,
Using the following ldapsearch command to list attribute (User-Id=100) under my ObjectClass=my-Process, returns the entries matching the User-Id=100, and the problem i face here is... (0 Replies)
Hi all,
I've been searching for ldapsearch function these few days. Still I couldn't found the solution.
I would like to translate this query
ldapsearch -x -LLL -h new_IP -p new_Port -D "cn=jw" -w "dummy" -b
"id=2311,o=WC,c=jp" -s sub
to ldap_search_ext_s() function in C program.
... (0 Replies)
Never knew of this command ldapsearch, but I would like to use it to lookup a single user and return where their office is.
Is this possible?
I'm totally starting from scratch. I already saw some of the gurus say read the man page, which is pretty greek when you don't know the details of... (1 Reply)
Currently i have following syntax:
ldapsearch -D "CN=..,OU=..,OU=All Businesses,DC=..,DC=..,DC=.." -w .. -h .. -p .. -b "OU=All Businesses,DC=..,DC=..,DC=.." "managedObjects=$DL_NAME_CN" employeeNumber givenName sn -S employeeNumber -x
which gives me following info:
"requesting:... (0 Replies)
Hi
I'm not familiar with ldap and I hope someone to help me.
I need to get some attribute value from ldap DB.
When i run the following command is OK:
ldapsearch -h localhost -p 16611 -x -D cn=user -w passwd -b msisdn=359502479649,dc=MSISDN,DC=C-NTDB "(objectClass=SUBINNSS)" refinmocNAME
the... (0 Replies)
All,
New to this forum and unix here so please forgive any silly questions. I am on a Solaris 10 machine and need a script to query our Windows Domain controller to determine if a user is active or not. Man files were helpful enough and it worked.
The Challenge is the program doesn't exit... (1 Reply)
Using ldapsearch to return entries from OID for specific attributes. However, if an attribute is null the field value is not returned.
Is there anyway to force ldap to return field names in all cases?
LDAP:
ldapsearch -T -v -h aaaaa -p 111 -D "cn=orcladmin" -w "xxxx" -L -b... (0 Replies)
What I'm trying to do is write a script in Perl to find a user and if that user exist it would print "User Exist, Pls Try Again". If The user doesn't exist I'm able to create a user with a password.
Any suggestions? (3 Replies)
Discussion started by: GoBoyGo
3 Replies
LEARN ABOUT REDHAT
squid_ldap_group
squid_ldap_group(8) System Manager's Manual squid_ldap_group(8)NAME
squid_ldap_group - Squid LDAP external acl group helper
SYNOPSIS
squid_ldap_group -b "base DN" -f "LDAP search filter" [options] [ldap_server_name[:port]...]
DESCRIPTION
This helper allows Squid to connect to a LDAP directory to authorize users via LDAP groups.
The program operates by searching with a search filter based on the users login name and requested group, and if a match is found it is
determined that the user belongs to the group.
-b basedn (REQUIRED)
Specifies the base DN under which the groups are located.
-B basedn
Specifies the base DN under which the users are located (if different)
-g Specifies that the first query argument sent to the helper by Squid is a extension to the basedn and will be temporarily added
infront of the global basedn for this query.
-f filter
LDAP search filter used to search the LDAP directory for any matching group memberships. In the filter %u will be replaced by the
user login name (or DN if the -F or -u options are used) and %g by the requested group name.
-F filter
LDAP search filter used to search the LDAP directory for any matching users. In the filter %s will be replaced by the user login
name. If % is to be included literally in the filter then use %%.
-u attr
LDAP attribute used to construct the user DN from the login name and base dn.
-s base|one|sub
search scope. Defaults to 'sub'.
base object only, one level below the base object or subtree below the base object
-D binddn -w password
The DN and password to bind as while performing searches. Required if the directory does not allow anonymous searches.
As the password needs to be printed in plain text in your Squid configuration and will be sent on the command line to the helper it
is strongly recommended to use a account with minimal associated privileges. This to limit the damage in case someone could get
hold of a copy of your Squid configuration file or extracts the password used from a process listing.
-P Use a persistent LDAP connection. Normally the LDAP connection is only open while validating a username to preserve resources at the
LDAP server. This option causes the LDAP connection to be kept open, allowing it to be reused for further user validations. Recom-
mended for larger installations.
-R do not follow referrals
-a never|always|search|find
when to dereference aliases. Defaults to 'never'
never dereference aliases (default), always dereference aliases, only while searching or only to find the base object
-h ldapserver
Specify the LDAP server to connect to
-p ldapport
Specify an alternate TCP port where the ldap server is listening if other than the default LDAP port 389.
-S Strip NT domain name component from usernames (/ or separated)
SQUID CONFIGURATION
This helper is intended to be used as a external_acl_type helper from squid.conf.
external_acl_type ldap_group %LOGIN /path/to/squid_ldap_group ...
acl group1 ldap_group Group1
acl group2 ldap_gorup Group2
NOTES
When constructing search filters it is strongly recommended to test the filter using ldapsearch before you attempt to use squid_ldap_group.
This to verify that the filter matches what you expect.
AUTHOR
This manual page was written by Henrik Nordstrom <hno@marasystems.com>
squid_ldap_group is written by Flavio Pescuma <flavio@marasystems.com> and Henrik Nordstrom <hno@squid-cache.org>, based on prior work in
squid_ldap_auth by Glen Newton <glen.newton@nrc.ca>
KNOWN LIMITATIONS
Max 16 occurances of %s in the -u argument is supported.
QUESTIONS
Any questions on usage can be sent to Squid Users <squid-users@squid-cache.org>, or to your favorite LDAP list/friend if the question is
more related to LDAP than Squid.
REPORTING BUGS
Report bugs or bug-fixes to Squid Bugs <squid-bugs@squid-cache.org> or ideas for new improvements to Squid Developers <squid-dev@squid-
cache.org>
SEE ALSO squid_ldap_auth(8), ldapsearch(1),
Your favorite LDAP documentation
RFC2254 - The String Representation of LDAP Search Filters,
Squid LDAP Match 7 September 2002 squid_ldap_group(8)