anchor.diff:  
   Spring Boot 2.0 brings full auto-configuration capabilities for OAuth 2.0 Login.
   
  -Let's jump right in and configure the {gh-samples-url}/boot/oauth2login[*OAuth 2.0 Login sample*] using _Google_ as the _Authentication Provider_.
  +This section shows how to configure the {gh-samples-url}/boot/oauth2login[*OAuth 2.0 Login sample*] using _Google_ as the _Authentication Provider_ and covers the following topics:
  +
  +* <<jc-oauth2login-sample-initial-setup>>
  +* <<jc-oauth2login-sample-redirect-uri>>
  +* <<jc-oauth2login-sample-application-config>>
  +* <<jc-oauth2login-sample-boot-application>>
  +
   
   [[jc-oauth2login-sample-initial-setup]]
   ===== Initial setup
   
  -In order to use Google's OAuth 2.0 authentication system for login, you must first set up a project in the *Google API Console* to obtain OAuth 2.0 credentials.
  +To use Google's OAuth 2.0 authentication system for login, you must set up a project in the Google API Console to obtain OAuth 2.0 credentials.
   
   NOTE: https://developers.google.com/identity/protocols/OpenIDConnect[Google's OAuth 2.0 implementation] for authentication conforms to the
    http://openid.net/connect/[OpenID Connect 1.0] specification and is http://openid.net/certification/[OpenID Certified].
   
  -Follow the instructions on the https://developers.google.com/identity/protocols/OpenIDConnect[OpenID Connect] page starting in the section *_"Setting up OAuth 2.0"_*.
  -
  -After completing the sub-section, *_"Obtain OAuth 2.0 credentials"_*, you should have created a new *OAuth Client* with credentials consisting of a *Client ID* and *Client Secret*.
  +Follow the instructions on the https://developers.google.com/identity/protocols/OpenIDConnect[OpenID Connect] page, starting in the section, "Setting up OAuth 2.0".
  +
  +After completing the "Obtain OAuth 2.0 credentials" instructions, you should have a new OAuth Client with credentials consisting of a Client ID and a Client Secret.
   
   [[jc-oauth2login-sample-redirect-uri]]
   ===== Setting the redirect URI
   
   The redirect URI is the path in the application that the end-user's user-agent is redirected back to after they have authenticated with Google
  -and have granted access to the OAuth Client _(<<jc-oauth2login-sample-initial-setup,created in previous step>>)_ on the *Consent screen* page.
  -
  -For the sub-section, *_"Set a redirect URI"_*, ensure the *Authorized redirect URIs* is set to *_"http://localhost:8080/login/oauth2/code/google"_*.
  -
  -TIP: The default redirect URI template is *_{baseUrl}/login/oauth2/code/{registrationId}_*.
  +and have granted access to the OAuth Client _(<<jc-oauth2login-sample-initial-setup,created in the previous step>>)_ on the Consent page.
  +
  +In the "Set a redirect URI" sub-section, ensure that the *Authorized redirect URIs* field is set to `http://localhost:8080/login/oauth2/code/google`.
  +
  +TIP: The default redirect URI template is `{baseUrl}/login/oauth2/code/{registrationId}`.
    The *_registrationId_* is a unique identifier for the <<jc-oauth2login-client-registration,ClientRegistration>>.
   
   [[jc-oauth2login-sample-application-config]]
  -===== Configure application.yml
  -
  -Now that you have created a new OAuth Client with Google, you need to configure the application to use the OAuth Client for the _authentication flow_.
  -
  -Go to *application.yml* and set the following configuration:
  -
  +===== Configure `application.yml`
  +
  +Now that you have a new OAuth Client with Google, you need to configure the application to use the OAuth Client for the _authentication flow_. To do so:
  +
  +. Go to `application.yml` and set the following configuration:
  ++
   [source,yaml]
   ----
   spring:
  
positive.code: }
  ----
  
  The sections to follow will go more into detail on each of the configuration options available.
  
  [[oauth2login-advanced-login-page]]
  === OAuth 2.0 Login Page
  
  By default, the OAuth 2.0 Login Page will be _auto-generated_ by the `DefaultLoginPageGeneratingFilter`.
  The default login page will display each configured OAuth Client with it's `ClientRegistration.clientName`
  as a link, that is capable of initiating the _Authorization Request_ (or OAuth 2.0 Login).
  
  The link's destination for each OAuth Client defaults to the following:
  
  `OAuth2AuthorizationRequestRedirectFilter.DEFAULT_AUTHORIZATION_REQUEST_BASE_URI` + "/{registrationId}"
  
  For example:
  
  [source,html]
  ----
  <a href="/oauth2/authorization/google">Google</a>
  ----
  
  If you would like to override the default login page,
  you need to configure `oauth2Login().loginPage()` and optionally `oauth2Login().authorizationEndpoint().baseUri()`.
  
  For example:
  
  [source,java]
  ----
  
negative.code: [[jc-oauth2login-common-oauth2-provider]]
  ==== CommonOAuth2Provider
  
  `CommonOAuth2Provider` pre-defines a set of default client properties for a number of well known providers: Google, GitHub, Facebook, and Okta.
  
  For example, the `authorization-uri`, `token-uri`, and `user-info-uri` do not change often for a Provider. Therefore, it makes sense to
  provide default values in order to reduce the required configuration.
  
  As demonstrated previously, when we <<jc-oauth2login-sample-application-config,configured a Google client>>, only the `client-id` and `client-secret` properties are required.
  
  The following listing shows an example:
  
  [source,yaml]
  ----
  