Skip to content

Commit

Permalink
Add Kerberos specific GSS-API Extensions
Browse files Browse the repository at this point in the history
Adds most of the Kerberos specific GSS-API extension methods.  These
methods are useful when migrating from the Kerberos API to GSS-API or
when needing Kerberos specific functionality that is not exposed in
GSS-API.

Signed-off-by: Jordan Borean <jborean93@gmail.com>
[rharwood@redhat.com: style and grammar things]
  • Loading branch information
jborean93 authored and frozencemetery committed Aug 10, 2021
1 parent 3724894 commit be33336
Show file tree
Hide file tree
Showing 10 changed files with 947 additions and 0 deletions.
2 changes: 2 additions & 0 deletions README.txt
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,8 @@ In addition to RFC 2743/2744, Python-GSSAPI also has support for:

* GGF Extensions

* Kerberos specific extensions

The Team
========

Expand Down
3 changes: 3 additions & 0 deletions ci/lib-setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ setup::debian::install() {
else
apt-get -y install krb5-{user,kdc,admin-server,multidev} libkrb5-dev \
gss-ntlmssp

export GSSAPI_KRB5_MAIN_LIB="/usr/lib/x86_64-linux-gnu/libkrb5.so"
fi

apt-get -y install gcc virtualenv python3-{virtualenv,dev} cython3
Expand Down Expand Up @@ -46,6 +48,7 @@ setup::fedora::install() {
setup::rh::install() {
setup::rh::yuminst krb5-{devel,libs,server,workstation} \
which gcc findutils gssntlmssp
export GSSAPI_KRB5_MAIN_LIB="/usr/lib64/libkrb5.so"

if [ -f /etc/fedora-release ]; then
setup::fedora::install
Expand Down
7 changes: 7 additions & 0 deletions docs/source/gssapi.raw.rst
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,13 @@ Acquiring Credentials With a Password Extensions
:members:
:undoc-members:

Kerberos Specific Extensions
~~~~~~~~~~~~~~~~~~~~~~~~~~~~

.. automodule:: gssapi.raw.ext_krb5
:members:
:undoc-members:

Other Extensions
~~~~~~~~~~~~~~~~

Expand Down
6 changes: 6 additions & 0 deletions gssapi/raw/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,12 @@
except ImportError:
pass

# optional KRB5 specific extension support
try:
from gssapi.raw.ext_krb5 import * # noqa
except ImportError:
pass

# optional RFC 6680 support
try:
from gssapi.raw.ext_rfc6680 import * # noqa
Expand Down
2 changes: 2 additions & 0 deletions gssapi/raw/ext_krb5.pxd
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
cdef class Krb5LucidContext:
cdef void *raw_ctx
Loading

0 comments on commit be33336

Please sign in to comment.