mirror of
https://github.com/gyurix1968/guacamole-client.git
synced 2025-09-06 05:07:41 +00:00
GUACAMOLE-1239: Remove per-extension configuration for case-sensitivity, retaining only global configuration.
This commit is contained in:
@@ -442,16 +442,5 @@ public class MySQLEnvironment extends JDBCEnvironment {
|
||||
true
|
||||
);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean getCaseSensitiveUsernames() throws GuacamoleException {
|
||||
|
||||
// Return the configured value for the property, or the global value.
|
||||
return getProperty(
|
||||
MySQLGuacamoleProperties.MYSQL_CASE_SENSITIVE_USERNAMES,
|
||||
super.getCaseSensitiveUsernames()
|
||||
);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -303,18 +303,4 @@ public class MySQLGuacamoleProperties {
|
||||
|
||||
};
|
||||
|
||||
/**
|
||||
* A property used to configure whether or not usernames within the MySQL
|
||||
* JDBC module should be treated as case-sensitive. Be aware that MySQL's
|
||||
* default database collations do not do case-sensitive comparisons, so in
|
||||
* many cases they will effectively be case-insensitive.
|
||||
*/
|
||||
public static final BooleanGuacamoleProperty MYSQL_CASE_SENSITIVE_USERNAMES =
|
||||
new BooleanGuacamoleProperty() {
|
||||
|
||||
@Override
|
||||
public String getName() { return "mysql-case-sensitive-usernames"; }
|
||||
|
||||
};
|
||||
|
||||
}
|
||||
|
@@ -22,8 +22,6 @@ package org.apache.guacamole.auth.postgresql.conf;
|
||||
import java.io.File;
|
||||
import org.apache.guacamole.GuacamoleException;
|
||||
import org.apache.guacamole.auth.jdbc.JDBCEnvironment;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.apache.guacamole.auth.jdbc.security.PasswordPolicy;
|
||||
import org.apache.ibatis.session.SqlSession;
|
||||
|
||||
@@ -33,11 +31,6 @@ import org.apache.ibatis.session.SqlSession;
|
||||
*/
|
||||
public class PostgreSQLEnvironment extends JDBCEnvironment {
|
||||
|
||||
/**
|
||||
* Logger for this class.
|
||||
*/
|
||||
private static final Logger logger = LoggerFactory.getLogger(PostgreSQLEnvironment.class);
|
||||
|
||||
/**
|
||||
* The default host to connect to, if POSTGRESQL_HOSTNAME is not specified.
|
||||
*/
|
||||
@@ -398,20 +391,5 @@ public class PostgreSQLEnvironment extends JDBCEnvironment {
|
||||
PostgreSQLGuacamoleProperties.POSTGRESQL_ENFORCE_ACCESS_WINDOWS_FOR_ACTIVE_SESSIONS,
|
||||
true);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean getCaseSensitiveUsernames() throws GuacamoleException {
|
||||
|
||||
// By default, PostgreSQL does perform case-sensitive string comparisons.
|
||||
// Even though usernames are generally not case-sensitive across
|
||||
// most authenticaiton systems, we've elected to maintain case-
|
||||
// sensitivity in this module in order to avoid surprising anyone who
|
||||
// may be relying upon it.
|
||||
return getProperty(
|
||||
PostgreSQLGuacamoleProperties.POSTGRESQL_CASE_SENSITIVE_USERNAMES,
|
||||
super.getCaseSensitiveUsernames()
|
||||
);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -328,19 +328,5 @@ public class SQLServerEnvironment extends JDBCEnvironment {
|
||||
SQLServerGuacamoleProperties.SQLSERVER_TRUST_ALL_SERVER_CERTIFICATES,
|
||||
false);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean getCaseSensitiveUsernames() throws GuacamoleException {
|
||||
|
||||
// Get the configured or default value of the property.
|
||||
boolean caseSensitiveUsernames = getProperty(
|
||||
SQLServerGuacamoleProperties.SQLSERVER_CASE_SENSITIVE_USERNAMES,
|
||||
super.getCaseSensitiveUsernames()
|
||||
);
|
||||
|
||||
// Return as configured
|
||||
return caseSensitiveUsernames;
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -257,20 +257,5 @@ public class SQLServerGuacamoleProperties {
|
||||
public String getName() { return "sqlserver-trust-all-server-certificates"; }
|
||||
|
||||
};
|
||||
|
||||
/**
|
||||
* A property used to configure whether or not usernames within the SQL
|
||||
* Server JDBC module should be treated as case-sensitive. While Guacamole
|
||||
* will treat usernames as case-sensitive by default, SQL Server's default
|
||||
* database collations do not do case-sensitive string comparisons, so in
|
||||
* many cases this will effectively result in case-insensitive usernames.
|
||||
*/
|
||||
public static final BooleanGuacamoleProperty SQLSERVER_CASE_SENSITIVE_USERNAMES =
|
||||
new BooleanGuacamoleProperty() {
|
||||
|
||||
@Override
|
||||
public String getName() { return "sqlserver-case-sensitive-usernames" ; }
|
||||
|
||||
};
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user