This tool creates a table report to verify access control on Spring Boot routes.
It uses the Preauthorize
, Secured
or RolesAllowed
annotation from spring-security-config
It creates a table.html file with a list of your routes and their preauthorize.
Clone the repository:
git clone [email protected]:marine-mb/spring-access-inspector.git
Go inside the repo:
cd spring-access-inspector
Compile the code:
mvn compile exec:java -Dexec.mainClass=com.theodo.tools.preauthorize.analyzer.PreAuthorizeAnalysis
Run the code (using maven exec plugin) and give it your pom path:
mvn exec:java -Dexec.mainClass=com.theodo.tools.preauthorize.analyzer.PreAuthorizeAnalysis -Dexec.args="/the_path/where/poms/are"
N.B: Compile your code before:
mvn clean install -DskipTests