• 大小: 69KB
    文件类型: .zip
    金币: 1
    下载: 0 次
    发布日期: 2021-05-28
  • 语言: 其他
  • 标签: Java  JWT  SSO  

资源简介

基于JWT实现的单点登录系统,使用idea开发的,可以供学习参考,有什么问题可以咨询

资源截图

代码片段和文件信息

package com.imooc.sso.client;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.security.oauth2.client.EnableOAuth2Sso;
import org.springframework.security.core.Authentication;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author yangye
 * @date 2018/1/31
 */
@SpringBootApplication
@RestController
@EnableOAuth2Sso
public class SsoClient1Application {

    @GetMapping(“/user“)
    public Authentication user(Authentication user) {
        return user;
    }

    public static void main(String[] args) {
        SpringApplication.run(SsoClient1Application.classargs);
    }
}

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2018-01-31 11:39  JWTSSO\
     目录           0  2018-01-31 15:37  JWTSSO\.idea\
     文件         887  2018-01-31 11:40  JWTSSO\.idea\compiler.xml
     目录           0  2018-01-31 11:36  JWTSSO\.idea\inspectionProfiles\
     文件        1444  2018-01-31 11:36  JWTSSO\.idea\inspectionProfiles\Project_Default.xml
     目录           0  2018-01-31 11:45  JWTSSO\.idea\libraries\
     文件         502  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__aopalliance_aopalliance_1_0.xml
     文件         563  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__ch_qos_logback_logback_classic_1_1_11.xml
     文件         542  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__ch_qos_logback_logback_core_1_1_11.xml
     文件         510  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__com_fasterxml_classmate_1_3_3.xml
     文件         632  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__com_fasterxml_jackson_core_jackson_annotations_2_8_0.xml
     文件         583  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__com_fasterxml_jackson_core_jackson_core_2_8_9.xml
     文件         611  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__com_fasterxml_jackson_core_jackson_databind_2_8_9.xml
     文件         531  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__commons_codec_commons_codec_1_10.xml
     文件         599  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__javax_validation_validation_api_1_1_0_Final.xml
     文件         613  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__org_apache_tomcat_embed_tomcat_embed_core_8_5_16.xml
     文件         599  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__org_apache_tomcat_embed_tomcat_embed_el_8_5_16.xml
     文件         648  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__org_apache_tomcat_embed_tomcat_embed_websocket_8_5_16.xml
     文件         550  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__org_bouncycastle_bcpkix_jdk15on_1_56.xml
     文件         550  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__org_bouncycastle_bcprov_jdk15on_1_56.xml
     文件         594  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__org_codehaus_jackson_jackson_core_asl_1_9_13.xml
     文件         608  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__org_codehaus_jackson_jackson_mapper_asl_1_9_13.xml
     文件         622  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__org_hibernate_hibernate_validator_5_3_5_Final.xml
     文件         596  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__org_jboss_logging_jboss_logging_3_3_1_Final.xml
     文件         536  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__org_slf4j_jcl_over_slf4j_1_7_25.xml
     文件         522  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__org_slf4j_jul_to_slf4j_1_7_25.xml
     文件         550  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__org_slf4j_log4j_over_slf4j_1_7_25.xml
     文件         501  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__org_slf4j_slf4j_api_1_7_25.xml
     文件         624  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__org_springframework_boot_spring_boot_1_5_6_RELEASE.xml
     文件         722  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__org_springframework_boot_spring_boot_autoconfigure_1_5_6_RELEASE.xml
     文件         680  2018-01-31 11:45  JWTSSO\.idea\libraries\Maven__org_springframework_boot_spring_boot_starter_1_5_6_RELEASE.xml
............此处省略124个文件信息

评论

共有 条评论