title: How to secure my java web application?
body: <p>I have a web application in which when users login they reach the <code>mainjsp.jsp</code> page.</p>
  
  <p>In this page there are few text-box for dates and based on dates and selection from another drop-down, data is submitted. This data is retrieved by a <code>servlet</code> and brought back to the <code>mainjsp</code> page.</p>
  
  <p>My concern is about security. Now when I copy paste the <code>mainjsp.jsp</code> page's URL and paste it in any browser this page appears as it is. I don't want this to happen. I want the users to login first and hence I want my web application secure.</p>
  
  <p>I don't have any idea how to do this. Could you please tell me how can I achieve this?</p>
  
  <p>Also please tell me how do I achieve this for any of the pages in the web-application. Users should not be able to access any page if they haven't logged in.</p>