From e755d3f144ebb6bd182188610fd74d973a0bfde2 Mon Sep 17 00:00:00 2001 From: Nick Porter Date: Fri, 14 Jul 2023 10:23:05 +0100 Subject: [PATCH] Set header flags correctly if body is not encrypted --- tacacs_plus/client.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tacacs_plus/client.py b/tacacs_plus/client.py index 19c593d..e024ab0 100644 --- a/tacacs_plus/client.py +++ b/tacacs_plus/client.py @@ -109,7 +109,8 @@ def send(self, body, req_type, seq_no=1): req_type, self.session_id, len(body.packed), - seq_no=seq_no + seq_no=seq_no, + flags=(0 if self.secret else 1) ) packet = TACACSPacket(header, body.packed, self.secret)