From 3ad28b2771fb86a3cd356f36b4e1a4fbc84f89bf Mon Sep 17 00:00:00 2001 From: Richard Markiewicz Date: Fri, 21 Feb 2025 13:32:38 -0500 Subject: [PATCH] [core,credssp_auth] Fix faulty string length check in `credssp_auth_client_init_cred_attributes` --- libfreerdp/core/credssp_auth.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libfreerdp/core/credssp_auth.c b/libfreerdp/core/credssp_auth.c index adda839c5..ab82d8ec2 100644 --- a/libfreerdp/core/credssp_auth.c +++ b/libfreerdp/core/credssp_auth.c @@ -207,7 +207,7 @@ static BOOL credssp_auth_client_init_cred_attributes(rdpCredsspAuth* auth) SSIZE_T str_size = 0; str_size = ConvertUtf8ToWChar(auth->kerberosSettings.kdcUrl, NULL, 0); - if ((str_size <= 0) || (str_size <= UINT16_MAX / 2)) + if ((str_size <= 0) || (str_size >= UINT16_MAX / 2)) return FALSE; str_size++;