ifp_cache.c revision d3c82d0170d6d7407549afdadd08aa7e11aeb9a2
/*
Authors:
Pavel Březina <pbrezina@redhat.com>
Copyright (C) 2015 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 <talloc.h>
#include <tevent.h>
#include "responder/common/responder.h"
#include "responder/ifp/ifp_cache.h"
#include "responder/ifp/ifp_users.h"
#include "responder/ifp/ifp_groups.h"
#include "responder/ifp/ifp_iface_generated.h"
static struct ldb_dn *
enum ifp_cache_type type,
struct sss_domain_info *domain)
{
switch (type) {
case IFP_CACHE_USER:
break;
case IFP_CACHE_GROUP:
break;
}
return base_dn;
}
static char *
enum ifp_cache_type type,
struct sss_domain_info *domain,
struct ldb_message *msg)
{
char *path;
switch (type) {
case IFP_CACHE_USER:
break;
case IFP_CACHE_GROUP:
break;
}
return path;
}
static const char *
{
switch (type) {
case IFP_CACHE_USER:
break;
case IFP_CACHE_GROUP:
break;
}
return class;
}
static errno_t
enum ifp_cache_type type,
struct sss_domain_info *domain,
const char ***_paths,
int *_num_paths)
{
struct ldb_result *result;
const char **paths;
int ldb_ret;
int i;
SYSDB_GIDNUM, NULL};
return ENOMEM;
}
goto done;
}
"(&(objectClass=%s)(%s=TRUE))", class,
if (ldb_ret != LDB_SUCCESS) {
goto done;
}
goto done;
}
goto done;
}
}
done:
return ret;
}
void *data,
enum ifp_cache_type type)
{
struct sss_domain_info *domain;
const char **tmp_paths;
int num_tmp_paths;
const char **paths;
int num_paths;
return ERR_INTERNAL;
}
num_paths = 0;
&tmp_paths, &num_tmp_paths);
"Unable to build object list [%d]: %s\n",
}
discard_const(&paths));
"Unable to build object list [%d]: %s\n",
}
}
return EOK;
}
void *data,
const char *domainname,
enum ifp_cache_type type)
{
struct sss_domain_info *domain;
const char **paths;
int num_paths;
return ERR_INTERNAL;
}
}
}
return EOK;
}
bool value)
{
struct sysdb_attrs *attrs;
return ENOMEM;
}
goto done;
}
goto done;
}
done:
return ret;
}
struct sss_domain_info *domain,
{
} else {
}
return EOK;
}
struct sss_domain_info *domain,
{
} else {
}
return EOK;
}