From: Miloš Mulač Date: Mon, 6 Mar 2006 11:29:53 +0000 (+0000) Subject: use credentials given on command line when communicating with PS X-Git-Tag: glite-jp-index_R_1_2_0~13 X-Git-Url: http://scientific.zcu.cz/git/?a=commitdiff_plain;h=80ee933edc9d333f74ca4dc6926761f8d61b73ef;p=jra1mw.git use credentials given on command line when communicating with PS --- 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; }