Skip to content
5 changes: 5 additions & 0 deletions server/bundles/io.cloudbeaver.model/plugin.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,11 @@
label="Default secret controller" description="Default void secret controller"/>
</extension>

<extension point="io.cloudbeaver.feature">
<feature id="ssh" label="SSH tunnels for databases" description="Enables SSH tunnels for secure database connections, allowing access to remote databases through encrypted channels" enabledByDefault="true"/>
</extension>


<extension point="org.jkiss.dbeaver.ws.event">
<event topicId="cb_session_task" id="cb_session_task_info_updated"
class="io.cloudbeaver.websocket.event.task.WSSessionTaskInfoEvent"/>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* DBeaver - Universal Database Manager
* Copyright (C) 2010-2024 DBeaver Corp and others
* Copyright (C) 2010-2026 DBeaver Corp and others
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand All @@ -17,6 +17,7 @@
package io.cloudbeaver.model.session;

import io.cloudbeaver.WebSessionProjectImpl;
import io.cloudbeaver.utils.ServletAppUtils;
import org.jkiss.code.NotNull;
import org.jkiss.code.Nullable;
import org.jkiss.dbeaver.DBException;
Expand Down Expand Up @@ -199,12 +200,15 @@ void clearProjects() {

@Override
public boolean hasRealmPermission(@NotNull String permission) {
if (getWebSession() instanceof WebSession webSession) {
return webSession.getSessionPermissions().contains(permission);
}
return false;
}

@Override
public boolean supportsRealmFeature(@NotNull String feature) {
return false;
return ServletAppUtils.getServletApplication().getAppConfiguration().isFeatureEnabled(feature);
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -115,4 +115,9 @@ public BaseProjectImpl getProject(@NotNull String projectName) {
}
return null;
}

@Override
public boolean supportsRealmFeature(@NotNull String feature) {
return application.getAppConfiguration().isFeatureEnabled(feature);
}
}
Loading