Skip to content

ryokotmng/oauth-in-action-code-go

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

34 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

OAuth in Action in Go

This repository is my try to translate OAuth 2 in Action source code into Go.

Cover of OAuth 2 in Action

https://www.manning.com/books/oauth-2-in-action

Requirement

  • Go 1.17

Libraries

  • WAF: Gin
  • DB: Redis
  • Others:
    • oauth2
      • NOTE: To understand detailed internal implementation, this repository does not use some useful features of this package

Tools

  • File Watcher: Air

Execute 'make install-tools' at the root directory to install necessary tools.

Setup

Install useful tools

$ make install-tools

Start up redis

$ make start-redis

How to Use

The folder structure is quite similar to OAuth 2 in Action, but the entry points for authorization, client and protected resource servers are under each folder.
You should execute 'air' of 'go run main.go' command under each folder in cmd.

Ports are all same with the original repository, except for redis which replace over nosql.

server port
authorization 9001
client 9000
protected resource 9002
redis 6379

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

Packages

Used by

Contributors

Languages