python-krbcontext icon indicating copy to clipboard operation
python-krbcontext copied to clipboard

Doesn't work with default ccache specified by KRB5CCNAME

Open tkdchen opened this issue 8 years ago • 0 comments

User story

I want to initialize a Kerberos context in default ccache, which is specified by KRB5CCNAME.

For example,

import os
os.environ['KRB5CCNAME'] = '/tmp/mycc'

with krbContext(using_keytab=True, principal='...', keytab_file='...'):
    import subprocess
    subprocess.call(['klist'])

Credential cannot be acquired in ccache /tmp/mycc, and error is raised

GSSError: Major (851968): Unspecified GSS failure. Minor code may provide more information, Minor (39756032): Principal in credential cache does not match desired name

tkdchen avatar Sep 04 '17 09:09 tkdchen