Skip to content

Commit 92bb1c2

Browse files
committed
Various doc fixes and update maintainer list
Signed-off-by: Jordan Borean <jborean93@gmail.com>
1 parent 935f95a commit 92bb1c2

15 files changed

+70
-66
lines changed

Diff for: README.txt

+2-1
Original file line numberDiff line numberDiff line change
@@ -170,8 +170,9 @@ The Team
170170

171171
(GitHub usernames in parentheses)
172172

173-
* Robbie Harwood (@frozencemetery) - current maintainer and developer
173+
* Jordan Borean (@jborean93) - current maintainer and developer
174174
* Simo Sorce (@simo5) - developer
175+
* Robbie Harwood (@frozencemetery) - author emeritus
175176
* Solly Ross (@directxman12) - author emeritus
176177
* Hugh Cole-Baker (@sigmaris) - author emeritus
177178

Diff for: gssapi/creds.py

+10-10
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ def name(self) -> rnames.Name:
9090

9191
@property
9292
def lifetime(self) -> int:
93-
"""Get the remaining lifetime of these credentials"""
93+
"""Get the remaining lifetime of these credentials, in seconds"""
9494
return t.cast(int,
9595
self.inquire(name=False, lifetime=True,
9696
usage=False, mechs=False).lifetime)
@@ -137,8 +137,8 @@ def acquire(
137137
Args:
138138
name (~gssapi.names.Name): the name associated with the
139139
credentials, or None for the default name
140-
lifetime (int): the desired lifetime of the credentials, or None
141-
for indefinite
140+
lifetime (int): the desired lifetime of the credentials in seconds,
141+
or None for indefinite
142142
mechs (list): the desired :class:`MechType` OIDs to be used
143143
with the credentials, or None for the default set
144144
usage (str): the usage for the credentials -- either 'both',
@@ -253,8 +253,8 @@ def impersonate(
253253
254254
Args:
255255
name (~gssapi.names.Name): the name to impersonate
256-
lifetime (int): the desired lifetime of the new credentials,
257-
or None for indefinite
256+
lifetime (int): the desired lifetime of the new credentials in
257+
seconds, or None for indefinite
258258
mechs (list): the desired :class:`MechType` OIDs for the new
259259
credentials
260260
usage (str): the desired usage for the new credentials -- either
@@ -326,13 +326,13 @@ def inquire_by_mech(
326326
about them.
327327
328328
Args:
329-
mech (~gssapi.OID): the mechanism for which to retrive the
329+
mech (~gssapi.OID): the mechanism for which to retrieve the
330330
information
331331
name (bool): get the name associated with the credentials
332332
init_lifetime (bool): get the remaining initiate lifetime for
333-
the credentials
333+
the credentials in seconds
334334
accept_lifetime (bool): get the remaining accept lifetime for
335-
the credentials
335+
the credentials in seconds
336336
usage (bool): get the usage for the credentials
337337
338338
Returns:
@@ -396,9 +396,9 @@ def add(
396396
usage (str): the usage for the credentials -- either 'both',
397397
'initiate', or 'accept'
398398
init_lifetime (int): the desired initiate lifetime of the
399-
credentials, or None for indefinite
399+
credentials in seconds, or None for indefinite
400400
accept_lifetime (int): the desired accept lifetime of the
401-
credentials, or None for indefinite
401+
credentials in seconds, or None for indefinite
402402
impersonator (Credentials): the credentials to use to impersonate
403403
the given name, or None to not acquire normally
404404
(:requires-ext:`s4u`)

Diff for: gssapi/raw/creds.pyi

+10-8
Original file line numberDiff line numberDiff line change
@@ -37,17 +37,17 @@ def acquire_cred(
3737
Args:
3838
name (~gssapi.raw.names.Name): the name for which to acquire the
3939
credentials (or None for the "no name" functionality)
40-
lifetime (int): the lifetime for the credentials (or None for
41-
indefinite)
40+
lifetime (int): the lifetime in seconds for the credentials (or None
41+
for indefinite)
4242
mechs (~gssapi.raw.types.MechType): the desired mechanisms for which
4343
the credentials should work, or None for the default set
4444
usage (str): the usage type for the credentials: may be
4545
'initiate', 'accept', or 'both'
4646
4747
Returns:
4848
AcquireCredResult: the resulting credentials, the actual mechanisms
49-
with which they may be used, and their actual lifetime (or None for
50-
indefinite or not supported)
49+
with which they may be used, and their actual lifetime in seconds (or
50+
None for indefinite or not supported)
5151
5252
Raises:
5353
~gssapi.exceptions.BadMechanismError
@@ -103,9 +103,9 @@ def add_cred(
103103
usage (str): usage type for credentials. Possible values:
104104
'initiate' (default), 'accept', 'both' (failsafe).
105105
init_lifetime (int): lifetime of credentials for use in initiating
106-
security contexts (None for indefinite)
106+
security contexts in seconds (None for indefinite)
107107
accept_lifetime (int): lifetime of credentials for use in accepting
108-
security contexts (None for indefinite)
108+
security contexts in seconds (None for indefinite)
109109
mutate_input (bool): whether to mutate the input credentials (True)
110110
or produce a new set of credentials (False). Defaults to False
111111
@@ -172,8 +172,10 @@ def inquire_cred_by_mech(
172172
creds (Creds): the credentials to inspect
173173
mech (~gssapi.OID): the desired mechanism
174174
name (bool): get the Name associated with the credentials
175-
init_lifetime (bool): get the initiator TTL for the credentials
176-
accept_lifetime (bool): get the acceptor TTL for the credentials
175+
init_lifetime (bool): get the initiator TTL for the credentials (in
176+
seconds)
177+
accept_lifetime (bool): get the acceptor TTL for the credentials (in
178+
seconds)
177179
usage (bool): get the usage type of the credentials
178180
179181
Returns:

Diff for: gssapi/raw/ext_cred_store.pyi

+6-6
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@ def acquire_cred_from(
3232
See :doc:`credstore` for valid values
3333
name (~gssapi.raw.names.Name): the name associated with the
3434
credentials, or None for the default name
35-
lifetime (int): the desired lifetime of the credentials, or None
36-
for indefinite
35+
lifetime (int): the desired lifetime of the credentials in seconds, or
36+
None for indefinite
3737
mechs (list): the desired mechanisms to be used with these
3838
credentials, or None for the default set
3939
usage (str): the usage for these credentials -- either 'both',
@@ -80,10 +80,10 @@ def add_cred_from(
8080
credentials
8181
usage (str): the usage for these credentials -- either 'both',
8282
'initiate', or 'accept'
83-
init_lifetime (int): the desired initiate lifetime of the
84-
credentials, or None for indefinite
85-
accept_lifetime (int): the desired accept lifetime of the
86-
credentials, or None for indefinite
83+
init_lifetime (int): the desired initiate lifetime of the credentials
84+
in seconds, or None for indefinite
85+
accept_lifetime (int): the desired accept lifetime of the credentials
86+
in seconds, or None for indefinite
8787
8888
Returns:
8989
AcquireCredResult: the new credentials set and information about

Diff for: gssapi/raw/ext_krb5.pyi

+2-2
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ def krb5_export_lucid_sec_context(
130130
context: "SecurityContext",
131131
version: int,
132132
) -> Krb5LucidContext:
133-
"""Retuns a non-opaque version of the internal context info.
133+
"""Returns a non-opaque version of the internal context info.
134134
135135
Gets information about the Kerberos security context passed in. Currently
136136
only version 1 is known and supported by this library.
@@ -240,7 +240,7 @@ def krb5_get_tkt_flags(
240240
241241
Note:
242242
Heimdal can only get the tkt flags on the acceptor security context.
243-
MIT is able to get the tkt flags on initators and acceptors.
243+
MIT is able to get the tkt flags on initiators and acceptors.
244244
245245
Args:
246246
context (~gssapi.raw.sec_contexts.SecurityContext): the security

Diff for: gssapi/raw/ext_password.pyi

+4-4
Original file line numberDiff line numberDiff line change
@@ -24,17 +24,17 @@ def acquire_cred_with_password(
2424
Args:
2525
name (~gssapi.raw.names.Name): the name to acquire credentials for
2626
password (bytes): the password used to acquire credentialss with
27-
lifetime (int): the lifetime for the credentials (or None for
28-
indefinite)
27+
lifetime (int): the lifetime for the credentials in seconds (or None
28+
for indefinite)
2929
mechs (~gssapi.raw.types.MechType): the desired mechanisms for which
3030
the credentials should work (or None for the default set)
3131
usage (str): usage type for credentials. Possible values:
3232
'initiate' (default), 'accept', 'both' (failsafe).
3333
3434
Returns:
3535
AcquireCredResult: the resulting credentials, the actual mechanisms
36-
with which they may be used, and their actual lifetime (or None for
37-
indefinite or not supported)
36+
with which they may be used, and their actual lifetime in seconds (or
37+
None for indefinite or not supported)
3838
3939
Raises:
4040
~gssapi.exceptions.GSSError

Diff for: gssapi/raw/ext_password_add.pyi

+8-8
Original file line numberDiff line numberDiff line change
@@ -31,17 +31,17 @@ def add_cred_with_password(
3131
password (bytes): the password used to acquire credentialss with
3232
usage (str): the usage type for the credentials: may be
3333
'initiate', 'accept', or 'both'
34-
init_lifetime (int): the lifetime for the credentials to remain valid
35-
when using them to initiate security contexts (or None for
36-
indefinite)
37-
accept_lifetime (int): the lifetime for the credentials to remain
38-
valid when using them to accept security contexts (or None for
39-
indefinite)
34+
init_lifetime (int): the lifetime, in seconds, for the credentials to
35+
remain valid when using them to initiate security contexts (or None
36+
for indefinite)
37+
accept_lifetime (int): the lifetime, in seconds, for the credentials to
38+
remain valid when using them to accept security contexts (or None
39+
for indefinite)
4040
4141
Returns:
4242
AddCredResult: the actual mechanisms with which the credentials may be
43-
used, the actual initiator TTL, and the actual acceptor TTL (the TTLs
44-
may be None for indefinite or not supported)
43+
used, the actual initiator TTL in seconds, and the actual acceptor TTL
44+
in seconds (the TTLs may be None for indefinite or not supported)
4545
4646
Raises:
4747
~gssapi.exceptions.GSSError

Diff for: gssapi/raw/ext_rfc5587.pyi

+1-1
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ def display_mech_attr(
5151
"""Returns information about attributes in human readable form.
5252
5353
Args:
54-
attr (~gssapi.OID): Mechanism attribute to retrive names and
54+
attr (~gssapi.OID): Mechanism attribute to retrieve names and
5555
descriptions of
5656
5757
Returns:

Diff for: gssapi/raw/ext_rfc6680.pyi

+1-1
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ def inquire_name(
4040
) -> "InquireNameResult":
4141
"""Get information about a Name.
4242
43-
This method retrives information about the given name, including
43+
This method retrieves information about the given name, including
4444
the set of attribute names for the given name, as well as whether or
4545
not the name is a mechanism name. Additionally, if the given name is
4646
a mechanism name, the associated mechansim is returned as well.

Diff for: gssapi/raw/ext_s4u.pyi

+11-11
Original file line numberDiff line numberDiff line change
@@ -26,16 +26,16 @@ def acquire_cred_impersonate_name(
2626
permissions to impersonate the target name
2727
name (~gssapi.raw.names.Name): the name to impersonate
2828
lifetime (int): the lifetime for the credentials (or None for
29-
indefinite)
29+
indefinite) in seconds
3030
mechs (~gssapi.raw.types.MechType): the desired mechanisms for which
3131
the credentials should work (or None for the default set)
3232
usage (str): the usage type for the credentials: may be
3333
'initiate', 'accept', or 'both'
3434
3535
Returns:
3636
AcquireCredResult: the resulting credentials, the actual mechanisms
37-
with which they may be used, and their actual lifetime (or None for
38-
indefinite or not support)
37+
with which they may be used, and their actual lifetime in seconds (or
38+
None for indefinite or not support)
3939
4040
Raises:
4141
~gssapi.exceptions.GSSError
@@ -69,17 +69,17 @@ def add_cred_impersonate_name(
6969
singular and required, unlike acquireCredImpersonateName
7070
usage (str): the usage type for the credentials: may be
7171
'initiate', 'accept', or 'both'
72-
init_lifetime (int): the lifetime for the credentials to remain
73-
valid when using them to initiate security contexts (or None for
74-
indefinite)
75-
accept_lifetime (int): the lifetime for the credentials to remain
76-
valid when using them to accept security contexts (or None for
77-
indefinite)
72+
init_lifetime (int): the lifetime, in seconds, for the credentials to
73+
remain valid when using them to initiate security contexts (or None
74+
for indefinite)
75+
accept_lifetime (int): the lifetime, in seconds, for the credentials to
76+
remain valid when using them to accept security contexts (or None
77+
for indefinite)
7878
7979
Returns:
8080
AddCredResult: the actual mechanisms with which the credentials may be
81-
used, the actual initiator TTL, and the actual acceptor TTL (the TTLs
82-
may be None for indefinite or not supported)
81+
used, the actual initiator TTL in seconds, and the actual acceptor TTL
82+
in seconds (the TTLs may be None for indefinite or not supported)
8383
8484
Raises:
8585
~gssapi.exceptions.GSSError

Diff for: gssapi/raw/misc.pyi

+2-2
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ def inquire_names_for_mech(
2020
inquire_names_for_mech(mech)
2121
Get the name types supported by a mechanism.
2222
23-
This method retrives the different name types supported by
23+
This method retrieves the different name types supported by
2424
the given mechanism.
2525
2626
Args:
@@ -123,7 +123,7 @@ class GSSError(Exception):
123123
Create a new GSSError.
124124
125125
This method creates a new GSSError,
126-
retrieves the releated human-readable
126+
retrieves the related human-readable
127127
string messages, and uses the results to construct an
128128
exception message
129129

Diff for: gssapi/raw/named_tuples.py

+5-5
Original file line numberDiff line numberDiff line change
@@ -25,17 +25,17 @@ class InquireCredResult(NamedTuple):
2525
class InquireCredByMechResult(NamedTuple):
2626
"""Information about the credential for a specific mechanism."""
2727
name: Optional["g.Name"] #: The principal associated with the credential
28-
init_lifetime: Optional[int] #: Time valid for initiation
29-
accept_lifetime: Optional[int] #: Time valid for accepting
28+
init_lifetime: Optional[int] #: Time valid for initiation, in seconds
29+
accept_lifetime: Optional[int] #: Time valid for accepting, in seconds
3030
usage: Optional[str] #: How the credential can be used
3131

3232

3333
class AddCredResult(NamedTuple):
3434
"""Result of adding to a GSSAPI credential."""
3535
creds: Optional["g.Creds"] #: The credential that was generated
3636
mechs: Set[OID] #: Set of mechs the cred is for
37-
init_lifetime: int #: Time valid for initiation
38-
accept_lifetime: int #: Time valid for accepting
37+
init_lifetime: int #: Time valid for initiation, in seconds
38+
accept_lifetime: int #: Time valid for accepting, in seconds
3939

4040

4141
class DisplayNameResult(NamedTuple):
@@ -83,7 +83,7 @@ class InquireContextResult(NamedTuple):
8383
"""Information about the security context."""
8484
initiator_name: Optional["g.Name"] #: Name of the initiator
8585
target_name: Optional["g.Name"] #: Name of the acceptor
86-
lifetime: Optional[int] #: Time valid for the security context
86+
lifetime: Optional[int] #: Time valid for the security context, in seconds
8787
mech: Optional[OID] #: Mech used to create the security context
8888
flags: Optional[RequirementFlag] #: Services available for the context
8989
locally_init: Optional[bool] #: Context was initiated locally

Diff for: gssapi/raw/oids.pyi

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ class OID:
88
to the constructor. The `elements` argument should be a
99
`bytes` consisting of the BER-encoded values in the OID.
1010
11-
To retrive the underlying bytes, use the :func:`bytes`
11+
To retrieve the underlying bytes, use the :func:`bytes`
1212
function in Python 3.
1313
1414
This object is hashable, and may be compared using equality

Diff for: gssapi/raw/sec_contexts.pyi

+5-5
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,8 @@ def init_sec_context(
6262
None to use the default set: mutual_authentication and
6363
out_of_sequence_detection. This may also be an
6464
:class:`IntEnumFlagSet`
65-
lifetime (int): the request lifetime of the security context (a value
66-
of 0 or None means indefinite)
65+
lifetime (int): the request lifetime of the security context in seconds
66+
(a value of 0 or None means indefinite)
6767
channel_bindings (ChannelBindings): The channel bindings (or None for
6868
no channel bindings)
6969
input_token (bytes): the token to use to update the security context,
@@ -72,8 +72,8 @@ def init_sec_context(
7272
Returns:
7373
InitSecContextResult: the output security context, the actual mech
7474
type, the actual flags used, the output token to send to the acceptor,
75-
the actual lifetime of the context (or None if not supported or
76-
indefinite), and whether or not more calls are needed to finish the
75+
the actual lifetime of the context in seconds (or None if not supported
76+
or indefinite), and whether or not more calls are needed to finish the
7777
initiation.
7878
7979
Raises:
@@ -120,7 +120,7 @@ def accept_sec_context(
120120
Returns:
121121
AcceptSecContextResult: the resulting security context, the initiator
122122
name, the mechanism being used, the output token, the flags in use,
123-
the lifetime of the context (or None for indefinite or not
123+
the lifetime of the context in seconds (or None for indefinite or not
124124
supported), the delegated credentials (valid only if the
125125
delegate_to_peer flag is set), and whether or not further token
126126
exchanges are needed to finalize the security context.

Diff for: gssapi/sec_contexts.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -429,7 +429,8 @@ def _inquire(
429429
Args:
430430
initiator_name (bool): get the initiator name for this context
431431
target_name (bool): get the target name for this context
432-
lifetime (bool): get the remaining lifetime for this context
432+
lifetime (bool): get the remaining lifetime, in seconds, for this
433+
context
433434
mech (bool): get the :class:`MechType` used by this context
434435
flags (bool): get the flags set on this context
435436
locally_init (bool): get whether this context was locally initiated

0 commit comments

Comments
 (0)