Hi, See my replies below.
> -----Original Message----- > > I've got the saml token stored as an axiom_node within rampart_context, > > and I add it into the sec_node as a child within > > rampart_saml_token_build (called by rampart_shb_build_message). > > Unfortunately this means that when the sec_node is destroyed at the end > > of a message send, the SAML token is destroyed too. So is there a way of > > duplicating an axiom_node so that I can add a clone into the sec_node > > instead. > No there is no such method. But why are you storing the saml token as an > axiom_node within the rampart_context? Cant't you keep the information > related to saml_token as a basic type or a user defined type. So that > inside rampart you can build the saml node using this information in > rampart_context. So for the next request you can alter those information > as you wish and rampart will build the saml node accoarding to the new > information. I'd like to do this, but it would require a proper SAML implementation, which unfortunately I don't have time for. Basically at present my only requirement is to receive a SAML token from a request, store it, and attach it into the security header at a later point. > > If there's not a way of duplicating them, like there is with attributes > > and namespaces, then I'll have to write a clone function myself. If I do > > have to do this, are there any pointers you'd like to share? > IMHO duplicating a node make no sense. Because a node always attached to > a om_tree. We are keeping shallow copies to the nodes in the tree. Well, not one particular node, but the entire tree, taking that node as the root. I have need for this in other places too, external to rampart (e.g so I can modify certain trees without altering the original). Or am I misunderstanding what you're saying? I can follow Kaushalye's suggestion and use axiom_node_to_string then use oxs_axiom_deserialize_node(), but is there no way to do it that's more elegant? > > Also, when creating the rampart_context, is there a way to tell it to > > load default data from the policy.xml file? At present I'm just > > hardcoding values for the default timeout, etc.. > > If you are not using a policy file that means those options are need to > be set by the user. This is useful when rampart is used from other > extensions like PHP. But for timeout there is a default value. But other > information are user specific so you need to set them using the set > functions in rampart_context. I'd like to use a policy file in conjunction with the custom one I create -- but when creating the rampart_context manually I don't know how to do this. The functions that rampart itself uses to load stuff from a policy file into the context aren't exported in the header files. If this isn't possible, setting the values manually really isn't much of an issue, it would just be nice if it was available. Thanks, Jamie --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
