GithubHelp home page GithubHelp logo

yapi-plugin-cas's Introduction

yapi-plugin-cas

第三方cas登录插件,配置方法如下:

第一步: 在生成的配置文件config.json中加入如下配置:

"plugins": [
  {
    "name": "cas",
    "options": {
      "type": "cas",
      "LOGIN_SERVER": "http://cas.example.com/cas/login",
      "AUTH_SERVER" : "https://cas.example.com/cas/serviceValidate",
      "emailPostfix": "@163.com",
    }
  }
]

这里面的配置项含义如下:

  • type 登陆类型,目前只支持cas登陆
  • loginUrl 服务端在获取token之后,可以通过这个url来获取用户的详细信息
  • emailPostfix 登陆邮箱后缀
  • AUTH_SERVER 点击登陆按钮式需要跳转的url,用户通过该页面登录以后会向服务器发送一个token 第二步:在config.json 这层目录下运行 yapi plugin --name yapi-plugin-cas 重新下载插件

第三步: 重启服务器

yapi-plugin-cas's People

Contributors

angrytoro avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.