Skip to content

scratches/sparklr-boot

This branch is 6 commits ahead of 2325407504/sparklr-boot:master.

Folders and files

NameName
Last commit message
Last commit date

Latest commit

author
Dave Syer
Mar 13, 2014
869c24b · Mar 13, 2014

History

20 Commits
Mar 13, 2014
Oct 9, 2013
Mar 13, 2014
Mar 12, 2014

Repository files navigation

This project is a minimal but functional OAuth2 Authorization Server (token issuer) and Resource Server (protected API). (You could split the two roles across two applications if you preferred.) It uses Spring Boot to provide an embedded servlet container and for defaulting a load of configuration, so you should be up and running with it very quickly. There are integration tests proving that it works and also showing you how to access it with the Spring RestTemplate API.

Building

You need Java (1.7 or better) and Maven (3.0.5 or better):

$ mvn package
$ java -jar target/*.jar
...
<app starts and listens on port 8080>

Here are some curl commands to use to get started:

$ curl -H "Accept: application/json" my-client-with-secret:secret@localhost:8080/oauth/token -d grant_type=client_credentials
{... "access_token": "b561ff06-4259-466e-92d8-781db1a51901", ...}
$ TOKEN=b561ff06-4259-466e-92d8-781db1a5190
$ curl -H "Authorization: Bearer $TOKEN" localhost:8080/
Hello World

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published