1.login
This commit is contained in:
parent
a24ace5245
commit
42a0038afd
6
pom.xml
6
pom.xml
|
@ -35,7 +35,7 @@
|
|||
<dependency>
|
||||
<groupId>cn.hutool</groupId>
|
||||
<artifactId>hutool-all</artifactId>
|
||||
<version>5.8.18</version>
|
||||
<version>5.8.25</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
|
@ -46,6 +46,10 @@
|
|||
<build>
|
||||
<finalName>login</finalName>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.graalvm.buildtools</groupId>
|
||||
<artifactId>native-maven-plugin</artifactId>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-maven-plugin</artifactId>
|
||||
|
|
|
@ -0,0 +1,31 @@
|
|||
#-------------------------------------------------------------------------------#
|
||||
# Qodana analysis is configured by qodana.yaml file #
|
||||
# https://www.jetbrains.com/help/qodana/qodana-yaml.html #
|
||||
#-------------------------------------------------------------------------------#
|
||||
version: "1.0"
|
||||
|
||||
#Specify inspection profile for code analysis
|
||||
profile:
|
||||
name: qodana.starter
|
||||
|
||||
#Enable inspections
|
||||
#include:
|
||||
# - name: <SomeEnabledInspectionId>
|
||||
|
||||
#Disable inspections
|
||||
#exclude:
|
||||
# - name: <SomeDisabledInspectionId>
|
||||
# paths:
|
||||
# - <path/where/not/run/inspection>
|
||||
|
||||
projectJDK: 17 #(Applied in CI/CD pipeline)
|
||||
|
||||
#Execute shell command before Qodana execution (Applied in CI/CD pipeline)
|
||||
#bootstrap: sh ./prepare-qodana.sh
|
||||
|
||||
#Install IDE plugins before Qodana execution (Applied in CI/CD pipeline)
|
||||
#plugins:
|
||||
# - id: <plugin.id> #(plugin id can be found at https://plugins.jetbrains.com)
|
||||
|
||||
#Specify Qodana linter for analysis (Applied in CI/CD pipeline)
|
||||
linter: jetbrains/qodana-jvm:latest
|
|
@ -8,7 +8,7 @@ import org.springframework.web.bind.annotation.*;
|
|||
|
||||
@RequestMapping("/login")
|
||||
@RestController
|
||||
@CrossOrigin
|
||||
//@CrossOrigin
|
||||
public class LoginController {
|
||||
|
||||
@Resource
|
||||
|
@ -19,7 +19,7 @@ public class LoginController {
|
|||
* 获取签名
|
||||
* @param userDo 用户信息
|
||||
* @return 登录信息
|
||||
*/
|
||||
* */
|
||||
@PostMapping("/getSign")
|
||||
public LoginDo getSign(@RequestBody UserDo userDo){
|
||||
if(userDo == null || userDo.getName() == null || userDo.getPsd() == null){
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
<!DOCTYPE html><html><head><meta charset=utf-8><meta http-equiv=X-UA-Compatible content="IE=edge,chrome=1"><meta name=renderer content=webkit><meta name=viewport content="width=device-width,initial-scale=1,maximum-scale=1,user-scalable=no"><title>差旅费控云</title><link href=public/css/app.e9fd97b8.css rel=preload as=style><link href=public/css/chunk-libs.3dfb7769.css rel=preload as=style><link href=public/js/app.d0de374c.js rel=preload as=script><link href=public/js/chunk-elementUI.cf1c449f.js rel=preload as=script><link href=public/js/chunk-libs.7632cd70.js rel=preload as=script><link href=public/css/chunk-libs.3dfb7769.css rel=stylesheet><link href=public/css/app.e9fd97b8.css rel=stylesheet></head><body><div id=app></div><script>(function(e){function r(r){for(var n,l,i=r[0],a=r[1],f=r[2],c=0,s=[]; c<i.length; c++)l=i[c],Object.prototype.hasOwnProperty.call(o,l)&&o[l]&&s.push(o[l][0]),o[l]=0;for(n in a)Object.prototype.hasOwnProperty.call(a,n)&&(e[n]=a[n]);p&&p(r);while(s.length)s.shift()();return u.push.apply(u,f||[]),t()}function t(){for(var e,r=0; r<u.length; r++){for(var t=u[r],n=!0,i=1; i<t.length; i++){var a=t[i];0!==o[a]&&(n=!1)}n&&(u.splice(r--,1),e=l(l.s=t[0]))}return e}var n={},o={runtime:0},u=[];function l(r){if(n[r])return n[r].exports;var t=n[r]={i:r,l:!1,exports:{}};return e[r].call(t.exports,t,t.exports,l),t.l=!0,t.exports}l.m=e,l.c=n,l.d=function(e, r, t){l.o(e,r)||Object.defineProperty(e,r,{enumerable:!0,get:t})},l.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},l.t=function(e, r){if(1&r&&(e=l(e)),8&r)return e;if(4&r&&"object"===typeof e&&e&&e.__esModule)return e;var t=Object.create(null);if(l.r(t),Object.defineProperty(t,"default",{enumerable:!0,value:e}),2&r&&"string"!=typeof e)for(var n in e)l.d(t,n,function(r){return e[r]}.bind(null,n));return t},l.n=function(e){var r=e&&e.__esModule?function(){return e["default"]}:function(){return e};return l.d(r,"a",r),r},l.o=function(e, r){return Object.prototype.hasOwnProperty.call(e,r)},l.p="";var i=window["webpackJsonp"]=window["webpackJsonp"]||[],a=i.push.bind(i);i.push=r,i=i.slice();for(var f=0; f<i.length; f++)r(i[f]);var p=a;t()})([]);</script><script src=public/js/chunk-elementUI.cf1c449f.js></script><script src=public/js/chunk-libs.7632cd70.js></script><script src=public/js/app.d0de374c.js></script></body></html>
|
|
@ -4,7 +4,7 @@
|
|||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Login~</title>
|
||||
<link href="./js/daisyui.css" rel="stylesheet" type="text/css" />
|
||||
<link href="js/daisyui.css" rel="stylesheet" type="text/css" />
|
||||
<style>
|
||||
:root {
|
||||
/* COLORS */
|
||||
|
@ -96,7 +96,7 @@
|
|||
|
||||
.overlay {
|
||||
background-color: var(--lightblue);
|
||||
background: url("./assets/baidu_logo.png");
|
||||
background: url("assets/baidu_logo.png");
|
||||
background-attachment: fixed;
|
||||
background-position: center;
|
||||
background-repeat: no-repeat;
|
||||
|
@ -334,8 +334,8 @@
|
|||
|
||||
|
||||
</script>
|
||||
<script src="./js/jquery.js"></script>
|
||||
<script src="./js/axios.js"></script>
|
||||
<script src="js/jquery.js"></script>
|
||||
<script src="js/axios.js"></script>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -0,0 +1 @@
|
|||
{"type":"FeatureCollection","features":[{"id":"820001","type":"Feature","geometry":{"type":"MultiPolygon","coordinates":[["@@LADC^umZ@DONWE@DALBBF@H@DFBBTC"],["@@P@LC@AGM@OECMBABBTCD@DDH"]],"encodeOffsets":[[[116285,22746]],[[116303,22746]]]},"properties":{"cp":[113.552965,22.207882],"name":"花地玛堂区","childNum":2}},{"id":"820002","type":"Feature","geometry":{"type":"Polygon","coordinates":["@@MK@CA@AAGDEB@NVFJG"],"encodeOffsets":[[116281,22734]]},"properties":{"cp":[113.549052,22.199175],"name":"花王堂区","childNum":1}},{"id":"820003","type":"Feature","geometry":{"type":"Polygon","coordinates":["@@EGOB@DNLHE@C"],"encodeOffsets":[[116285,22729]]},"properties":{"cp":[113.550252,22.193791],"name":"望德堂区","childNum":1}},{"id":"820004","type":"Feature","geometry":{"type":"Polygon","coordinates":["@@YMVAN@BFCBBDAFHDBBFDHIJJEFDPCHHlYJQ"],"encodeOffsets":[[116313,22707]]},"properties":{"cp":[113.55374,22.188119],"name":"大堂区","childNum":1}},{"id":"820005","type":"Feature","geometry":{"type":"Polygon","coordinates":["@@JICGAECACGEBAAEDBFNXB@"],"encodeOffsets":[[116266,22728]]},"properties":{"cp":[113.54167,22.187778],"name":"风顺堂区","childNum":1}},{"id":"820006","type":"Feature","geometry":{"type":"Polygon","coordinates":["@@ ZNWRquZCBCC@AEA@@ADCDCAACEAGBQ@INEL"],"encodeOffsets":[[116265,22694]]},"properties":{"cp":[113.558783,22.154124],"name":"嘉模堂区","childNum":1}},{"id":"820007","type":"Feature","geometry":{"type":"Polygon","coordinates":["@@MOIAIEI@@GE@AAUCBdCFIFR@HAFBBDDBDCBC@@FB@BDDDA\\M"],"encodeOffsets":[[116316,22676]]},"properties":{"cp":[113.56925,22.136546],"name":"路凼填海区","childNum":1}},{"id":"820008","type":"Feature","geometry":{"type":"Polygon","coordinates":["@@DKMMa_GC_COD@dVDBBF@@HJ@JFJBNPZK"],"encodeOffsets":[[116329,22670]]},"properties":{"cp":[113.559954,22.124049],"name":"圣方济各堂区","childNum":1}}],"UTF8Encoding":true}
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -0,0 +1 @@
|
|||
/*! normalize.css v7.0.0 | MIT License | github.com/necolas/normalize.css */html{line-height:1.15;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}body{margin:0}article,aside,footer,header,nav,section{display:block}h1{font-size:2em;margin:.67em 0}figcaption,figure,main{display:block}figure{margin:1em 40px}hr{-webkit-box-sizing:content-box;box-sizing:content-box;height:0;overflow:visible}pre{font-family:monospace,monospace;font-size:1em}a{background-color:transparent;-webkit-text-decoration-skip:objects}abbr[title]{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted}b,strong{font-weight:inherit;font-weight:bolder}code,kbd,samp{font-family:monospace,monospace;font-size:1em}dfn{font-style:italic}mark{background-color:#ff0;color:#000}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}audio,video{display:inline-block}audio:not([controls]){display:none;height:0}img{border-style:none}svg:not(:root){overflow:hidden}button,input,optgroup,select,textarea{font-family:sans-serif;font-size:100%;line-height:1.15;margin:0}button,input{overflow:visible}button,select{text-transform:none}[type=reset],[type=submit],button,html [type=button]{-webkit-appearance:button}[type=button]::-moz-focus-inner,[type=reset]::-moz-focus-inner,[type=submit]::-moz-focus-inner,button::-moz-focus-inner{border-style:none;padding:0}[type=button]:-moz-focusring,[type=reset]:-moz-focusring,[type=submit]:-moz-focusring,button:-moz-focusring{outline:1px dotted ButtonText}fieldset{padding:.35em .75em .625em}legend{-webkit-box-sizing:border-box;box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal}progress{display:inline-block;vertical-align:baseline}textarea{overflow:auto}[type=checkbox],[type=radio]{-webkit-box-sizing:border-box;box-sizing:border-box;padding:0}[type=number]::-webkit-inner-spin-button,[type=number]::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}[type=search]::-webkit-search-cancel-button,[type=search]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}details,menu{display:block}summary{display:list-item}canvas{display:inline-block}[hidden],template{display:none}#nprogress{pointer-events:none}#nprogress .bar{background:#29d;position:fixed;z-index:1031;top:0;left:0;width:100%;height:2px}#nprogress .peg{display:block;position:absolute;right:0;width:100px;height:100%;-webkit-box-shadow:0 0 10px #29d,0 0 5px #29d;box-shadow:0 0 10px #29d,0 0 5px #29d;opacity:1;-webkit-transform:rotate(3deg) translateY(-4px);transform:rotate(3deg) translateY(-4px)}#nprogress .spinner{display:block;position:fixed;z-index:1031;top:15px;right:15px}#nprogress .spinner-icon{width:18px;height:18px;-webkit-box-sizing:border-box;box-sizing:border-box;border:2px solid transparent;border-top-color:#29d;border-left-color:#29d;border-radius:50%;-webkit-animation:nprogress-spinner .4s linear infinite;animation:nprogress-spinner .4s linear infinite}.nprogress-custom-parent{overflow:hidden;position:relative}.nprogress-custom-parent #nprogress .bar,.nprogress-custom-parent #nprogress .spinner{position:absolute}@-webkit-keyframes nprogress-spinner{0%{-webkit-transform:rotate(0deg)}to{-webkit-transform:rotate(1turn)}}@keyframes nprogress-spinner{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
After Width: | Height: | Size: 160 KiB |
Binary file not shown.
After Width: | Height: | Size: 96 KiB |
Binary file not shown.
After Width: | Height: | Size: 4.7 KiB |
Binary file not shown.
After Width: | Height: | Size: 5.4 KiB |
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -0,0 +1,16 @@
|
|||
@startuml
|
||||
actor 用户 as user #A9A9A9
|
||||
control 业务系统 as sys #A9A9A9
|
||||
control 单点登录系统 as sso #A9A9A9
|
||||
database redis as redis #A9A9A9
|
||||
|
||||
|
||||
|
||||
user -> sys: 登出
|
||||
sys -> sys: 获取保存的Token
|
||||
sys -> sso: 通知sso登出
|
||||
sso -> redis: 删除登录信息
|
||||
sso -> sys: 返回成功
|
||||
sys -> user: 返回登录
|
||||
|
||||
@enduml
|
|
@ -0,0 +1,27 @@
|
|||
@startuml
|
||||
actor 用户 as user #A9A9A9
|
||||
control 业务系统 as sys #A9A9A9
|
||||
control 单点登录系统 as sso #A9A9A9
|
||||
database redis as redis #A9A9A9
|
||||
|
||||
|
||||
|
||||
user -> sys: 访问需要登录的业务系统功能
|
||||
sys -> sys: 获取保存的Token
|
||||
sys -> sso: 获取登录状态
|
||||
sso -> redis: 获取登录状态
|
||||
|
||||
group 登录情况
|
||||
redis -> sso: 返回登录信息
|
||||
sso -> sys: 返回登录信息
|
||||
sys -> user: 允许访问
|
||||
end
|
||||
|
||||
group 未登录情况
|
||||
redis -> sso: 返回用户未登录
|
||||
sso -> sys: 返回用户未登录
|
||||
sys -> user: 返回用户未登录
|
||||
user -> user: 登录
|
||||
end
|
||||
|
||||
@enduml
|
|
@ -0,0 +1,21 @@
|
|||
@startuml
|
||||
|
||||
|
||||
actor 用户 as user #A9A9A9
|
||||
control 业务系统 as sys #A9A9A9
|
||||
control 单点登录系统 as sso #A9A9A9
|
||||
database redis as redis #A9A9A9
|
||||
database 数据库 as DB #A9A9A9
|
||||
|
||||
user -> sys: 用户登录
|
||||
sys -> sso: 调用单点登录系统
|
||||
sso -> redis: 查询用户信息
|
||||
sso -> DB: 查询用户信息
|
||||
DB -> sso: 返回用户信息
|
||||
sso -> redis: 缓存用户信息
|
||||
sso -> sys: 返回结果
|
||||
sys -> user: 返回结果
|
||||
|
||||
|
||||
|
||||
@enduml
|
|
@ -0,0 +1,21 @@
|
|||
@startuml
|
||||
!theme cerulean-outline
|
||||
|
||||
control 业务系统 as sys
|
||||
control 单点登录系统 as sso
|
||||
|
||||
activate sys
|
||||
activate sso
|
||||
|
||||
sys -> sso: 发起请求
|
||||
sso -> sys: 返回加密公钥
|
||||
sys -> sys: 生成随机数
|
||||
sys -> sso: 通过公钥加密随机数
|
||||
sso -> sso: 通过私钥解密随机数
|
||||
sso -> sys: 通过随机数进行对称加密
|
||||
|
||||
sys -> sso: 通过随机数进行加解密
|
||||
|
||||
|
||||
|
||||
@enduml
|
|
@ -0,0 +1,43 @@
|
|||
@startuml
|
||||
!theme cerulean-outline
|
||||
|
||||
actor 用户 as user
|
||||
control 业务系统 as sys
|
||||
control 业务系统2 as sys2
|
||||
control 单点登录系统 as sso
|
||||
|
||||
|
||||
user -> sys: 访问业务页面
|
||||
activate user
|
||||
activate sys
|
||||
|
||||
sys -> sys: Token不存在
|
||||
sys -> user: 重定向到登录界面
|
||||
user -> sys: ID+PW+验证码
|
||||
|
||||
|
||||
|
||||
sys <-> sso: 加解密操作
|
||||
activate sso
|
||||
|
||||
sys -> sso : ID+PW+验证码+用户信息+Time
|
||||
|
||||
sso -> sso: 验证登录信息
|
||||
sso -> sso: 创建Token
|
||||
sso -> sys: 返回Token和用户TEL
|
||||
deactivate sso
|
||||
|
||||
sys -> sys: 登录
|
||||
sys -> user: 重定向到业务页面
|
||||
deactivate sys
|
||||
|
||||
|
||||
user -> sys2: 访问系统2
|
||||
activate sys2
|
||||
sys2 -> sys2: 执行上述流程
|
||||
sys2 -> user: 重定向到业务页面
|
||||
deactivate sys2
|
||||
|
||||
deactivate user
|
||||
|
||||
@enduml
|
Loading…
Reference in New Issue