Since I did not get an answer yet, I will try rephrasing my question!
I would like to find a mechanism that will allow me to get the user principal both in my server (EJB Container) and my client (servlet container).
When using form based login, I can get the user principal in my jsp but not in my EJBs. Reversely, when I use the JAAS login as stated above, I cannot get the principal from by jsp, but I can from my EJBs (given the filter).
I cannot get my filter to work when using a form based login, because I have no way of getting the user name and password...