/* $OpenLDAP$ */
/* This work is part of OpenLDAP Software <http://www.openldap.org/>.
*
- * Copyright 1998-2005 The OpenLDAP Foundation.
+ * Copyright 1998-2007 The OpenLDAP Foundation.
* Portions Copyright 1998-2003 Kurt D. Zeilenga.
* Portions Copyright 1998-2001 Net Boolean Incorporated.
* Portions Copyright 2001-2003 IBM Corporation.
const char options[] = ""
- "d:D:e:h:H:InO:p:QR:U:vVw:WxX:y:Y:Z";
+ "d:D:e:h:H:InO:o:p:QR:U:vVw:WxX:y:Y:Z";
int
handle_private_option( int i )
char *matcheddn = NULL, *text = NULL, **refs = NULL;
char *retoid = NULL;
struct berval *retdata = NULL;
- int id, code;
+ int id, code = 0;
LDAPMessage *res;
- tool_init();
+ tool_init( TOOL_WHOAMI );
prog = lutil_progname( "ldapwhoami", argc, argv );
/* LDAPv3 only */
tool_bind( ld );
- if ( not ) {
+ if ( dont ) {
rc = LDAP_SUCCESS;
goto skip;
}
- if ( assertion || authzid || manageDSAit || noop ) {
- tool_server_controls( ld, NULL, 0 );
- }
+ tool_server_controls( ld, NULL, 0 );
rc = ldap_whoami( ld, NULL, NULL, &id );