title: How to preserve data between two calls to controller methods?
body: <p>I have 2 JSPs: <code>pay.jsp</code>, <code>confirmPay.jsp</code></p>
  
  <p>User submits data (credit card# etc.) on <code>pay.jsp</code>. This data is validated at the backend and is displayed along with some other data, on <code>confirmPay.jsp</code>. Once he clicks on 'Confirm', the data (from the <code>pay.jsp</code> page) is used for billing. If he clicks 'Cancel', the payment is discarded.</p>
  
  <p>The important things here are:</p>
  
  <ol>
  <li>Data should be modifiable only in <code>pay.jsp</code></li>
  <li>Data should be preserved between the two calls</li>
  </ol>
  
  <p>I know this question is similar to <a href="https://stackoverflow.com/questions/10019132/how-to-prserve-the-modelmap-between-form-submits">How to preserve the ModelMap between form submits?</a>. Just wanted to know what works for situations like this, that involves sensitive information (like credit card#). Putting it in a session would mean that multiple calls in the same function will create issues.</p>
  
  <p>Please help me understand what the best choice is.</p>