sysdb_selinux.c revision a3c8390d19593b1e5277d95bfb4ab206d4785150
/*
SSSD
System Database - SELinux support
Copyright (C) Jan Zeleny <jzeleny@redhat.com> 2012
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 "util/sss_selinux.h"
#include "db/sysdb_selinux.h"
#include "db/sysdb_private.h"
/* Some generic routines */
enum selinux_entity_type {
};
static errno_t
const char *objectclass,
struct sysdb_attrs *attrs,
{
struct ldb_message *msg;
if (!tmp_ctx) {
return ENOMEM;
}
if (!msg) {
goto done;
}
return ret;
}
if (!now) {
}
done:
if (ret) {
}
return ret;
}
struct sysdb_attrs *attrs,
enum selinux_entity_type type)
{
bool in_transaction = false;
const char *objectclass = NULL;
const char *name;
char *clean_name;
if (!tmp_ctx) {
return ENOMEM;
}
switch (type) {
case SELINUX_USER_MAP:
goto done;
}
goto done;
}
break;
case SELINUX_CONFIG:
break;
}
goto done;
}
if (!dn) {
goto done;
}
goto done;
}
in_transaction = true;
goto done;
}
goto done;
}
goto done;
}
in_transaction = false;
done:
if (in_transaction) {
}
}
if (ret) {
}
return ret;
}
struct sysdb_attrs *attrs)
{
}
const char *default_user,
const char *order)
{
struct sysdb_attrs *attrs;
return ENOMEM;
}
if (!order) {
return EINVAL;
}
if (default_user) {
goto done;
}
}
order);
goto done;
}
done:
return ret;
}
{
return ret;
}
return EOK;
}
/* --- SYSDB SELinux search routines --- */
struct sss_domain_info *domain,
const char **attrs,
struct ldb_message ***messages)
{
char *filter;
if (!basedn) {
return ENOMEM;
}
return ENOMEM;
}
*count = 0;
} else if (ret) {
return ret;
}
return EOK;
}
struct sss_domain_info *domain,
const char **attrs,
struct ldb_message **_config)
{
const char *def_attrs[] = { SYSDB_SELINUX_DEFAULT_USER,
NULL };
struct ldb_message **msgs;
if (!tmp_ctx) {
return ENOMEM;
}
if (!basedn) {
goto done;
}
if (ret) {
goto done;
}
done:
} else if (ret) {
}
return ret;
}