proxy_client.c revision e07d700ed9daf0cf96607fa2d72978cb2431b794
/*
SSSD
Authors:
Stephen Gallagher <sgallagh@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 "providers/proxy/proxy_iface_generated.h"
struct proxy_client {
struct proxy_auth_ctx *proxy_auth_ctx;
struct sbus_connection *conn;
struct tevent_timer *timeout;
bool initialized;
};
void *data,
{
struct sbus_connection *conn;
struct proxy_client *proxy_cli;
int hret;
struct tevent_req *req;
struct proxy_child_ctx *child_ctx;
struct pc_init_ctx *init_ctx;
return EINVAL;
}
/* First thing, cancel the timeout */
/* Check the hash table */
"Unknown child ID. Killing the connection\n");
return EIO;
}
if (hret != HASH_SUCCESS) {
return EIO;
}
/* Signal that the child is up and ready to receive the request */
/* This should hopefully be impossible, but protect
* against it anyway. If we're not marked running, then
* the init_req will be NULL below and things will
* break.
*/
"that's not marked as running\n");
return EIO;
}
return EOK;
}
struct tevent_timer *te,
struct timeval t,
void *ptr)
{
struct proxy_client *proxy_cli;
"Client timed out before Identification [%p]!\n", te);
/* If we time out here, we will also time out to
* pc_init_timeout(), so we'll finish the request
* there.
*/
}
{
struct proxy_auth_ctx *auth_ctx;
struct proxy_client *proxy_cli;
static struct iface_proxy_client iface_proxy_client = {
{ &iface_proxy_client_meta, 0 },
};
/* When connection is lost we also free the client. */
return ENOMEM;
}
proxy_cli->initialized = false;
/* Setup timeout in case client fails to register himself in time. */
/* Connection is closed in the caller. */
return ENOMEM;
}
/* Setup D-Bus interfaces and methods. */
/* Connection is closed in the caller. */
return ret;
}
return ret;
}