mirror of
https://github.com/dbeaver/cloudbeaver.git
synced 2026-09-24 16:04:36 +08:00
Merge remote-tracking branch 'origin/devel' into feature/CB-2127
This commit is contained in:
+4
-1
@@ -821,7 +821,10 @@ public class WebSession extends AbstractSessionPersistent implements SMSession,
|
||||
if (providerId == null) {
|
||||
clearAuthTokens();
|
||||
} else {
|
||||
removeAuthInfo(getAuthInfo(providerId));
|
||||
WebAuthInfo authInfo = getAuthInfo(providerId);
|
||||
if (authInfo != null) {
|
||||
removeAuthInfo(authInfo);
|
||||
}
|
||||
}
|
||||
if (authTokens.isEmpty()) {
|
||||
resetUserState();
|
||||
|
||||
+8
-1
@@ -359,7 +359,7 @@ public class CBEmbeddedSecurityController implements SMAdminController, SMAuthen
|
||||
///////////////////////////////////////////
|
||||
// Credentials
|
||||
|
||||
private static SMAuthCredentialsProfile getCredentialProfileByParameters(SMAuthProviderDescriptor authProvider, Set<String> keySet) {
|
||||
private static SMAuthCredentialsProfile getCredentialProfileByParameters(AuthProviderDescriptor authProvider, Set<String> keySet) {
|
||||
List<SMAuthCredentialsProfile> credentialProfiles = authProvider.getCredentialProfiles();
|
||||
if (credentialProfiles.size() > 1) {
|
||||
for (SMAuthCredentialsProfile profile : credentialProfiles) {
|
||||
@@ -1218,6 +1218,13 @@ public class CBEmbeddedSecurityController implements SMAdminController, SMAuthen
|
||||
return new SMAuthPermissions(userId, sessionId, permissions);
|
||||
}
|
||||
|
||||
@Override
|
||||
public SMAuthProviderDescriptor[] getAvailableAuthProviders() {
|
||||
return AuthProviderRegistry.getInstance().getAuthProviders().stream()
|
||||
.filter(ap -> !ap.isTrusted())
|
||||
.map(AuthProviderDescriptor::createDescriptorBean).toArray(SMAuthProviderDescriptor[]::new);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void updateSession(@NotNull String sessionId, @Nullable String userId, @NotNull Map<String, Object> parameters) throws DBCException {
|
||||
try (Connection dbCon = database.openConnection()) {
|
||||
|
||||
Reference in New Issue
Block a user