spring-securitySpring Security config with java (not XML)


Introduction

Typical database backed, annotation base spring security setup.

Syntax

  1. configureGlobal() configure the auth object.
  2. The later two SQLs may be optional.
  3. configure() method tells spring mvc how to authenticate request
  4. some url we do not need to authenticate
  5. others will redirect to /login if not yet authenticated.