Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Include InclusiveNamespaces in transform tag #60

Closed
cmartin81 opened this issue Jun 24, 2015 · 2 comments · Fixed by #284
Closed

Include InclusiveNamespaces in transform tag #60

cmartin81 opened this issue Jun 24, 2015 · 2 comments · Fixed by #284

Comments

@cmartin81
Copy link

Hi
I need to define a reference when signing my xml with a html tag called: InclusiveNamespaces.
Are there any solution for this?

This is what I need to have inside my reference tag:


@yaronn
Copy link
Contributor

yaronn commented Jun 24, 2015

Hi @cmartin81

This is not supported yet but some of the infrustructure so it might not be complex to implement if you want to try. Check this part in signed-xml.js:

https://github.com/auth0/xml-crypto/blob/be60701831079964ca56dbbd87a263af689fa509/lib/signed-xml.js#L416

you need two changes:

  1. the getCannonXml() method can get a third parameter with the namespaces you want in the PrefixList (see how to call it here https://github.com/auth0/xml-crypto/blob/be60701831079964ca56dbbd87a263af689fa509/lib/signed-xml.js#L246)
  2. In the same place where you added the parameter, see how the "transform" xml tag is built. you need to add it the "InclusiveNamespaces" child tag as in your example (using simple string concat).

You can try to do it hard coded with your required namespaces so it will be very fast to check if it works.

Thanks,
Yaron

@zygimantus
Copy link

So, InclusiveNamespaces are not supported yet?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants