The GSSAPI support in 1.15 and master contains a few minor bugs.
This pull request includes one commit for each bug.
Add a missing import.
Fix the documentation of both implementations of ssh_check_mic.
The method raises an exception, if the check fails and has no
Fix an uninitialised variable usage and simplify the code.
Switch kex_gss from using PyCrypto's Random to using os.urandom.
Coverage increased (+0.16%) to 72.71% when pulling c158db9 on akruis:1.15-gssfixes into ca0fd10 on paramiko:1.15.
I'm running this locally - paramiko as installed from pip is broken for GSS auth at the moment. This should be a high-priority merge.
FYI, without at LEAST accepting the change in c158db9, GSSAPI support is completely broken.
Referencing #584 for linkage, it's not directly related as far as I can tell (insofar as the newer GSSAPI module breaking things is not the same as this bundle of fixes) but presumably without fixing #584, many users will not be able to reap the benefits of these fixes here.
I don't have the ability to readily test GSSAPI functionality (would like to sometime though, ugh) but since I've got at least a few people in here saying the PR fixes it, I'm going to trust them and just-merge :)
Ah, #584 was a little confused, if people are actually following instructions and pip installing python-gssapi and not gssapi, there's no problem currently. Still good to have these linked tho.
Changelog re #496