index.html 1009 B

1234567891011121314151617181920212223242526272829
  1. <!DOCTYPE html>
  2. <html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org" xmlns:sec="http://www.thymeleaf.org/thymeleaf-extras-springsecurity4">
  3. <head>
  4. <title>Spring Security - OAuth 2.0 Login</title>
  5. <meta charset="utf-8" />
  6. </head>
  7. <body>
  8. <div style="float: right" th:fragment="logout" sec:authorize="isAuthenticated()">
  9. <div style="float:left">
  10. <span style="font-weight:bold">User: </span><span sec:authentication="name"></span>
  11. </div>
  12. <div style="float:none">&nbsp;</div>
  13. <div style="float:right">
  14. <form action="#" th:action="@{/logout}" method="post">
  15. <input type="submit" value="Logout" />
  16. </form>
  17. </div>
  18. </div>
  19. <h1>OAuth 2.0 Login with Spring Security</h1>
  20. <div>
  21. You are successfully logged in <span style="font-weight:bold" th:text="${userName}"></span>
  22. via the OAuth 2.0 Client <span style="font-weight:bold" th:text="${clientName}"></span>
  23. </div>
  24. <div>&nbsp;</div>
  25. <div>
  26. <a href="/userinfo" th:href="@{/userinfo}">Display User Info</a>
  27. </div>
  28. </body>
  29. </html>