ipa_id.c revision 39be7dbfa25a1cae78741a1c6c8c744e8c87e38f
/*
SSSD
IPA Identity Backend Module
Authors:
Jan Zeleny <jzeleny@redhat.com>
Copyright (C) 2011 Red Hat
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include <errno.h>
#include "providers/ldap/ldap_common.h"
#include "providers/ldap/sdap_async.h"
struct tevent_context *ev,
struct ipa_id_ctx *ipa_ctx,
const char *name);
{
struct ipa_id_ctx *ipa_ctx;
struct sdap_id_ctx *ctx;
struct be_acct_req *ar;
struct tevent_req *req;
const char *err = "Unknown Error";
}
if (!req) {
}
return;
}
case BE_REQ_USER: /* user */
case BE_REQ_GROUP: /* group */
case BE_REQ_INITGROUPS: /* init groups for user */
case BE_REQ_SERVICES: /* Services. Not natively supported by IPA */
case BE_REQ_NETGROUP:
err = "Invalid filter type";
break;
}
if (!req) {
}
break;
default: /*fail*/
err = "Invalid request type";
}
}
int ret, const char *default_error_text)
{
const char* error_text;
error_text = NULL;
} else {
}
} else if (dp_error == DP_ERR_OFFLINE) {
error_text = "Offline";
error_text = "Out of memory";
} else {
}
}
{
}
{
const char *error_text;
}
/* Request for netgroups
* - first start here and then go to ipa_netgroups.c
*/
struct ipa_id_get_netgroup_state {
struct tevent_context *ev;
struct ipa_id_ctx *ctx;
struct sdap_id_op *op;
struct sss_domain_info *domain;
const char *name;
int timeout;
char *filter;
const char **attrs;
struct sysdb_attrs **netgroups;
int dp_error;
};
struct tevent_context *ev,
struct ipa_id_ctx *ipa_ctx,
const char *name)
{
struct tevent_req *req;
struct ipa_id_get_netgroup_state *state;
struct tevent_req *subreq;
struct sdap_id_ctx *ctx;
char *clean_name;
int ret;
goto fail;
}
goto fail;
}
goto fail;
}
if (!subreq) {
goto fail;
}
return req;
fail:
return req;
}
{
struct tevent_req *req =
struct ipa_id_get_netgroup_state *state =
int dp_error = DP_ERR_FATAL;
int ret;
return;
}
if (!subreq) {
return;
}
return;
}
{
struct tevent_req *req =
struct ipa_id_get_netgroup_state *state =
int dp_error = DP_ERR_FATAL;
int ret;
/* retry */
if (!subreq) {
return;
}
return;
}
return;
}
return;
}
return;
}
}
return;
}
{
struct ipa_id_get_netgroup_state *state =
if (dp_error) {
}
return EOK;
}
{
struct ipa_id_ctx *ipa_ctx;
struct ipa_id_ctx);
}