Giter VIP home page Giter VIP logo

spring-oauth2-jwt's Introduction

spring-oauth2-jwt

This project is an exemple of Spring + Spring Security + OAuth2 using JWT Token focous in microservice.

authorizationServer

Is responsable to manager user, auth and manager the Token.The project will run on 8080 Every time the aplication start creates two users:

  • user witch password 1q2w3e and role USER
  • admin witch password 1q2w3e and rolse ADMIN
curl -X POST -u my-trusted-client:secret "http://localhost:8080/oauth/token?grant_type=password&username=user&password=1q2w3e"

resourceServer

Is responsible to response for API endpoint, and the only will do this if the user is auth. The project will run on 8081 and havce two endpoint\

curl -H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJyb2xlIjoiUk9MRV9VU0VSIiwidXNlcl9uYW1lIjoidGFkZXVjcnV6Iiwic2NvcGUiOlsicmVhZCIsIndyaXRlIl0sImV4cCI6MTQ5NTcwNTEyOCwidXVpZCI6ImUwZjNjOGM4LThmNzMtNDkzNS1hYjY3LWUxMDRhNjkyNzg2YyIsImF1dGhvcml0aWVzIjpbIlJPTEVfVVNFUiJdLCJqdGkiOiJjY2M0MTJiMi05ZTQ0LTQzODktOWIwMS01YzRjODRhYzRmNjUiLCJjbGllbnRfaWQiOiJteS10cnVzdGVkLWNsaWVudCJ9.65kTz4Omiy1a1RTgAoEtGKcidh9VUeqoM3wskHdw4sc" http://localhost:8081/endpointuser

TODO:

  • Use RSA Key for JWT

References

spring-oauth2-jwt's People

Contributors

tadeucruz avatar

Stargazers

惊风529 avatar Timothy Olisaeloka Ngonadi avatar Rodolfo Ricardo Sirpa Calderón avatar  avatar Przemek Broda avatar Sangkyun Yoon avatar Meghan McCormick avatar Micro avatar  avatar Melon avatar  avatar Yi Li avatar Paweł Tymczuk avatar hanfeng avatar Bruno Machado avatar

Watchers

James Cloos avatar Micro avatar  avatar André Krebs avatar  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.