ba1ba8455d
* Added parent module on poms that have no parent defined * Removed dependency reduced pom from undertow module * Defined the integration profile in the parent * 21.02 - pom cleanup * 21.02 - pom cleanup * 21.02 - pom cleanup * 21.02 - pom cleanup * Spring-dependency injection * BAEL-1683-Guide to Java Clock class * BAEL-1683-Guide to Java Clock class * added article link * added article link * fixed link * refactoring packages and using generics * BAEL-717: Singleton Session Bean. (#4046) * BAEL-717: Singleton EJB Bean Files for BAEL-717:Singleton EJB Bean. * BAEL-717: Singleton EJB Bean Corrected Indentation. * BAEL-717: Singleton EJB Bean Corrected Indentation. * BAEL-717: Singleton EJB Bean Corrected Indentation. * BAEL-717: Singleton EJB Bean Corrected Indentation. * BAEL-717: Singleton EJB Bean Changed artifactId value. * BAEL-717: Singleton EJB Bean. Added module for Singleton EJB Bean. * BAEL-717: Singleton EJB Bean. Removed Singleton EJB Bean Module. * BAEL-717: Singleton EJB Bean Changed the JNDI Lookup name. * BAEL-717: Singleton EJB Bean. Added the "singleton-ejb-bean" module. * BAEL-717: Singleton EJB Bean. Corrected Indentation. * BAEL-717: Singleton EJB Bean Corrected Indentation. * BAEL-717: Singleton EJB Bean. Corrected Indentation. * BAEL-717: Singleton EJB Bean. Corrected Indentation. * BAEL-717:Singleton EJB Bean. Corrected Indentation. * BAEL-717:Singleton EJB Bean. Corrected Indentation. * BAEL-717: Singleton Session Bean. Added class for Bean-Managed concurrrency. Changed class name from CountryStateCacheBean to CountryStateContainerManagedBean. * BAEL-717: Singleton Session Bean. Changing the name of the class to CountryStateContainerManagedBean. * BAEL-717: Singleton Session Bean. Added method to test Bean-Managed concurrency. * Get Latest. * deleting CountryStateBeanManagedBean for new file. * deleting CountryStateCacheBean for new file. * deleting CountryStateContainerManagedBean for new file. * BAEL-717: Singleton Session Bean. Adding file for Bean with Bean-Managed concurrency. Changing file name for original file to CountryStateContainerManagedBean with Container-Managed concurrency. * Deleting file for new checkin. * BAEL-717: Singleton Session Bean. Added test case for Bean-Manged concurrency. Change in JNDI names. * BAEL-717: Singleton Session Bean. Changed the assert method parameter order and null check in test cases. * BAEL-717:Singleton Session Bean Removed volatile keyword for the variable countryStatesMap. Marking it as final. * [BAEL-1641] Find all pairs of numbers in an array that add up to a given sum (#3890) * [BAEL-1641] Find all pairs of numbers in an array that add up to a given sum * Commiting editor's suggested changes * Commiting article Spring Data Reactive Mongo DB microservice in Kotlin * Revert commit for BAEL 1687 - Moving those files to a new branch * Use AssertJ and BDD-style on unit testing * BAEL 1639: added singleton examples and test. (#3977) * BAEL-1701 (#4012) * BAEL-1701: Create SQSApplication, add most functionality (still need to format, and add queue monitoring) * BAEL-1701: Complete examples * added article links * removed folder "SpringDependencyInjection" e Please enter the commit message for your changes. Lines starting * BAEL-1706 - optional parameters in java (#4050) * BAEL-1706 - optional parameters in java * minor adjustments per review * add tests * fix formatting * fix constructor issue with MultiVitaminOverloading * BAEL-1706 Test name change, formatting * working with booleans in thymeleaf (#4061) * BAEL-1725 Java Pass-by-reference vs Pass-by-value - First commit (#4058) * BAEL-1725 Java Pass-by-reference vs Pass-by-value - First commit * updated test cases * Update README.md * Demonstration of Java assert * BAEL-1679 (#3959) * BAEL-1412 add java 8 spring data features * BAEL-21 new HTTP API overview * BAEL-21 fix executor * BAEL-1432 add custom gradle task * BAEL-1567 add samples of cookie and session in serlvet * BAEL-1567 use stream api * BAEL-1567 fix optional * BAEL-1679 add query annotation jpa spring data * BAEL-1679 added new junits * BAEL-1679 use assertJ, use givenWhenThen naming convention * 21.02 - pom cleanup * 21.02 - pom cleanup * 21.02 - pom cleanup * spring-data final * service locator pattern * service locator pattern * variable name changes * Spring MVC @PathVariable dot (.) get truncated * testing changes * Update README files (#4065) * BAEL-1612: Update README * BAEL-1562: Update README * BAEL-1562: Update README * BAEL-1369 * BAEL-1369 * BAEL-1369 * remove comments * Back-link corrected (#4071) * Back-link corrected (#4073) * Back-link added (#4074) * Back-link added (#4075) * Back-link added (#4076) * Back-link added (#4077) * Back-link added (#4078) * Back-link added (#4080) * Back-link added (#4081) * Back-link added (#4083) * Back-link corrected (#4086) * Back-link added (#4087) * Back-link added (#4091) * Back-link added (#4089) * added example code for Java mail (#4101) * Back-link added (#4099) * Back-link added (#4088) * Back-link added (#4082) * 21.02 - pom cleanup * 21.02 - pom cleanup * 21.02 - pom cleanup * 21.02 - pom cleanup |
||
---|---|---|
.. | ||
src | ||
.gitignore | ||
README.md | ||
pom.xml |
README.md
JWT Fun
This tutorial walks you through the various features supported by the JJWT library - a fluent interface Java JWT building and parsing library.
Build and Run
It's super easy to build and exercise this tutorial.
mvn clean install
java -jar target/*.jar
That's it!
You can hit the home endpoint with your favorite command-line http client. My favorite is: httpie
http localhost:8080
Available commands (assumes httpie - https://github.com/jkbrzt/httpie):
http http://localhost:8080/
This usage message
http http://localhost:8080/static-builder
build JWT from hardcoded claims
http POST http://localhost:8080/dynamic-builder-general claim-1=value-1 ... [claim-n=value-n]
build JWT from passed in claims (using general claims map)
http POST http://localhost:8080/dynamic-builder-specific claim-1=value-1 ... [claim-n=value-n]
build JWT from passed in claims (using specific claims methods)
http POST http://localhost:8080/dynamic-builder-compress claim-1=value-1 ... [claim-n=value-n]
build DEFLATE compressed JWT from passed in claims
http http://localhost:8080/parser?jwt=<jwt>
Parse passed in JWT
http http://localhost:8080/parser-enforce?jwt=<jwt>
Parse passed in JWT enforcing the 'iss' registered claim and the 'hasMotorcycle' custom claim
The Baeldung post that compliments this repo can be found here