hive 配置用户名_配置HiveServer2的安全策略之自定义用户名密码验证

本文介绍了如何配置HiveServer2以使用自定义的用户名和密码验证。通过实现`PasswdAuthenticationProvider`接口并创建`XXXXPasswdAuthenticator`类,将认证逻辑集成到Hive服务中。配置涉及在`hive-site.xml`中设置相关属性,并将实现类的JAR文件添加到Hive的库目录。
摘要由CSDN通过智能技术生成

具体从网上看

http://doc.mapr.com/display/MapR/Using+HiveServer2#UsingHiveServer2-ConfiguringCustomAuthentication

一共提供了三种安全认证方式,我们通常采用的为第三种自定义的方式。

To implement custom authentication for HiveServer2, create a custom Authenticator class derived from the following interface:

从这段话看出来我们要实现一个接口:PasswdAuthenticationProvider (org.apache.hive.service.auth.PasswdAuthenticationProvider)我们来看看这个接口

public interface PasswdAuthenticationProvider {

/**

* The Authenticate method is called by the HiveServer2 authentication layer

* to authenticate users for their requests.

* If a user is to be granted, return nothing/throw nothing.

* When a user is to be disallowed, throw an appropriate {@link AuthenticationException}.

*

* For an example implementation, see {@link LdapAuthenticationProviderImpl}.

*

* @param user - Th

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值