bowenliang123 commented on code in PR #3838:
URL: https://github.com/apache/incubator-kyuubi/pull/3838#discussion_r1032055137
##########
kyuubi-common/src/main/scala/org/apache/kyuubi/config/KyuubiReservedKeys.scala:
##########
@@ -20,6 +20,8 @@ package org.apache.kyuubi.config
object KyuubiReservedKeys {
final val KYUUBI_CLIENT_IP_KEY = "kyuubi.client.ipAddress"
final val KYUUBI_SESSION_USER_KEY = "kyuubi.session.user"
+ final val KYUUBI_SESSION_USER_SIGN = "kyuubi.session.user.sign"
+ final val KYUUBI_SESSION_USER_PUBIC_KEY = "kyuubi.session.user.public.key"
Review Comment:
fixed.
##########
extensions/spark/kyuubi-spark-authz/src/main/scala/org/apache/kyuubi/plugin/spark/authz/util/AuthZUtils.scala:
##########
@@ -74,6 +85,13 @@ private[authz] object AuthZUtils {
def getAuthzUgi(spark: SparkContext): UserGroupInformation = {
// kyuubi.session.user is only used by kyuubi
val user = spark.getLocalProperty("kyuubi.session.user")
+ if (StringUtils.isNotBlank(user)) {
+ if (!verifyKyuubiSessionUser(spark, user)) {
+ throw new AccessControlException(
Review Comment:
Good point, thx.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]