[
https://issues.apache.org/jira/browse/RAMPART-349?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17896041#comment-17896041
]
Robert Lazarski commented on RAMPART-349:
-----------------------------------------
I am confused by this patch.
I am pasting it here as "subject" on setNameID() is not in scope in any version
of SAML2TokenIssuer.java.
+ if (data.getPrincipal() != null) {
+ //get subject's name from Rahas data
+ String subjectNameID = data.getPrincipal().getName();
+ //Create NameID and attach it to the subject
+ NameID nameID = new NameIDBuilder().buildObject();
+ nameID.setValue(subjectNameID);
+ nameID.setFormat(NameIdentifier.EMAIL);
+ subject.setNameID(nameID);
+ }
The above is code from the patch on method
SAML2TokenIssuer.createKeyInfo(Document doc, Crypto crypto, RahasData data)
which passes in no SAML Subject.
I mention this because similar code is right above the invocation of the method
createKeyInfo(). So, I see an out of scope subject that does something similar
to code that is called right before it.
I am deferring this until 2.0.0. until I can understand this better however
after all this time I may mark it as incomplete without additional feedback.
> In SAML2 token, subject's NameID is not attached to the subject when HOK SC
> is used with key type:SymmetricKey
> ---------------------------------------------------------------------------------------------------------------
>
> Key: RAMPART-349
> URL: https://issues.apache.org/jira/browse/RAMPART-349
> Project: Rampart
> Issue Type: Bug
> Environment: When creating Subject element with Holder of Key Subject
> Confirmation method and when Symmetric Key is given as the key type, NameID
> of the subject is not created and attached to the subject.
> Reporter: Hasini Gunasinghe
> Assignee: Robert Lazarski
> Priority: Major
> Fix For: 1.8.0
>
> Attachments: RAMPART-349.patch
>
>
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]