title: Authenticating my Ionic 3 app against Spring Boot REST API
body: <p>The question must be very typical, but I can't really find a good comparison.</p>
  
  <p>I'm new to Ionic &amp; mobile dev.
  We have a REST API (Spring Boot).
  API is currently used by AngularJS 1.5 front-end only.
  AngularJS app is authenticated based on the standard session-based authentication.</p>
  
  <p>What should I use to authenticate an ionic 3 app?
  As I understand, have 2 options:</p>
  
  <ol>
  <li>Use the same auth as for Angular front-end.</li>
  <li>implement oauth2 on the back-end and use the token for the ionic app.</li>
  </ol>
  
  <p>As for now, I understand that implementing oauth2 at back-end is a way to go because with the option #1 I should store the username &amp; password in the local storage (ionic app), which is not safe. Otherwise, if I don't do that - the user will have to authenticate each time the app was launched. Am I right?</p>
  
  <p>So, that leaves me with option #2 - store oauth2 token on the device?</p>