/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License (the "License").
* You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
* Copyright 2008 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#pragma ident "%Z%%M% %I% %E% SMI"
#include <project.h>
#include "ldap_common.h"
/* Project attributes filters */
static const char *project_attrs[] = {
(char *)NULL
};
/*
* _nss_ldap_proj2str is the data marshalling method for the project getXbyY
* (getprojbyname, getprojbyid, getprojent) backend processes. This method
* is called after a successful ldap search has been performed. This method
* will parse the ldap search values into the file format.
* e.g.
*
* system:0:System:::
*
* beatles:100:The Beatles:john,paul,george,ringo::task.max-lwps=
* (privileged,100,signal=SIGTERM),(privileged,110,deny)
*
* (All in one line)
*/
static int
{
int i;
int nss_result;
int firsttime;
return (NSS_STR_PARSE_PARSE);
/* In all cases it must be deallocated by caller */
goto result_proj2str;
}
} else
goto result_proj2str;
}
goto result_proj2str;
}
else
comment);
firsttime = 1;
for (i = 0; i < users->value_count; i++) {
goto result_proj2str;
}
if (firsttime) {
firsttime = 0;
} else {
}
}
}
firsttime = 1;
for (i = 0; i < groups->value_count; i++) {
goto result_proj2str;
}
if (firsttime) {
firsttime = 0;
} else {
}
}
}
else
/* The front end marshaller doesn't need the trailing nulls */
return ((int)nss_result);
}
/*
* getbyname gets a project entry by name. This function constructs an ldap
* search filter using the name invocation parameter and the getprojname search
* filter defined. Once the filter is constructed, we search for a matching
* entry and marshal the data results into struct project for the frontend
* process. The function _nss_ldap_proj2ent performs the data marshaling.
*/
static nss_status_t
{
return (NSS_NOTFOUND);
NULL));
}
/*
* getbyprojid gets a project entry by number. This function constructs an ldap
* search filter using the name invocation parameter and the getprojid search
* filter defined. Once the filter is constructed, we search for a matching
* entry and marshal the data results into struct project for the frontend
* process. The function _nss_ldap_proj2ent performs the data marshaling.
*/
static nss_status_t
{
return (NSS_NOTFOUND);
NULL));
}
};
/*ARGSUSED0*/
const char *dummy3)
{
return (_nss_ldap_constr(project_ops,
sizeof (project_ops) / sizeof (project_ops[0]),
}