Fwd: OpenSaml: BinarySecurityTokenMarshaller generates ValueType as EncodingType
Patrick Peer
p.peer at synedra.com
Thu Sep 3 08:27:48 UTC 2020
On Thu, Sep 3, 2020 at 2:03 AM Brent Putman <putmanb at georgetown.edu> wrote:
>
> On 9/2/20 5:18 PM, Patrick Peer wrote:
>
> Hi Brent,
>
> I am tasked to assemble a security token renew request, with signature and
> the whole shebang. To do so, I utilize the Java implementation of OpenSaml.
> I ran into a problem and it seems easier to contact you directly instead of
> jumping through the hoops necessary to open a Jira issue.
>
>
> First, please do not email the developers directly. Use the dev list
> (copied on this reply): https://www.shibboleth.net/community/
>
Will do. I briefly searched for a list like this. Not thoroughly enough it
seems :).
> Second, if you think you have found a bug and want it addressed, please do
> open a Jira issue. That is the way that issues get addressed.
>
The process necessary to get permission to post a Jira issue does not seem
to be straight forward or quick. I will go through it eventually, but right
now my focus is on developing a product.
>
>
> The BinarySecurityToken is required to have the EncodingType and ValueType
> attributes. However, the ValueType is never marshalled. Digging a bit, I
> found that the BinarySecurityTokenMarshaller uses the String "EncodingType"
> for the ValueType I provide. Digging even deeper I could track this down to
> commit d53f2af26987075774350ccb8d60db9110247638, which seems to split up
> the code for the two Types. Before, both were rendered
> within BinarySecurityTokenMarshaller with their respective correct names.
>
>
> This was contributed code from someone else over a decade ago and has not
> been thoroughly tested.
>
I wondered, too, why this did not pop up earlier.
>
>
> I'd be grateful for any insights, as It seems I will need to find a
> workaround to meet my deadlines. Currently I think I will just alter
> the DOM before generating the signature. I would prefer to not compile and
> distribute the openSaml library myself.
>
>
> Seems like a simple typo type of bug in the marshaller. We can fix it but
> I can't currently guarantee when we will do another release. You didn't
> mention whether you are using 3.x or 4.x. It's quite likely we will not be
> doing another release of 3.x at all.
>
I agree. The fix should be easy enough. The version of OpenSaml where the
fix will be included is not that important to me. We are not shy when it
comes to upgrading libraries, and a bugfix is a good reason to do so a
little earlier. Hearing from you, that 3.x is not under active development
anymore is an even better reason.
Meanwhile I found an easy solution: `token.setValueType(...);`=>
`token.getUnknownAttributes().put()`, so no hurry ;). Actually, I
anticipated that I'd need a workaround to finish my current work anyway,
and the biggest motivation to reach out to you (aside from finding a good
workaround in the first place) was that I thought you want to be aware of
the issue.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://shibboleth.net/pipermail/dev/attachments/20200903/a564417f/attachment.htm>
More information about the dev
mailing list