【问题标题】:Kerberos authorization to add another user添加其他用户的 Kerberos 授权
【发布时间】:2016-11-17 00:45:17
【问题描述】:

我正在 Linux 上进行 Ansible 设置以连接 Windows(主机)机器,我已使用 KERBEROS method 成功连接。

我已使用以下命令添加用户:

kinit -C user_1@EXAMPLE.COM

我可以使用klist查看详细信息,它显示了详细信息票。

但我想添加另一个用户,即 user_2,当我尝试运行 kinit -C user_2@EXAMPLE.COM 时,它会覆盖现有的 klist,我想查看两张票(user_1 和 user_2)

我的对象正在使用 ansible 我想在不同的用户( user_1 , user_2)上运行剧本

【问题讨论】:

    标签: active-directory ansible kerberos ansible-2.x klist


    【解决方案1】:

    您不能添加额外用户到现有票证缓存;但是您可以为不同的用户创建 distinct 缓存,并切换上下文。

    # new context, new ticket for other account
    export KRB5CCNAME=/tmp/krb5cc_$(id -u)_biloute
    kinit biloute@EXAMPLE.COM
    ...
    # switch back to default context
    unset KRB5CCNAME
    ...
    # switch again
    export KRB5CCNAME=/tmp/krb5cc_$(id -u)_biloute
    ...
    

    【讨论】:

      【解决方案2】:

      您需要使用 Kerberized 版本的“ksu”在 user_1 和 user_2 之间切换 user(su),然后尝试 klist。

      换句话说,使用 Kerberos 程序 ksu 代替其非 Kerberos 程序 su。那就试试klist

      谢谢

      库马尔

      【讨论】:

        猜你喜欢
        • 2017-07-29
        • 1970-01-01
        • 2014-11-08
        • 1970-01-01
        • 1970-01-01
        • 2021-03-11
        • 2015-11-17
        • 1970-01-01
        • 2013-09-14
        相关资源
        最近更新 更多