when the whole browser tab gets closed
You can capture a closing tab, with HTML DOM events like beforeunload.
My questions are: How can I have the list of opened pages (views) from server side?
You can list them in an application scoped bean. i.e : Add a view to a list when the view has been called and initiated, and remove it from the list on tab unload/closure ? From that list you can do lot of checkings.. and even close a session if there are no more views associated with it.