Ciao a tutti,
Sto leggendo questo programma in spring boot security:
github.com
e ci sono alcuni codici che non comprendo. In particolare in application.properties trovo scritto:
L'autore scrive nel suo testo (riporto testuali parole):
grazie
Sto leggendo questo programma in spring boot security:
beg-spring-boot-2/chapter-13/springboot-thymeleaf-security-demo at master · Apress/beg-spring-boot-2
Source code for 'Beginning Spring Boot 2' by K. Siva Prasad Reddy - Apress/beg-spring-boot-2
Codice:
security.user.name=admin
security.user.password=secret
security.user.role=USER,ADMIN
Sapreste dirmi come far comparire la richiesta delle credenziali dell'utente su IntelliJ?Now if you run the application and access http://localhost:8080, you will be prompted to enter the
user credentials. The default user is user and the password is auto-generated. You can find it in the console log.
Using default security password: 78fa095d-3f4c-48b1-ad50-e24c31d5cf35
You can change the default user credentials in application.properties as follows:
security.user.name=admin
security.user.password=secret
security.user.role=USER,ADMIN
Okay, that’s nice for a quick demo. But in your actual projects, you may want to implement role-based
access control using a persistence datastore such as a database. Also, you might want to fine-tune the access
to resources (URLs, service layer methods, etc.) based on roles. Now you’ll see how to customize the default
Spring Security autoconfiguration to meet your needs.
First, you’ll create the database tables shown in Figure 13-1 to store users and roles.
grazie