Security advisory GHSA-qjmq-8hjr-qcv6: SQL Injection when creating an application with Reactive SQL backend 
Package: generator-jhipster (npm), vulnerable version: 7.8.0, fixed in: 7.8.1
CWE: CWE-89
Files changed by the fix:
b/generators/generator-constants.js

Fix diff:
diff -ruN --no-dereference /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.0/generators/client/templates/angular/package.json /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.1/generators/client/templates/angular/package.json
--- a/generators/client/templates/angular/package.json
+++ b/generators/client/templates/angular/package.json
@@ -7,7 +7,7 @@
     "@ng-bootstrap/ng-bootstrap": "12.0.1",
     "@ngx-translate/core": "14.0.0",
     "@ngx-translate/http-loader": "7.0.0",
-    "@popperjs/core": "2.11.4",
+    "@popperjs/core": "2.11.5",
     "bootstrap": "5.1.3",
     "bootswatch": "5.1.3",
     "ngx-cookie-service": "13.1.2",
@@ -21,10 +21,10 @@
     "@angular/cli": "13.3.1",
     "@angular-builders/custom-webpack": "13.1.0",
     "@angular-builders/jest": "13.0.3",
-    "@angular-eslint/eslint-plugin": "13.1.0",
+    "@angular-eslint/eslint-plugin": "13.2.0",
     "@types/node": "16.11.26",
     "@types/jest": "27.4.1",
-    "@typescript-eslint/eslint-plugin": "5.17.0",
+    "@typescript-eslint/eslint-plugin": "5.18.0",
     "browser-sync": "2.27.9",
     "browser-sync-webpack-plugin": "2.3.0",
     "copy-webpack-plugin": "10.2.4",
@@ -35,14 +35,14 @@
     "jest": "27.5.1",
     "jest-preset-angular": "11.1.1",
     "jest-date-mock": "1.0.8",
-    "jest-junit": "13.0.0",
+    "jest-junit": "13.1.0",
     "jest-sonar-reporter": "2.0.0",
     "merge-jsons-webpack-plugin": "2.0.1",
     "postcss-rtlcss": "3.5.4",
     "rimraf": "3.0.2",
     "ts-jest": "27.1.4",
     "typescript": "4.6.3",
-    "webpack": "5.70.0",
+    "webpack": "5.71.0",
     "webpack-bundle-analyzer": "4.5.0",
     "webpack-merge": "5.8.0",
     "webpack-notifier": "1.15.0"
diff -ruN --no-dereference /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.0/generators/client/templates/common/package.json /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.1/generators/client/templates/common/package.json
--- a/generators/client/templates/common/package.json
+++ b/generators/client/templates/common/package.json
@@ -8,7 +8,7 @@
     "eslint-plugin-cypress": "2.12.1",
     "lighthouse": "9.5.0",
     "nyc": "15.1.0",
