From 80ee933edc9d333f74ca4dc6926761f8d61b73ef Mon Sep 17 00:00:00 2001 From: =?utf8?q?Milo=C5=A1=20Mula=C4=8D?= Date: Mon, 6 Mar 2006 11:29:53 +0000 Subject: [PATCH] use credentials given on command line when communicating with PS --- org.glite.jp.index/src/soap_ps_calls.c | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/org.glite.jp.index/src/soap_ps_calls.c b/org.glite.jp.index/src/soap_ps_calls.c index ddd899b..874b8b0 100644 --- a/org.glite.jp.index/src/soap_ps_calls.c +++ b/org.glite.jp.index/src/soap_ps_calls.c @@ -133,15 +133,18 @@ int MyFeedIndex(glite_jpis_context_t ctx, glite_jp_is_conf *conf, long int uniqu // struct xsd__base64Binary blob; int i, dest_index; struct soap *soap = soap_new(); + glite_gsplugin_Context plugin_ctx; glite_jp_error_t err; char *src, hname[512]; lprintf("MyFeedIndex for %s called\n", dest); - + glite_gsplugin_init_context(&plugin_ctx); + if (ctx->conf->server_key) plugin_ctx->key_filename = strdup(ctx->conf->server_key); + if (ctx->conf->server_cert) plugin_ctx->cert_filename = strdup(ctx->conf->server_cert); + soap_init(soap); soap_set_namespaces(soap,jpps__namespaces); -// TODO - soap_register_plugin(soap,glite_gsplugin); + soap_register_plugin_arg(soap,glite_gsplugin,plugin_ctx); memset(&in, 0, sizeof(in)); memset(&err, 0, sizeof(err)); @@ -187,12 +190,18 @@ lprintf("MyFeedIndex for %s called\n", dest); glite_jpis_unlockFeed(ctx, uniqueid); } + soap_end(soap); + soap_done(soap); + return 0; + err: err.source = src; glite_jp_stack_error(ctx->jpctx, &err); free(src); soap_end(soap); + soap_done(soap); + return err.code; } -- 1.8.2.3