Question 1
In Spring Security, form-based authentication typically presents:
A JSON API
An HTML login form
An XML request
A command-line prompt
Question 2
Which Spring Security method enables form-based authentication?
http.formAuth()
http.formLogin()
http.loginForm()
http.formBased()
Question 3
In JDBC Authentication, user credentials are usually stored in:
A JSON file
An XML file
A relational database
In-memory storage
Question 4
Which method is used in Spring Security to configure JDBC Authentication?
auth.inMemoryAuthentication()
auth.jdbcAuthentication()
auth.dbAuth()
auth.dataSourceAuthentication()
Question 5
In JDBC Authentication, which table stores the user’s roles or authorities by default?
users
authorities
roles
user_roles
Question 6
During form-based authentication, if login fails, Spring Security:
Redirects to /error
Redirects to /login?error
Returns 401 Unauthorized
Reloads the homepage
Question 7
In a typical registration process, the password should be stored:
As plain text
Base64 encoded
Hashed using a password encoder
In a session variable
Question 8
Which Spring Security interface is responsible for loading user details from the database?
UserRepository
UserDetailsService
AuthenticationManager
PasswordEncoder
Question 9
Which method in form-based authentication specifies the default success page after login?
.defaultSuccessUrl("/home")
.loginSuccess("/home")
.redirectHome()
.setHomePage("/home")
There are 9 questions to complete.