In order to accomplish this task you don't need a full hibernate plugin. You are looking to implement the Open Session In View pattern. Basically the idea is to implement a servlet filter that opens a hibernate session, passes control to the rest of the filter chain, and then closes the filter once execution is complete. In this manner your view has an open session to play with, and it gets closed in the end. However, it should be pointed out that some people view this as an anti-pattern, since it does allow your view code to trigger a large number of database related operations via lazy loading and such. This is definitely something to keep in mind.
There are a number of examples online, usually under the abbreviation OSIV, here is one using straight hibernate that I wrote for a former employer that is open sourced. I think the original version of this was written in 2007 or so and recently moved from SVN to GIT:
https://fisheye.5amsolutions.com/browse/5AMCOM/core/src/main/java/com/fiveamsolutions/commons/web/filter/OpenSessionInViewFilter.java?r=78fe9215dcbdea11ed54e7446bf19f779cb13770
The home page to their open source library that includes this is here:
https://www.5amsolutions.com/how-we-do-it/5am-commons
If you want to use a complete JPA solution, spring does include an Open Entity Manager in View filter:
http://static.springsource.org/spring/docs/3.1.x/javadoc-api/org/springframework/orm/jpa/support/OpenEntityManagerInViewFilter.html
I haven't used that specific class since I haven't used Spring in years, but Spring's stuff usually works very well.
One last link on the topic is a few years old from the hibernate docs:
https://community.jboss.org/wiki/OpenSessionInView