-    "swagger-ui-dist": "4.10.0"
+    "swagger-ui-dist": "4.10.3"
   },
   "dependencies": {
     "dayjs": "1.11.0"
diff -ruN --no-dereference /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.0/generators/client/templates/react/package.json /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.1/generators/client/templates/react/package.json
--- a/generators/client/templates/react/package.json
+++ b/generators/client/templates/react/package.json
@@ -14,7 +14,7 @@
     "react-hook-form": "7.29.0",
     "react-jhipster": "0.20.0",
     "react-loadable": "5.5.0",
-    "react-redux": "7.2.7",
+    "react-redux": "7.2.8",
     "react-redux-loading-bar": "5.0.2",
     "react-router-dom": "5.3.0",
     "react-toastify": "8.2.0",
@@ -37,8 +37,8 @@
     "@types/react-router-dom": "5.3.3",
     "@types/redux": "3.6.31",
     "@types/webpack-env": "1.16.3",
-    "@typescript-eslint/eslint-plugin": "5.17.0",
-    "@typescript-eslint/parser": "5.17.0",
+    "@typescript-eslint/eslint-plugin": "5.18.0",
+    "@typescript-eslint/parser": "5.18.0",
     "autoprefixer": "10.4.4",
     "browser-sync": "2.27.9",
     "browser-sync-webpack-plugin": "2.3.0",
@@ -52,11 +52,11 @@
     "eslint-plugin-react": "7.29.4",
     "eslint-webpack-plugin": "3.1.1",
     "folder-hash": "4.0.2",
-    "fork-ts-checker-webpack-plugin": "7.2.1",
+    "fork-ts-checker-webpack-plugin": "7.2.3",
     "html-webpack-plugin": "5.5.0",
     "identity-obj-proxy": "3.0.0",
     "jest": "27.5.1",
-    "jest-junit": "13.0.0",
+    "jest-junit": "13.1.0",
     "jest-sonar-reporter": "2.0.0",
     "json-loader": "0.5.7",
     "merge-jsons-webpack-plugin": "2.0.1",
@@ -66,7 +66,7 @@
     "react-infinite-scroll-component": "6.1.0",
     "redux-mock-store": "1.5.4",
     "rimraf": "3.0.2",
-    "sass": "1.49.10",
+    "sass": "1.49.11",
     "sass-loader": "12.6.0",
     "simple-progress-webpack-plugin": "2.0.0",
     "sinon": "13.0.1",
@@ -78,9 +78,9 @@
     "ts-jest": "27.1.4",
     "ts-loader": "9.2.8",
     "typescript": "4.6.3",
-    "webpack": "5.70.0",
+    "webpack": "5.71.0",
     "webpack-cli": "4.9.2",
-    "webpack-dev-server": "4.7.4",
+    "webpack-dev-server": "4.8.0",
     "webpack-merge": "5.8.0",
     "webpack-notifier": "1.15.0",
     "workbox-webpack-plugin": "6.5.2"
diff -ruN --no-dereference /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.0/generators/client/templates/vue/package.json /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.1/generators/client/templates/vue/package.json
--- a/generators/client/templates/vue/package.json
+++ b/generators/client/templates/vue/package.json
@@ -35,10 +35,10 @@
     "css-loader": "6.7.1",
     "css-minimizer-webpack-plugin": "3.4.1",
     "folder-hash": "4.0.2",
-    "fork-ts-checker-webpack-plugin": "7.2.1",
+    "fork-ts-checker-webpack-plugin": "7.2.3",
     "html-webpack-plugin": "5.5.0",
     "jest": "27.5.1",
-    "jest-junit": "13.0.0",
+    "jest-junit": "13.1.0",
     "jest-serializer-vue": "2.0.2",
     "jest-sonar-reporter": "2.0.0",
     "jest-vue-preprocessor": "1.7.1",
@@ -49,7 +49,7 @@
     "postcss-loader": "6.2.1",
     "postcss-url": "10.1.3",
     "rimraf": "3.0.2",
-    "sass": "1.49.10",
+    "sass": "1.49.11",
     "sass-loader": "12.6.0",
     "sinon": "13.0.1",
     "terser-webpack-plugin": "5.3.1",
@@ -59,10 +59,10 @@
     "eslint-plugin-prettier": "4.0.0",
     "eslint-plugin-vue": "8.5.0",
     "typescript": "4.6.3",
-    "webpack": "5.70.0",
+    "webpack": "5.71.0",
     "webpack-bundle-analyzer": "4.5.0",
     "webpack-cli": "4.9.2",
-    "webpack-dev-server": "4.7.4",
+    "webpack-dev-server": "4.8.0",
     "webpack-merge": "5.8.0",
     "workbox-webpack-plugin": "6.5.2",
     "vue-jest": "3.0.7",
diff -ruN --no-dereference /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.0/generators/common/templates/package.json /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.1/generators/common/templates/package.json
--- a/generators/common/templates/package.json
+++ b/generators/common/templates/package.json
@@ -1,6 +1,6 @@
 {
   "devDependencies": {
-    "concurrently": "7.0.0",
+    "concurrently": "7.1.0",
     "husky": "7.0.4",
     "lint-staged": "12.3.7",
     "npm": "8.6.0",
diff -ruN --no-dereference /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.0/generators/entity-server/templates/src/main/java/package/repository/EntityRepositoryInternalImpl_reactive.java.ejs /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.1/generators/entity-server/templates/src/main/java/package/repository/EntityRepositoryInternalImpl_reactive.java.ejs
--- a/generators/entity-server/templates/src/main/java/package/repository/EntityRepositoryInternalImpl_reactive.java.ejs
+++ b/generators/entity-server/templates/src/main/java/package/repository/EntityRepositoryInternalImpl_reactive.java.ejs
@@ -50,6 +50,9 @@
 import org.springframework.data.r2dbc.repository.support.SimpleR2dbcRepository;
 import org.springframework.data.relational.core.query.Criteria;
 import org.springframework.data.relational.core.sql.Column;
+import org.springframework.data.relational.core.sql.Comparison;
+import org.springframework.data.relational.core.sql.Condition;
+import org.springframework.data.relational.core.sql.Conditions;
 import org.springframework.data.relational.core.sql.Expression;
 import org.springframework.data.relational.core.sql.Select;
 import org.springframework.data.relational.core.sql.SelectBuilder.SelectFromAndJoin<% if (reactiveEagerRelations.length > 0) { %>Condition<% } %>;
@@ -121,15 +124,10 @@
 
     @Override
     public Flux<<%= persistClass %>> findAllBy(Pageable pageable) {
-        return findAllBy(pageable, null);
+        return createQuery(pageable, null).all();
     }
 
-    @Override
-    public Flux<<%= persistClass %>> findAllBy(Pageable pageable, Criteria criteria) {
-        return createQuery(pageable, criteria).all();
-    }
-
-    RowsFetchSpec<<%= persistClass %>> createQuery(Pageable pageable, Criteria criteria) {
+    RowsFetchSpec<<%= persistClass %>> createQuery(Pageable pageable, Condition whereClause) {
         List<Expression> columns = <%= entityClass %>SqlHelper.getColumns(entityTable, EntityManager.ENTITY_ALIAS);
 <%_ reactiveEagerRelations.forEach(function(rel) { _%>
         columns.addAll(<%= rel.otherEntityNameCapitalized %>SqlHelper.getColumns(<%= rel.relationshipName %>Table, "<%= rel.relationshipName %>"));
@@ -138,19 +136,20 @@
 <%_ reactiveEagerRelations.forEach(function(rel) { _%>
             .leftOuterJoin(<%= rel.relationshipName %>Table).on(Column.create("<%= rel.joinColumnNames[0] %>", entityTable)).equals(Column.create("<%= rel.otherEntity.primaryKey.fields[0].columnName %>", <%= rel.relationshipName %>Table ))
 <%_ }); _%>;
-
-        String select = entityManager.createSelect(selectFrom, <%= persistClass %>.class, pageable, criteria);
+        // we do not support Criteria here for now as of https://github.com/jhipster/generator-jhipster/issues/18269
+        String select = entityManager.createSelect(selectFrom, <%= persistClass %>.class, pageable, whereClause);
         return db.sql(select).map(this::process);
     }
 
     @Override
     public Flux<<%= persistClass %>> findAll() {
-        return findAllBy(null, null);
+        return findAllBy(null);
     }
 
     @Override
     public Mono<<%= persistClass %>> findById(<%= primaryKey.type %> id) {
-        return createQuery(null, where(EntityManager.ENTITY_ALIAS + ".<%= primaryKey.fields[0].columnName %>").is(id)).one();
+        Comparison whereClause = Conditions.isEqual(entityTable.column("<%= primaryKey.fields[0].columnName %>"), Conditions.just(id.toString()));
+        return createQuery(null, whereClause).one();
     }
 
 <%_ if (implementsEagerLoadApis) { _%>
diff -ruN --no-dereference /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.0/generators/entity-server/templates/src/main/java/package/repository/EntityRepository_reactive.java.ejs /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.1/generators/entity-server/templates/src/main/java/package/repository/EntityRepository_reactive.java.ejs
--- a/generators/entity-server/templates/src/main/java/package/repository/EntityRepository_reactive.java.ejs
+++ b/generators/entity-server/templates/src/main/java/package/repository/EntityRepository_reactive.java.ejs
@@ -144,8 +144,8 @@
     Flux<<%= persistClass %>> findAll();
 
     Mono<<%= persistClass %>> findById(<%= primaryKey.type %> id);
-
-    Flux<<%= persistClass %>> findAllBy(Pageable pageable, Criteria criteria);
+    // this is not supported at the moment because of https://github.com/jhipster/generator-jhipster/issues/18269
+    // Flux<<%= persistClass %>> findAllBy(Pageable pageable, Criteria criteria);
 
   <%_ if (implementsEagerLoadApis) { _%>
 
diff -ruN --no-dereference /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.0/generators/generator-constants.js /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.1/generators/generator-constants.js
--- a/generators/generator-constants.js
+++ b/generators/generator-constants.js
@@ -35,7 +35,7 @@
 const JIB_VERSION = '3.2.1';
 
 // Libraries version
-const JHIPSTER_DEPENDENCIES_VERSION = '7.8.0';
+const JHIPSTER_DEPENDENCIES_VERSION = '7.8.1';
 // The spring-boot version should match the one managed by https://mvnrepository.com/artifact/tech.jhipster/jhipster-dependencies/JHIPSTER_DEPENDENCIES_VERSION
 const SPRING_BOOT_VERSION = '2.6.6';
 const LIQUIBASE_VERSION = '4.6.1';
diff -ruN --no-dereference /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.0/generators/maven/templates/.mvn/wrapper/maven-wrapper.properties /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.1/generators/maven/templates/.mvn/wrapper/maven-wrapper.properties
--- a/generators/maven/templates/.mvn/wrapper/maven-wrapper.properties
+++ b/generators/maven/templates/.mvn/wrapper/maven-wrapper.properties
@@ -5,14 +5,14 @@
 # to you under the Apache License, Version 2.0 (the
 # "License"); you may not use this file except in compliance
 # with the License.  You may obtain a copy of the License at
-# 
+#
 #   http://www.apache.org/licenses/LICENSE-2.0
-# 
+#
 # Unless required by applicable law or agreed to in writing,
 # software distributed under the License is distributed on an
 # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
 # KIND, either express or implied.  See the License for the
 # specific language governing permissions and limitations
 # under the License.
-distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.8.4/apache-maven-3.8.4-bin.zip
+distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.8.5/apache-maven-3.8.5-bin.zip
 wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.1.0/maven-wrapper-3.1.0.jar
diff -ruN --no-dereference /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.0/generators/maven/templates/pom.xml.jhi.ejs /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.1/generators/maven/templates/pom.xml.jhi.ejs
--- a/generators/maven/templates/pom.xml.jhi.ejs
+++ b/generators/maven/templates/pom.xml.jhi.ejs
@@ -59,7 +59,7 @@
     <properties>
         <java.version><%= JAVA_VERSION %></java.version>
 
-        <compiler-plugin.version>3.8.4</compiler-plugin.version>
+        <compiler-plugin.version>3.9.0</compiler-plugin.version>
         <surefire-plugin.version>3.0.0-M5</surefire-plugin.version>
 <&- fragments.propertiesSection() -&>
     </properties>
diff -ruN --no-dereference /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.0/generators/server/templates/.mvn/wrapper/maven-wrapper.properties /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.1/generators/server/templates/.mvn/wrapper/maven-wrapper.properties
--- a/generators/server/templates/.mvn/wrapper/maven-wrapper.properties
+++ b/generators/server/templates/.mvn/wrapper/maven-wrapper.properties
@@ -5,14 +5,14 @@
 # to you under the Apache License, Version 2.0 (the
 # "License"); you may not use this file except in compliance
 # with the License.  You may obtain a copy of the License at
-# 
+#
 #   http://www.apache.org/licenses/LICENSE-2.0
-# 
+#
 # Unless required by applicable law or agreed to in writing,
 # software distributed under the License is distributed on an
 # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
 # KIND, either express or implied.  See the License for the
 # specific language governing permissions and limitations
 # under the License.
-distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.8.4/apache-maven-3.8.4-bin.zip
+distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.8.5/apache-maven-3.8.5-bin.zip
 wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.1.0/maven-wrapper-3.1.0.jar
diff -ruN --no-dereference /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.0/generators/server/templates/pom.xml.ejs /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.1/generators/server/templates/pom.xml.ejs
--- a/generators/server/templates/pom.xml.ejs
+++ b/generators/server/templates/pom.xml.ejs
@@ -64,7 +64,7 @@
 
     <properties>
         <!-- Build properties -->
-        <maven.version>3.8.4</maven.version>
+        <maven.version>3.8.5</maven.version>
         <java.version><%= JAVA_VERSION %></java.version>
 <%_ if (!skipClient) { _%>
         <node.version>v<%= NODE_VERSION %></node.version>
diff -ruN --no-dereference /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.0/generators/server/templates/src/main/java/package/repository/EntityManager.java.ejs /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.1/generators/server/templates/src/main/java/package/repository/EntityManager.java.ejs
--- a/generators/server/templates/src/main/java/package/repository/EntityManager.java.ejs
+++ b/generators/server/templates/src/main/java/package/repository/EntityManager.java.ejs
@@ -33,6 +33,7 @@
 import org.springframework.data.r2dbc.mapping.OutboundRow;
 import org.springframework.data.r2dbc.query.UpdateMapper;
 import org.springframework.data.relational.core.query.Criteria;
+import org.springframework.data.relational.core.sql.Condition;
 import org.springframework.data.relational.core.mapping.RelationalPersistentEntity;
 import org.springframework.data.relational.core.sql.Conditions;
 import org.springframework.data.relational.core.sql.OrderByField;
@@ -90,19 +91,28 @@
      * Creates an SQL select statement from the given fragment and pagination parameters.
      * @param selectFrom a representation of a select statement.
      * @param entityType the entity type which holds the table name.
-     * @param pageable page parameter, or null, if everything needs to be returned
+     * @param pageable page parameter, or null, if everything needs to be returned.
+     * @param where condition or null. The condition to apply as where clause.
      * @return sql select statement
      */
-    public String createSelect(SelectFromAndJoin selectFrom, Class<?> entityType, Pageable pageable, Criteria criteria) {
+    public String createSelect(SelectFromAndJoin selectFrom, Class<?> entityType, Pageable pageable, Condition where) {
         if (pageable != null) {
-            if (criteria != null) {
-                return createSelectImpl(selectFrom.limitOffset(pageable.getPageSize(), pageable.getOffset()).where(Conditions.just(criteria.toString())), entityType, pageable.getSort());
+            if (where != null) {
+                return createSelectImpl(
+                    selectFrom.limitOffset(pageable.getPageSize(), pageable.getOffset()).where(where),
+                    entityType,
+                    pageable.getSort()
+                );
             } else {
-                return createSelectImpl(selectFrom.limitOffset(pageable.getPageSize(), pageable.getOffset()), entityType, pageable.getSort());
+                return createSelectImpl(
+                    selectFrom.limitOffset(pageable.getPageSize(), pageable.getOffset()),
+                    entityType,
+                    pageable.getSort()
+                );
             }
         } else {
-            if (criteria != null) {
-                return createSelectImpl(selectFrom.where(Conditions.just(criteria.toString())), entityType, null);
+            if (where != null) {
+                return createSelectImpl(selectFrom.where(where), entityType, null);
             } else {
                 return createSelectImpl(selectFrom, entityType, null);
             }
@@ -114,37 +124,32 @@
      * @param selectFrom a representation of a select statement.
      * @param entityType the entity type which holds the table name.
      * @param pageable page parameter, or null, if everything needs to be returned
+     * @param where condition or null. The condition to apply as where clause.
      * @return sql select statement
      */
-    public String createSelect(SelectFromAndJoinCondition selectFrom, Class<?> entityType, Pageable pageable, Criteria criteria) {
+    public String createSelect(SelectFromAndJoinCondition selectFrom, Class<?> entityType, Pageable pageable, Condition where) {
         if (pageable != null) {
-            if (criteria != null) {
-                return createSelectImpl(selectFrom.limitOffset(pageable.getPageSize(), pageable.getOffset()).where(Conditions.just(criteria.toString())), entityType, pageable.getSort());
+            if (where != null) {
+                return createSelectImpl(selectFrom.limitOffset(pageable.getPageSize(), pageable.getOffset()).where(where), entityType, pageable.getSort());
             } else {
                 return createSelectImpl(selectFrom.limitOffset(pageable.getPageSize(), pageable.getOffset()), entityType, pageable.getSort());
             }
         } else {
-            if (criteria != null) {
-                return createSelectImpl(selectFrom.where(Conditions.just(criteria.toString())), entityType, null);
+            if (where != null) {
+                return createSelectImpl(selectFrom.where(where), entityType, null);
             } else {
                 return createSelectImpl(selectFrom, entityType, null);
             }
         }
     }
 
-    private String createSelectImpl(SelectOrdered selectFrom, Class<?> entityType, Sort sortParameter) {
-        if (sortParameter != null && sortParameter.isSorted()) {
-            RelationalPersistentEntity<?> entity = getPersistentEntity(entityType);
-            if (entity != null) {
-                Sort sort = updateMapper.getMappedObject(sortParameter, entity);
-                selectFrom = selectFrom.orderBy(createOrderByFields(Table.create(entity.getTableName()).as(EntityManager.ENTITY_ALIAS), sort));
-            }
-        }
-        return createSelect(selectFrom.build());
-    }
-
-    private RelationalPersistentEntity<?> getPersistentEntity(Class<?> entityType) {
-        return r2dbcEntityTemplate.getConverter().getMappingContext().getPersistentEntity(entityType);
+    /**
+     * Generate an actual SQL from the given {@link Select}.
+     * @param select a representation of a select statement.
+     * @return the generated SQL select.
+     */
+    public String createSelect(Select select) {
+        return sqlRenderer.render(select);
     }
 
     /**
@@ -167,15 +172,6 @@
     }
 
     /**
-     * Generate an actual SQL from the given {@link Select}.
-     * @param select a representation of a select statement.
-     * @return the generated SQL select.
-     */
-    public String createSelect(Select select) {
-        return sqlRenderer.render(select);
-    }
-
-    /**
      * Inserts the given entity into the database - and sets the id, if it's an autoincrement field.
      * @param <S> the type of the persisted entity.
      * @param entity the entity to be inserted into the database.
@@ -222,6 +218,21 @@
         return r2dbcEntityTemplate.getDatabaseClient().sql(statementMapper.getMappedObject(deleteSpec)).then();
     }
 
+    private String createSelectImpl(SelectOrdered selectFrom, Class<?> entityType, Sort sortParameter) {
+        if (sortParameter != null && sortParameter.isSorted()) {
+            RelationalPersistentEntity<?> entity = getPersistentEntity(entityType);
+            if (entity != null) {
+                Sort sort = updateMapper.getMappedObject(sortParameter, entity);
+                selectFrom = selectFrom.orderBy(createOrderByFields(Table.create(entity.getTableName()).as(EntityManager.ENTITY_ALIAS), sort));
+            }
+        }
+        return createSelect(selectFrom.build());
+    }
+
+    private RelationalPersistentEntity<?> getPersistentEntity(Class<?> entityType) {
+        return r2dbcEntityTemplate.getConverter().getMappingContext().getPersistentEntity(entityType);
+    }
+
     private static Collection<? extends OrderByField> createOrderByFields(Table table, Sort sortToUse) {
 
         List<OrderByField> fields = new ArrayList<>();
@@ -236,5 +247,4 @@
 
         return fields;
     }
-
 }
diff -ruN --no-dereference /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.0/package.json /home/ubuntu/closed-source-intelligence/data/cache/npm-tarballs/generator-jhipster-7.8.1/package.json
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
 {
   "name": "generator-jhipster",
-  "version": "7.8.0",
+  "version": "7.8.1",
   "description": "Spring Boot + Angular/React/Vue in one handy generator",
   "keywords": [
     "yeoman-generator",
@@ -84,12 +84,12 @@
   },
   "dependencies": {
     "@faker-js/faker": "5.5.3",
-    "aws-sdk": "2.1101.0",
+    "aws-sdk": "2.1106.0",
     "axios": "0.26.1",
     "chalk": "4.1.2",
     "chevrotain": "10.1.2",
     "commander": "9.1.0",
-    "conf": "10.1.1",
+    "conf": "10.1.2",
     "debug": "4.3.4",
     "didyoumean": "1.2.2",
     "ejs": "3.1.6",
@@ -105,14 +105,14 @@
     "p-transform": "1.3.0",
     "parse-gitignore": "1.0.1",
     "pluralize": "8.0.0",
-    "prettier": "2.6.1",
+    "prettier": "2.6.2",
     "prettier-plugin-java": "1.6.1",
     "prettier-plugin-packagejson": "2.2.17",
     "progress": "2.0.3",
     "randexp": "0.5.3",
     "semver": "7.3.5",
     "shelljs": "0.8.5",
-    "simple-git": "3.4.0",
+    "simple-git": "3.5.0",
     "then-request": "6.0.2",
     "uuid": "8.3.2",
     "winston": "3.6.0",