How to send Authorization header in JSF - Mojarra - PrimeFaces

Viewed 110

We have a java 8 project with JSF Mojarra implementation with PrimeFaces 3.5. We are implementing the authentication OIDC using Spring Security.

The front has to include in each HTTP Request the header Authorization with the bearer token. We couldn't find how to add a header in a call any Primefaces component (commandbutton,etc).

When I use for example the commandLink tag (https://www.tutorialspoint.com/jsf/jsf_commandlink_tag.htm) I need that the rendered method mojarra.jsfcljs to send the Authorization header with my token when it calls the backend.

Is there any way of send customized headers with Mojarra in order to implement OIDC protocol?

0 Answers
Related