request is an implicit object in JSP page.
So, you can try out like this.
request.getAttribute("the name you have used in servlet class");
In servlet class
In servlet class request.setAttribute("sessVariable", flag);
In JSP page;
Boolean value = (Boolean)request.getAttribute("sessVariable");
NOTE: whater type of Object you have set to request, while retrieving you have to do the casting of same type. otherwise, you will be getting ClassCastException.
Hope this will resolve you problem.