Hi Nick,
Here is a clue. You might want to tweak it around since i had to clear
up some stuff from the existing code, but you get the idea.
Hope this helps
Properties prop1 = new Properties();
prop1.setProperty("org.apache.ws.security.crypto.provider",
"org.apache.ws.security.components.crypto.Merlin");
prop1.setProperty("org.apache.ws.security.crypto.merlin.keystore.type",
"jks");
prop1.setProperty("org.apache.ws.security.crypto.merlin.keystore.passwor
d", "password");
prop1.setProperty("org.apache.ws.security.crypto.merlin.file",
"c:/mykeystore.jks");
OutflowConfiguration ofc = new OutflowConfiguration();
ofc.setActionItems("Timestamp Signature");
// other ofc setup goes here
ofc.setSignaturePropRefId("cyrpto_props");
ServiceClient.getOptions.setProperty("cyrpto_props", prop1);
George
________________________________
From: Nick Haines [mailto:[EMAIL PROTECTED]
Sent: Friday, February 16, 2007 10:19 AM
To: [email protected]
Subject: Rampart 1.1 dynamic configuration
Hi there,
I'm trying to write a WebService client which dynamically configures the
security for a WebService. My problem is that I don't really want to
access the Signature/Encryption properties file from disk
(client.properties), and I can't see a way to avoid this.
Is there an option I've missed where I can configure this
programmatically (such as passing a Properties object rather than a
filename) into the Inflow/Outflow Configuration object (or as an
Option)?
I realize I could, and should be using policy files now, which I can
build up dynamically from what I've seen, but I'm reluctant to redo
everything else for this one reason if there is an alternative.
Thanks in advance
-Nick
**********************************************************************
This email and any files transmitted with it are confidential and intended
solely for the use of the individual or entity to whom they are addressed. Any
unauthorized review, use, disclosure or distribution is prohibited. If you are
not the intended recipient, please contact the sender by reply e-mail and
destroy all copies of the original message.