File tree 1 file changed +5
-0
lines changed
api/src/main/java/io/kafbat/ui/config/auth
1 file changed +5
-0
lines changed Original file line number Diff line number Diff line change 12
12
import java .util .stream .Stream ;
13
13
import lombok .RequiredArgsConstructor ;
14
14
import lombok .extern .slf4j .Slf4j ;
15
+ import org .apache .commons .lang3 .StringUtils ;
15
16
import org .springframework .beans .factory .annotation .Autowired ;
16
17
import org .springframework .boot .autoconfigure .condition .ConditionalOnProperty ;
17
18
import org .springframework .boot .context .properties .EnableConfigurationProperties ;
@@ -163,6 +164,10 @@ public SecurityWebFilterChain configureLdap(ServerHttpSecurity http) {
163
164
}
164
165
165
166
private ActiveDirectoryLdapAuthenticationProvider activeDirectoryProvider (LdapAuthoritiesPopulator populator ) {
167
+ if (StringUtils .isBlank (props .getActiveDirectoryDomain ())) {
168
+ throw new IllegalArgumentException ("Active Directory domain is required but not specified" );
169
+ }
170
+
166
171
ActiveDirectoryLdapAuthenticationProvider provider = new ActiveDirectoryLdapAuthenticationProvider (
167
172
props .getActiveDirectoryDomain (),
168
173
props .getUrls ()
You can’t perform that action at this time.
0 commit comments