Hi

do you have a http request? getRemoteHost() doesn't help?
getRemoteUser and getRemoteAddr are not yet implemented in embedded
mode. If you use secured endpoints you can use
sessionContext.getCallerPrincipal()
Romain Manni-Bucau
Twitter: @rmannibucau
Blog: http://rmannibucau.wordpress.com/
LinkedIn: http://fr.linkedin.com/in/rmannibucau
Github: https://github.com/rmannibucau



2014-10-14 11:46 GMT+02:00 Ƹ̵̡Ӝ̵̨̄Ʒ Charms Styler <[email protected]>:
> Tried my OpenEJB embedded application as the server (only openejb
> container). Wondering How I can collect information about the
> requester like the IP. This strictly for audit purpose and also to
> prevent users from making attacks. Thread.currentThread().getName()
> seems to be the only way people could actually sniff the request ip on
> ejb. I tried that on OpenEJB but no luck so far. any advice ?
>
>
> @Stateless
> public class HelloBean implements Hello{
>     public String sayHello(){
> System.out.println("Requestor "+ Thread.currentThread().getName());
>         return "Hello World!!!!";
>     }
> }

Reply via email to