Skip to content

Commit 8d6e00b

Browse files
committed
Update behavior.py
1 parent a6a4ee6 commit 8d6e00b

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

modules/processing/behavior.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1272,6 +1272,8 @@ def event_apicall(self, call, process):
12721272
if isinstance(url, str) and url.strip():
12731273
u = _extract_first_url(url) or url.strip()
12741274
host = _host_from_url(u)
1275+
if not host and "://" not in u:
1276+
host = _host_from_url(f"http://{u}")
12751277
if host:
12761278
_add_http_host(self.http_host_map, host, pinfo, sock=sock)
12771279

@@ -1282,8 +1284,8 @@ def event_apicall(self, call, process):
12821284
if host2:
12831285
_add_http_host(self.http_host_map, host2, pinfo, sock=sock)
12841286

1285-
if api in ("internetconnectw", "internetconnecta"):
1286-
server_name = _get_arg_any(args_map, "ServerName", "lpszServerName")
1287+
if api in ("internetconnectw", "internetconnecta", "winhttpconnect"):
1288+
server_name = _get_arg_any(args_map, "ServerName", "lpszServerName", "szServerName", "pszServerName")
12871289
if server_name:
12881290
_add_http_host(self.http_host_map, server_name, pinfo, sock=sock)
12891291

0 commit comments

Comments
 (0)