You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@iotdb.apache.org by GitBox <gi...@apache.org> on 2022/01/08 14:32:21 UTC
[GitHub] [iotdb] zyk990424 opened a new pull request #4734: [IOTDB-2256] Fix permission check bug while query with non timeseries
zyk990424 opened a new pull request #4734:
URL: https://github.com/apache/iotdb/pull/4734
## Description
### Problem
When authority module checks a query plan with empty path sets, which is caused by path pattern matching non timeseries, the system will return "user no permission", which should not happen.
### Solution
Add check on path nums before authority check. If empty path sets, authority check is unnecessary.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [iotdb] coveralls edited a comment on pull request #4734: [IOTDB-2256] Fix permission check bug while query with non timeseries
Posted by GitBox <gi...@apache.org>.
coveralls edited a comment on pull request #4734:
URL: https://github.com/apache/iotdb/pull/4734#issuecomment-1008030729
[](https://coveralls.io/builds/45468390)
Coverage increased (+0.01%) to 67.552% when pulling **bcf29162be83f3957ea17934efae2f7b7ba598e2 on zyk990424:fix_permission_bug** into **4df4bccb1f52831b889548a2d00bba63a1b57b62 on apache:master**.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [iotdb] coveralls edited a comment on pull request #4734: [IOTDB-2256] Fix permission check bug while query with non timeseries
Posted by GitBox <gi...@apache.org>.
coveralls edited a comment on pull request #4734:
URL: https://github.com/apache/iotdb/pull/4734#issuecomment-1008030729
[](https://coveralls.io/builds/45468472)
Coverage increased (+0.02%) to 67.562% when pulling **bcf29162be83f3957ea17934efae2f7b7ba598e2 on zyk990424:fix_permission_bug** into **4df4bccb1f52831b889548a2d00bba63a1b57b62 on apache:master**.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [iotdb] coveralls commented on pull request #4734: [IOTDB-2256] Fix permission check bug while query with non timeseries
Posted by GitBox <gi...@apache.org>.
coveralls commented on pull request #4734:
URL: https://github.com/apache/iotdb/pull/4734#issuecomment-1008030729
[](https://coveralls.io/builds/45468289)
Coverage increased (+0.04%) to 67.573% when pulling **bcf29162be83f3957ea17934efae2f7b7ba598e2 on zyk990424:fix_permission_bug** into **4df4bccb1f52831b889548a2d00bba63a1b57b62 on apache:master**.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [iotdb] coveralls edited a comment on pull request #4734: [IOTDB-2256] Fix permission check bug while query with non timeseries
Posted by GitBox <gi...@apache.org>.
coveralls edited a comment on pull request #4734:
URL: https://github.com/apache/iotdb/pull/4734#issuecomment-1008030729
[](https://coveralls.io/builds/45471031)
Coverage increased (+0.05%) to 67.584% when pulling **79b76cf39cf67e47a340a47476a9d1d112a458f5 on zyk990424:fix_permission_bug** into **4df4bccb1f52831b889548a2d00bba63a1b57b62 on apache:master**.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [iotdb] jt2594838 commented on a change in pull request #4734: [IOTDB-2256][IOTDB-2318] Fix permission check bug while query with non timeseries & Fix doc
Posted by GitBox <gi...@apache.org>.
jt2594838 commented on a change in pull request #4734:
URL: https://github.com/apache/iotdb/pull/4734#discussion_r780960814
##########
File path: integration/src/test/java/org/apache/iotdb/db/integration/auth/IoTDBAuthorizationIT.java
##########
@@ -1178,4 +1178,26 @@ public void testSelectUDTF() throws ClassNotFoundException, SQLException {
assertTrue(resultSet.next());
}
}
+
+ @Test
+ public void testEmptySetAuthorityCheck() throws ClassNotFoundException, SQLException {
+ Class.forName(Config.JDBC_DRIVER_NAME);
+ try (Connection adminConnection =
+ DriverManager.getConnection(
+ Config.IOTDB_URL_PREFIX + "127.0.0.1:6667/", "root", "root");
+ Statement adminStatement = adminConnection.createStatement()) {
+ adminStatement.execute("CREATE USER a_application 'a_application'");
+ adminStatement.execute("GRANT USER a_application PRIVILEGES READ_TIMESERIES on root.ln;");
+
+ adminStatement.execute("INSERT INTO root.ln.wt01.wf01(time, s1) VALUES(1, 2)");
+ }
+
+ try (Connection userConnection =
+ DriverManager.getConnection(
+ Config.IOTDB_URL_PREFIX + "127.0.0.1:6667/", "a_application", "a_application");
+ Statement userStatement = userConnection.createStatement();
+ ResultSet resultSet = userStatement.executeQuery("SELECT * FROM root.ln.*")) {
Review comment:
Does this correspond to "empty set"?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [iotdb] qiaojialin merged pull request #4734: [IOTDB-2256][IOTDB-2318] Fix permission check bug while query with non timeseries & Fix doc
Posted by GitBox <gi...@apache.org>.
qiaojialin merged pull request #4734:
URL: https://github.com/apache/iotdb/pull/4734
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [iotdb] coveralls edited a comment on pull request #4734: [IOTDB-2256][IOTDB-2318] Fix permission check bug while query with non timeseries & Fix doc
Posted by GitBox <gi...@apache.org>.
coveralls edited a comment on pull request #4734:
URL: https://github.com/apache/iotdb/pull/4734#issuecomment-1008030729
[](https://coveralls.io/builds/45479721)
Coverage increased (+0.009%) to 67.546% when pulling **ccc32740822891070182a81e53e7bd4d6380abb0 on zyk990424:fix_permission_bug** into **4df4bccb1f52831b889548a2d00bba63a1b57b62 on apache:master**.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org