From f40385e0b2eee49a711a8fe42e698f92a6d831a0 Mon Sep 17 00:00:00 2001 From: Michael Osipov Date: Wed, 22 Dec 2021 12:57:55 +0100 Subject: [PATCH] Drop out of sequence detection (#38) SPNEGO over HTTP does not use any message wrapping, therefore requesting out of sequence detection doesn't make sense. This fixes #38 Signed-off-by: Michael Osipov --- requests_gssapi/gssapi_.py | 2 +- test_requests_gssapi.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/requests_gssapi/gssapi_.py b/requests_gssapi/gssapi_.py index 6c56e66..aa7a87b 100644 --- a/requests_gssapi/gssapi_.py +++ b/requests_gssapi/gssapi_.py @@ -129,7 +129,7 @@ def generate_request_header(self, response, host, is_preemptive=False): """ - gssflags = [gssapi.RequirementFlag.out_of_sequence_detection] + gssflags = [] if self.delegate: gssflags.append(gssapi.RequirementFlag.delegate_to_peer) if self.mutual_authentication != DISABLED: diff --git a/test_requests_gssapi.py b/test_requests_gssapi.py index 02467ce..bf15a9c 100644 --- a/test_requests_gssapi.py +++ b/test_requests_gssapi.py @@ -28,7 +28,7 @@ # construction, so construct a *really* fake one fail_resp = Mock(side_effect=gssapi.exceptions.GSSError(0, 0)) -gssflags = [gssapi.RequirementFlag.out_of_sequence_detection] +gssflags = [] mutflags = gssflags + [gssapi.RequirementFlag.mutual_authentication] gssdelegflags = gssflags + [gssapi.RequirementFlag.delegate_to_peer]