revoke any privileges for unknown users from created database

This commit is contained in:
Peter Hormanns 2016-05-13 14:58:14 +02:00
parent dd4ce59112
commit aabb5d1781

View File

@ -27,6 +27,7 @@ public class PgSqlDatabaseProcessorFactory implements EntityProcessorFactory {
String aEncoding = AbstractEntity.escapeString(db.getEncoding());
aJDBCP = createPostgreSqlAdminProcessor();
aJDBCP.addSQL("CREATE DATABASE " + aName + " OWNER=" + aOwner + " ENCODING='" + aEncoding + "' TEMPLATE template0");
aJDBCP.addSQL("REVOKE ALL ON DATABASE " + aName + " FROM public");
return aJDBCP;
}