Skip to content

Conversation

@simo5
Copy link
Contributor

@simo5 simo5 commented Jun 16, 2015

Properly restrict the mechanism we want to allow even if the client misuses the Negotiate key word to perform raw NTLM/Kerb/Whatever authentication instead of using SPNEGO.

Implemented by aqcuiring creds only for allowed_mechs and by
explicity adding spnego to the allowed_mechs set (while still
restricting spengo only to the allowed mechanism as before).
If no explicit allowed mechanism is set in configuration just ask
gssapi for a list of known mechanisms and use that. do not try to
artificially acquire credentials as ultimatily all that does is
just call gss_inidicate_mechs() internally.

Do not store the result of gss_inidicate_mechs() on cfg->allowed_mechs
as that would lead to a leak fiven cfg->allowed_mechs is considered
allocated on a memory pool, while gss_inidate_mechs()s results are not.

Signed-off-by: Simo Sorce <simo@redhat.com>
This was referenced Jun 16, 2015
simo5 added 2 commits June 16, 2015 16:06
Try each allowed mechanism explicitly in a loop including sourcing
the server name per mechanism to insure the proper name type is
used in the accept.
Otherwise secondary mechanims will fail to work.

Fixes gssapi#43

Signed-off-by: Simo Sorce <simo@redhat.com>
@simo5 simo5 closed this in 6e4513d Jun 19, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants