/*
SSSD
Kerberos 5 Backend Module -- Request a TGT when the system gets online
Authors:
Sumit Bose <sbose@redhat.com>
Copyright (C) 2010 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 <security/pam_modules.h>
#ifdef USE_KEYRING
#include <keyutils.h>
#endif
#include <dhash.h>
#include "providers/krb5/krb5_auth.h"
#include "util/find_uid.h"
struct deferred_auth_ctx {
};
struct auth_data {
};
{
}
{
}
struct tevent_timer *te,
struct timeval current_time,
void *private_data)
{
struct auth_data);
#ifdef USE_KEYRING
char *password;
long keysize;
long keyrevoke;
if (keysize == -1) {
return;
}
if (ret) {
"failed to set password in auth token [%d][%s].\n",
return;
}
if (keyrevoke == -1) {
}
#endif
return;
}
}
{
struct auth_data);
int ret;
if (ret) {
} else {
if (pam_status == PAM_SUCCESS) {
"Successfully authenticated user [%s].\n",
} else {
}
}
}
struct deferred_auth_ctx *deferred_auth_ctx)
{
int ret;
if (ret != HASH_SUCCESS) {
return ret;
}
return EINVAL;
}
if (ret == HASH_SUCCESS) {
struct auth_data);
} else {
}
}
} else {
}
if (ret != HASH_SUCCESS) {
}
}
return EOK;
}
{
int ret;
"but user table does not exists.\n");
return;
}
"Backend is online, starting delayed online authentication.\n");
}
return;
}
struct sss_domain_info *domain,
{
int ret;
"Domain type does not support delayed authentication\n");
return ENOTSUP;
}
"Missing context for delayed online authentication.\n");
return EINVAL;
}
return EINVAL;
}
return EINVAL;
}
return ENOMEM;
}
#ifdef USE_KEYRING
const char *password;
if (ret) {
return ret;
}
return ret;
}
#endif
if (ret != HASH_SUCCESS) {
"delayed online authentication not possible.\n",
return ENOMEM;
}
return EOK;
}
struct tevent_context *ev)
{
int ret;
"on an unsupported system.\n");
} else {
"but initialisation failed.\n");
}
return ret;
}
if (ret != HASH_SUCCESS) {
return EFAULT;
}
struct deferred_auth_ctx);
return ENOMEM;
}
0, 0, 0, 0, hash_talloc, hash_talloc_free,
if (ret != HASH_SUCCESS) {
goto fail;
}
goto fail;
}
/* TODO: add destructor */
return EOK;
fail:
return ret;
}