You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-dev@axis.apache.org by Radley Kneeland <ra...@gmail.com> on 2011/05/09 23:31:54 UTC
Setting SSL properties at runtime
I came across this page, but it seems to be out of date.
http://people.apache.org/~dumindu/docs/HowToConfigureSSL.html
What API is used to dynamically set properties into the axis2.xml file at
runtime?
Re: Setting SSL properties at runtime
Posted by Nandika Jayawardana <ja...@gmail.com>.
axis2_options api is used to set properties dynamically.
You can use following code sample to set configure SSL.
axutil_property_t *ssl_server_key_prop = NULL;
axutil_property_t *ssl_client_key_prop = NULL;
axutil_property_t *passphrase_prop = NULL;
char *ssl_server_key_filename = NULL;
char *ssl_client_key_filename = NULL;
char *passphrase = NULL;
ssl_server_key_prop = axutil_property_create_with_args (env, 0,
AXIS2_TRUE, 0,
axutil_strdup (env, ssl_server_key_filename));
axis2_options_set_property (options, env, AXIS2_SSL_SERVER_CERT,
ssl_server_key_prop);
ssl_client_key_prop = axutil_property_create_with_args (env, 0,
AXIS2_TRUE, 0,
axutil_strdup (env, ssl_client_key_filename));
axis2_options_set_property (options, env, AXIS2_SSL_KEY_FILE,
ssl_client_key_prop);
passphrase_prop = axutil_property_create_with_args (env, 0, AXIS2_TRUE,
0,
axutil_strdup (env, passphrase));
axis2_options_set_property (options, env, AXIS2_SSL_PASSPHRASE,
passphrase_prop);
Replace appropriate file name values to the file name pointers.
Regards
Nandika
On Tue, May 10, 2011 at 3:01 AM, Radley Kneeland <ra...@gmail.com>wrote:
> I came across this page, but it seems to be out of date.
> http://people.apache.org/~dumindu/docs/HowToConfigureSSL.html
>
> What API is used to dynamically set properties into the axis2.xml file at
> runtime?
>