# CVE-2021-40642: Textpattern CMS v4.8.7 and older vulnerability exists through Sensitive Cookie in HTTPS Session Without 'Secure' Attribute via textpattern/…

- Severity: Medium 4.3 (CVSS:3.1, scored by NVD) `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:N/A:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.54%, higher than 39% of CVEs (2026-11-30)
- Published: 2022-06-29T10:25:00.000Z
- Modified: 2026-06-17T04:07:12.367Z
- Weaknesses: CWE-311
- Assigned by: mitre

## Description

Textpattern CMS v4.8.7 and older vulnerability exists through Sensitive Cookie in HTTPS Session Without 'Secure' Attribute via textpattern/lib/txplib_misc.php. The secure flag is not set for txp_login session cookie in the application. If the secure flag is not set, then the cookie will be transmitted in clear-text if the user visits any HTTP URLs within the cookie's scope. An attacker may be able to induce this event by feeding a user suitable links, either directly or via another web site.

(As written by CVE List.)

## Affected

- Unspecified product: n/a
- textpattern textpattern: up to 4.8.7

## Every score

- NVD: CVSS:3.1 4.3 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:N/A:N`
- NVD: CVSS:2.0 4.3 Medium `AV:N/AC:M/Au:N/C:P/I:N/A:N`

## References

- <https://github.com/textpattern/textpattern/commit/211fab0093999f59b0b61682aa988ac7d8337aa9> (patch, third-party-advisory)
- <https://www.huntr.dev/bounties/aadbe434-a376-443b-876f-2a1cbab7847b/> (permissions-required, third-party-advisory)

## Sources

- CVE List: [CVE-2021-40642](https://www.cve.org/CVERecord?id=CVE-2021-40642), CVE Terms of Use, modified 2024-08-04
- NVD: [CVE-2021-40642](https://nvd.nist.gov/vuln/detail/CVE-2021-40642), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2021-40642 · Whole record: https://cve.day/CVE-2021-40642.json · Rebuilt by cve.day 2026-11-25T22:58:07.692Z
