Skip to main content

OAuth2 for GitHub

Project description

这是基于 picbed 的一个小的扩展模块, 用来接入 GitHub OAuth2 登录。

安装

  • 正式版本

    $ pip install -U picbed-oauth2-github

  • 开发版本

    $ pip install -U git+https://github.com/staugur/picbed-oauth2-github.git@master

开始使用

此扩展请在部署 picbed 图床后使用,需要 其管理员进行添加扩展、设置钩子等操作。

添加:

请在 站点管理-钩子扩展 中点击安装第三方包,可在弹窗列表中选择 picbed-oauth2-github,点击行尾图标,或者在弹窗底部按照正式/开发版本填写安装。

安装完成后,在 站点管理-钩子扩展 中点击添加第三方钩子, 输入名称: oauth2gh ,确认后提交即可加载这个模块。

配置:

站点管理-网站设置 底部的钩子配置区域配置GitHub OAuth ID和 GitHub OAuth Secret!

使用:

1、在GitHub中 注册一个OAuth App

Authorization callback URL是picbed地址,比如http://demo.picbed.pro

其他参数根据实际填写。

提交后生成的Client ID和Client Secret是需要配置到picbed中的。

2、在picbed 站点管理-网站设置 底部钩子配置区域中选择第三方认证为 oauth2gh即可。

启用后,在登录页面会显示使用GitHub登录,跳转到授权页,授权后跳回picbed。

PS:

  • 登录状态是依靠session

  • 用户名有 gh- 前缀

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

picbed-oauth2-github-0.1.0.tar.gz (3.7 kB view details)

Uploaded Source

Built Distribution

picbed_oauth2_github-0.1.0-py2-none-any.whl (4.8 kB view details)

Uploaded Python 2

File details

Details for the file picbed-oauth2-github-0.1.0.tar.gz.

File metadata

  • Download URL: picbed-oauth2-github-0.1.0.tar.gz
  • Upload date:
  • Size: 3.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.4.2 requests/2.22.0 setuptools/44.1.1 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/2.7.15+

File hashes

Hashes for picbed-oauth2-github-0.1.0.tar.gz
Algorithm Hash digest
SHA256 48c554c7bed4d3aa62c810ded1a404c164206140d58d0679fc8722e426e8c840
MD5 a71df3e7a94f3da2110afb36824dac25
BLAKE2b-256 4d15d84317fbc5d801b6c12db91ef95502267303c5a735a6c55838a769fda9e6

See more details on using hashes here.

File details

Details for the file picbed_oauth2_github-0.1.0-py2-none-any.whl.

File metadata

  • Download URL: picbed_oauth2_github-0.1.0-py2-none-any.whl
  • Upload date:
  • Size: 4.8 kB
  • Tags: Python 2
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.4.2 requests/2.22.0 setuptools/44.1.1 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/2.7.15+

File hashes

Hashes for picbed_oauth2_github-0.1.0-py2-none-any.whl
Algorithm Hash digest
SHA256 78e70f757a26d2affcedace7c57652281e54cd68c4d146a7a233b9de83cdcd2e
MD5 db996d10d66c956181fd913da1d712f2
BLAKE2b-256 07a3b1649dbc1bd25b88cbdbb56dcdb3eb76e4793fb6b8440da73cbe5d993480

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page