WS-Trust STS service in wildfly 37

22 views
Skip to first unread message

Chege Kĩnũthia

unread,
Sep 20, 2025, 3:47:11 AM (7 days ago) Sep 20
to WildFly
Hi,

I am trying to implement STS web service as described here https://docs.wildfly.org/37/Developer_Guide.html#security-token-service-sts .

 I am getting a null pointer exception 

Caused by: java.lang.NullPointerException: Cannot invoke "jakarta.xml.ws.WebServiceContext.getMessageContext()" because "this.context" is null
at org.apache.cx...@4.0.9//org.apache.cxf.ws.security.sts.provider.SecurityTokenServiceProvider.createSOAPFault(SecurityTokenServiceProvider.java:283)
at org.apache.cx...@4.0.9//org.apache.cxf.ws.security.sts.provider.SecurityTokenServiceProvider.invoke(SecurityTokenServiceProvider.java:266)
at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
at java.base/java.lang.reflect.Method.invoke(Method.java:580)

After debugging I have found out that 

 @Resource
    private WebServiceContext context;


inside SecurityTokenServiceProvider is always null.
Anyone who has a working demo or workaround?

Chege

Richard Opalka

unread,
Sep 26, 2025, 3:42:19 AM (yesterday) Sep 26
to Chege Kĩnũthia, WildFly
Hello Chege,

   Could you share the whole stacktrace, please?

Rio

--
You received this message because you are subscribed to the Google Groups "WildFly" group.
To unsubscribe from this group and stop receiving emails from it, send an email to wildfly+u...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/wildfly/4b45ee44-9850-479b-9d23-ed2dc69caab8n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages