[ 
https://issues.apache.org/jira/browse/WSS-68?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12602598#action_12602598
 ] 

Colm O hEigeartaigh commented on WSS-68:
----------------------------------------


Sergio,

This functionality is only designed to be used when the password element is 
absent. In your code you have:

builder.setUserInfo("user", "password"); 

and this is causing the NPE. To get it to work try:

builder.setUserInfo("user", null); 

> No way to create a UsernameToken with absent <Password> element
> ---------------------------------------------------------------
>
>                 Key: WSS-68
>                 URL: https://issues.apache.org/jira/browse/WSS-68
>             Project: WSS4J
>          Issue Type: Bug
>            Reporter: George Stanchev
>             Fix For: 1.5.4
>
>         Attachments: UsernameToken.java, wss4j-1.5.3.patch, 
> WSSecUsernameToken.java
>
>
> We should be able to create UsernameTokens without <Password> in them if 
> needed. Password is an optional element

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to