Bug 1768463 (CVE-2019-17455)

Summary: CVE-2019-17455 libntlm: stack-based buffer overflow in buildSmbNtlmAuthRequest in smbutil.c
Product: [Other] Security Response Reporter: Guilherme de Almeida Suckevicz <gsuckevi>
Component: vulnerabilityAssignee: Red Hat Product Security <security-response-team>
Status: CLOSED ERRATA QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: unspecifiedCC: bkearney, gdeschner, kevin, moceap, tlestach
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: libntlm 1.6 Doc Type: If docs needed, set a value
Doc Text:
A flaw was found in the libntlm NTLM library where it was vulnerable to a buffer overflow in the buildSmbNtlmAuthRequest_userlen() function. If an application using this library does not check input length before calling the function, an attacker could use this flaw to send a specially crafted request that could crash the application, or possibly trigger code execution.
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-10-25 09:54:12 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1768464, 1768465, 1771558, 1771559, 1771560    
Bug Blocks: 1768466    

Description Guilherme de Almeida Suckevicz 2019-11-04 14:06:43 UTC
Libntlm through 1.5 relies on a fixed buffer size for tSmbNtlmAuthRequest, tSmbNtlmAuthChallenge, and tSmbNtlmAuthResponse read and write operations, as demonstrated by a stack-based buffer over-read in buildSmbNtlmAuthRequest in smbutil.c for a crafted NTLM request.

Reference:
https://gitlab.com/jas/libntlm/issues/2

Comment 1 Guilherme de Almeida Suckevicz 2019-11-04 14:07:04 UTC
Created libntlm tracking bugs for this issue:

Affects: epel-7 [bug 1768465]
Affects: fedora-all [bug 1768464]

Comment 4 Cedric Buissart 2020-02-05 17:24:47 UTC
Mitigation:

The calling application must verify that the input  username and domain fit in the 1024 byte buffer.

Comment 5 Cedric Buissart 2020-03-19 11:29:31 UTC
Statement:

The vulnerability is rated Medium because no package in Red Hat Enterprise Linux versions 6 and 7 is using Libntlm. Most 3rd party applications using Libntlm are command line clients and would be affected via a command line option or a configuration file, which are local vectors.