From d37b8091a8f16e94c26e5eb2ddb922d51928deda Mon Sep 17 00:00:00 2001 From: Jakub Hrozek Date: Tue, 19 Aug 2014 19:27:16 +0200 Subject: Revert "IPA: new attribute map for non-posix groups" This reverts commit b7afe5caaaeae1e92479284a7f555aee4ba23422. --- src/providers/ldap/ldap_id.c | 8 +------- src/providers/ldap/sdap.h | 11 ----------- src/providers/ldap/sdap_async.h | 3 +-- src/providers/ldap/sdap_async_initgroups.c | 12 +++--------- 4 files changed, 5 insertions(+), 29 deletions(-) (limited to 'src/providers/ldap') diff --git a/src/providers/ldap/ldap_id.c b/src/providers/ldap/ldap_id.c index 2cc8fc80e..2d1ba5b5a 100644 --- a/src/providers/ldap/ldap_id.c +++ b/src/providers/ldap/ldap_id.c @@ -927,7 +927,6 @@ struct groups_by_user_state { const char *name; const char **attrs; - const char **np_attrs; int dp_error; int sdap_ret; @@ -975,10 +974,6 @@ static struct tevent_req *groups_by_user_send(TALLOC_CTX *memctx, NULL, &state->attrs, NULL); if (ret != EOK) goto fail; - ret = build_attrs_from_map(state, ctx->opts->np_group_map, SDAP_OPTS_NP_GROUP, - NULL, &state->np_attrs, NULL); - if (ret != EOK) goto fail; - ret = groups_by_user_retry(req); if (ret != EOK) { goto fail; @@ -1033,8 +1028,7 @@ static void groups_by_user_connect_done(struct tevent_req *subreq) state->ctx, state->conn, state->name, - state->attrs, - state->np_attrs); + state->attrs); if (!subreq) { tevent_req_error(req, ENOMEM); return; diff --git a/src/providers/ldap/sdap.h b/src/providers/ldap/sdap.h index 567cf42a3..a766779e5 100644 --- a/src/providers/ldap/sdap.h +++ b/src/providers/ldap/sdap.h @@ -301,16 +301,6 @@ enum sdap_group_attrs { SDAP_OPTS_GROUP /* attrs counter */ }; -/* the objectclass must be the first attribute. - * Functions depend on this */ -enum sdap_np_group_attrs { - SDAP_OC_NP_GROUP = 0, - SDAP_AT_NP_GROUP_NAME, - SDAP_AT_NP_GROUP_MEMBER, - - SDAP_OPTS_NP_GROUP /* attrs counter */ -}; - enum sdap_netgroup_attrs { SDAP_OC_NETGROUP = 0, SDAP_AT_NETGROUP_NAME, @@ -423,7 +413,6 @@ struct sdap_options { struct sdap_attr_map *user_map; size_t user_map_cnt; struct sdap_attr_map *group_map; - struct sdap_attr_map *np_group_map; struct sdap_attr_map *netgroup_map; struct sdap_attr_map *service_map; diff --git a/src/providers/ldap/sdap_async.h b/src/providers/ldap/sdap_async.h index f54ab8b57..593404af3 100644 --- a/src/providers/ldap/sdap_async.h +++ b/src/providers/ldap/sdap_async.h @@ -134,8 +134,7 @@ struct tevent_req *sdap_get_initgr_send(TALLOC_CTX *memctx, struct sdap_id_ctx *id_ctx, struct sdap_id_conn_ctx *conn, const char *name, - const char **grp_attrs, - const char **np_grp_attrs); + const char **grp_attrs); int sdap_get_initgr_recv(struct tevent_req *req); struct tevent_req *sdap_exop_modify_passwd_send(TALLOC_CTX *memctx, diff --git a/src/providers/ldap/sdap_async_initgroups.c b/src/providers/ldap/sdap_async_initgroups.c index 220b96ae7..6c10c4ce7 100644 --- a/src/providers/ldap/sdap_async_initgroups.c +++ b/src/providers/ldap/sdap_async_initgroups.c @@ -706,7 +706,6 @@ struct sdap_initgr_nested_state { const char *orig_dn; const char **grp_attrs; - const char **np_grp_attrs; struct ldb_message_element *memberof; char *filter; @@ -736,8 +735,7 @@ static struct tevent_req *sdap_initgr_nested_send(TALLOC_CTX *memctx, struct sss_domain_info *dom, struct sdap_handle *sh, struct sysdb_attrs *user, - const char **grp_attrs, - const char **np_grp_attrs) + const char **grp_attrs) { struct tevent_req *req; struct sdap_initgr_nested_state *state; @@ -2676,7 +2674,6 @@ struct sdap_get_initgr_state { struct sdap_id_conn_ctx *conn; const char *name; const char **grp_attrs; - const char **np_grp_attrs; const char **user_attrs; char *user_base_filter; char *filter; @@ -2701,8 +2698,7 @@ struct tevent_req *sdap_get_initgr_send(TALLOC_CTX *memctx, struct sdap_id_ctx *id_ctx, struct sdap_id_conn_ctx *conn, const char *name, - const char **grp_attrs, - const char **np_grp_attrs) + const char **grp_attrs) { struct tevent_req *req; struct sdap_get_initgr_state *state; @@ -3041,11 +3037,9 @@ static void sdap_get_initgr_user(struct tevent_req *subreq) break; case SDAP_SCHEMA_IPA_V1: - subreq = sdap_initgr_nested_send(state, state->ev, state->opts, state->sysdb, state->dom, state->sh, - state->orig_user, state->grp_attrs, - state->np_grp_attrs); + state->orig_user, state->grp_attrs); if (!subreq) { tevent_req_error(req, ENOMEM); return; -- cgit