Securing your AJAX/Comet application using GlassFish