Skip to content

Latest commit

 

History

68 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This demo secures a Jooby application with jooby-pac4j, the Jooby implementation of pac4j, the security engine for Java. If it is useful to you, please ⭐ star pac4j on GitHub: it helps other developers discover it!

A minimal Jooby (Netty) demo showcasing authentication with jooby-pac4j and pac4j:

  • Form login (FormClient)
  • Indirect Basic Auth (IndirectBasicAuthClient)
  • CAS (CasClient)

It uses Jooby v4.x (jooby-pac4j) and pac4j v6.x.

Prerequisites

  • JDK 21+
  • Maven 3.8+
  • curl (for the CAS test script)

Build

mvn -q clean package

Run

  • Quick launcher (builds and starts the demo):
./run.sh
  • Or run the fat JAR directly:
java -jar target/jooby-pac4j-demo-*.jar

The server starts on http://localhost:8080

Endpoints

  • / — Home page with links
  • /form/index — Protected by FormClient (use username = password)
  • /basicauth/index — Protected by Indirect Basic Auth (use username = password)
  • /cas/index — Protected by CAS (redirects to the demo CAS server)
  • /logout — Local logout via pac4j

About

Jooby webapp demo to test the jooby-pac4j security module

Topics

Resources

Stars

5 stars

Watchers

2 watching

Forks

Releases

Packages

Used by

Contributors

Languages