---
title: "CVE-2017-7189"
canonical_url: "https://pkgseek.com/security/CVE-2017-7189"
locale: "en"
source: "pkgseek"
entity_type: "cve"
severity: "high"
---

# CVE-2017-7189

main/streams/xp_socket.c in PHP 7.x before 2017-03-07 misparses fsockopen calls, such as by interpreting fsockopen('127.0.0.1:80', 443) as if the address/port were 127.0.0.1:80:443, which is later truncated to 127.0.0.1:80. This behavior has a security risk if the explicitly provided port number (i.e., 443 in this example) is hardcoded into an application as a security policy, but the hostname argument (i.e., 127.0.0.1:80 in this example) is obtained from untrusted input.

CVE-2017-7189 is rated HIGH (7.5), with 21 indexed affected package builds across 1 distributions.

- **Severity / Score**: HIGH (7.5)
- **Affected builds**: 21
- **Affected distros**: 1
- **Distros with fixed_in**: None recorded in sample

## Affected Packages

| Distribution | Release | Package | Version | Fixed In |
| --- | --- | --- | --- | --- |
| Ubuntu | jammy | libapache2-mod-php8.1 | 8.1.2-1ubuntu2 | — |
| Ubuntu | jammy | php8.1 | 8.1.2-1ubuntu2 | — |
| Ubuntu | jammy | php8.1-cgi | 8.1.2-1ubuntu2 | — |
| Ubuntu | jammy | php8.1-cli | 8.1.2-1ubuntu2 | — |
| Ubuntu | jammy | php8.1-common | 8.1.2-1ubuntu2 | — |
| Ubuntu | jammy | php8.1-curl | 8.1.2-1ubuntu2 | — |
| Ubuntu | jammy | php8.1-dev | 8.1.2-1ubuntu2 | — |
| Ubuntu | jammy | php8.1-gd | 8.1.2-1ubuntu2 | — |
| Ubuntu | jammy | php8.1-gmp | 8.1.2-1ubuntu2 | — |
| Ubuntu | jammy | php8.1-ldap | 8.1.2-1ubuntu2 | — |
| Ubuntu | jammy | php8.1-mbstring | 8.1.2-1ubuntu2 | — |
| Ubuntu | jammy | php8.1-mysql | 8.1.2-1ubuntu2 | — |
| Ubuntu | jammy | php8.1-odbc | 8.1.2-1ubuntu2 | — |
| Ubuntu | jammy | php8.1-opcache | 8.1.2-1ubuntu2 | — |
| Ubuntu | jammy | php8.1-pgsql | 8.1.2-1ubuntu2 | — |
| Ubuntu | jammy | php8.1-pspell | 8.1.2-1ubuntu2 | — |
| Ubuntu | jammy | php8.1-readline | 8.1.2-1ubuntu2 | — |
| Ubuntu | jammy | php8.1-snmp | 8.1.2-1ubuntu2 | — |
| Ubuntu | jammy | php8.1-sqlite3 | 8.1.2-1ubuntu2 | — |
| Ubuntu | jammy | php8.1-tidy | 8.1.2-1ubuntu2 | — |
| Ubuntu | jammy | php8.1-xml | 8.1.2-1ubuntu2 | — |
