Performance: Form-based login configuration
MEDIUM IMPACT
This affects the initial page load speed and interaction responsiveness during user login.
http
.authorizeHttpRequests(auth -> auth.anyRequest().authenticated())
.formLogin(form -> form
.loginPage("/custom-login")
.permitAll()
.defaultSuccessUrl("/home", true))
.csrf(csrf -> csrf.enable());http
.authorizeHttpRequests(auth -> auth.anyRequest().authenticated())
.formLogin(form -> form.loginPage("/custom-login"))
.csrf(csrf -> csrf.disable());| Pattern | DOM Operations | Reflows | Paint Cost | Verdict |
|---|---|---|---|---|
| Simple form with minimal fields | Low (few nodes) | 1 reflow on load | Low paint cost | [OK] Good |
| Complex form with many inputs and scripts | High (many nodes) | Multiple reflows on input | High paint cost | [X] Bad |