{"api_version":"1","generated_at":"2026-07-24T01:16:05+00:00","cve":"CVE-2022-39284","urls":{"html":"https://cve.report/CVE-2022-39284","api":"https://cve.report/api/cve/CVE-2022-39284.json","docs":"https://cve.report/api","cve_org":"https://www.cve.org/CVERecord?id=CVE-2022-39284","nvd":"https://nvd.nist.gov/vuln/detail/CVE-2022-39284"},"summary":{"title":"CVE-2022-39284","description":"CodeIgniter is a PHP full-stack web framework. In versions prior to 4.2.7 setting `$secure` or `$httponly` value to `true` in `Config\\Cookie` is not reflected in `set_cookie()` or `Response::setCookie()`. As a result cookie values are erroneously exposed to scripts. It should be noted that this vulnerability does not affect session cookies. Users are advised to upgrade to v4.2.7 or later. Users unable to upgrade are advised to manually construct their cookies either by setting the options in code or by constructing Cookie objects. Examples of each workaround are available in the linked GHSA.","state":"PUBLIC","assigner":"security-advisories@github.com","published_at":"2022-10-06 20:15:00","updated_at":"2023-07-11 20:51:00"},"problem_types":["CWE-732"],"metrics":[],"references":[{"url":"https://codeigniter4.github.io/userguide/helpers/cookie_helper.html#set_cookie","name":"https://codeigniter4.github.io/userguide/helpers/cookie_helper.html#set_cookie","refsource":"MISC","tags":[],"title":"Cookie Helper — CodeIgniter 4.2.0 documentation","mime":"text/html","httpstatus":"200","archivestatus":"200"},{"url":"https://codeigniter4.github.io/userguide/outgoing/response.html#CodeIgniter%5CHTTP%5CResponse::setCookie","name":"https://codeigniter4.github.io/userguide/outgoing/response.html#CodeIgniter%5CHTTP%5CResponse::setCookie","refsource":"MISC","tags":[],"title":"HTTP Responses — CodeIgniter 4.2.0 documentation","mime":"text/html","httpstatus":"200","archivestatus":"200"},{"url":"https://github.com/codeigniter4/CodeIgniter4/issues/6540","name":"https://github.com/codeigniter4/CodeIgniter4/issues/6540","refsource":"MISC","tags":[],"title":"Bug: set_cookie not using default value of $secure from config · Issue #6540 · codeigniter4/CodeIgniter4 · GitHub","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"https://github.com/codeigniter4/CodeIgniter4/security/advisories/GHSA-745p-r637-7vvp","name":"https://github.com/codeigniter4/CodeIgniter4/security/advisories/GHSA-745p-r637-7vvp","refsource":"CONFIRM","tags":[],"title":"Secure or HttpOnly flag set in Config\\Cookie is not reflected in Cookies issued in Codeigniter4 · Advisory · codeigniter4/CodeIgniter4 · GitHub","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"https://www.cve.org/CVERecord?id=CVE-2022-39284","name":"https://www.cve.org/CVERecord?id=CVE-2022-39284","refsource":"MISC","tags":[],"title":"cve-website","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"https://developer.mozilla.org/en-US/docs/Web/HTTP/Cookies#restrict_access_to_cookies","name":"https://developer.mozilla.org/en-US/docs/Web/HTTP/Cookies#restrict_access_to_cookies","refsource":"MISC","tags":[],"title":"Using HTTP cookies - HTTP | MDN","mime":"text/html","httpstatus":"200","archivestatus":"200"},{"url":"https://github.com/codeigniter4/CodeIgniter4/pull/6544","name":"https://github.com/codeigniter4/CodeIgniter4/pull/6544","refsource":"MISC","tags":[],"title":"fix: set_cookie() does not use Config\\Cookie values by kenjis · Pull Request #6544 · codeigniter4/CodeIgniter4 · GitHub","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2022-39284","name":"NVD vulnerability detail","refsource":"NVD","tags":["canonical","analysis"]}],"affected":[],"timeline":[],"solutions":[],"workarounds":[],"exploits":[],"credits":[],"nvd_cpes":[{"cve_year":"2022","cve_id":"39284","vulnerable":"1","versionEndIncluding":"","cpe1":"cpe","cpe2":"2.3","cpe3":"a","cpe4":"codeigniter","cpe5":"codeigniter","cpe6":"*","cpe7":"*","cpe8":"*","cpe9":"*","cpe10":"*","cpe11":"*","cpe12":"*","cpe13":"*"}],"vendor_comments":[],"enrichments":{"kev":null,"epss":null,"legacy_qids":[]},"source_records":{"cve_program":{"CVE_data_meta":{"ASSIGNER":"security-advisories@github.com","ID":"CVE-2022-39284","STATE":"PUBLIC","TITLE":"Secure or HttpOnly flag set in Config\\Cookie is not reflected in Cookies issued in Codeigniter4"},"affects":{"vendor":{"vendor_data":[{"product":{"product_data":[{"product_name":"CodeIgniter4","version":{"version_data":[{"version_value":"< 4.2.7"}]}}]},"vendor_name":"codeigniter4"}]}},"data_format":"MITRE","data_type":"CVE","data_version":"4.0","description":{"description_data":[{"lang":"eng","value":"CodeIgniter is a PHP full-stack web framework. In versions prior to 4.2.7 setting `$secure` or `$httponly` value to `true` in `Config\\Cookie` is not reflected in `set_cookie()` or `Response::setCookie()`. As a result cookie values are erroneously exposed to scripts. It should be noted that this vulnerability does not affect session cookies. Users are advised to upgrade to v4.2.7 or later. Users unable to upgrade are advised to manually construct their cookies either by setting the options in code or by constructing Cookie objects. Examples of each workaround are available in the linked GHSA."}]},"impact":{"cvss":{"attackComplexity":"HIGH","attackVector":"NETWORK","availabilityImpact":"NONE","baseScore":2.6,"baseSeverity":"LOW","confidentialityImpact":"LOW","integrityImpact":"NONE","privilegesRequired":"LOW","scope":"UNCHANGED","userInteraction":"REQUIRED","vectorString":"CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:U/C:L/I:N/A:N","version":"3.1"}},"problemtype":{"problemtype_data":[{"description":[{"lang":"eng","value":"CWE-665: Improper Initialization"}]}]},"references":{"reference_data":[{"name":"https://github.com/codeigniter4/CodeIgniter4/security/advisories/GHSA-745p-r637-7vvp","refsource":"CONFIRM","url":"https://github.com/codeigniter4/CodeIgniter4/security/advisories/GHSA-745p-r637-7vvp"},{"name":"https://github.com/codeigniter4/CodeIgniter4/issues/6540","refsource":"MISC","url":"https://github.com/codeigniter4/CodeIgniter4/issues/6540"},{"name":"https://github.com/codeigniter4/CodeIgniter4/pull/6544","refsource":"MISC","url":"https://github.com/codeigniter4/CodeIgniter4/pull/6544"},{"name":"https://codeigniter4.github.io/userguide/helpers/cookie_helper.html#set_cookie","refsource":"MISC","url":"https://codeigniter4.github.io/userguide/helpers/cookie_helper.html#set_cookie"},{"name":"https://codeigniter4.github.io/userguide/outgoing/response.html#CodeIgniter%5CHTTP%5CResponse::setCookie","refsource":"MISC","url":"https://codeigniter4.github.io/userguide/outgoing/response.html#CodeIgniter%5CHTTP%5CResponse::setCookie"},{"name":"https://developer.mozilla.org/en-US/docs/Web/HTTP/Cookies#restrict_access_to_cookies","refsource":"MISC","url":"https://developer.mozilla.org/en-US/docs/Web/HTTP/Cookies#restrict_access_to_cookies"}]},"source":{"advisory":"GHSA-745p-r637-7vvp","discovery":"UNKNOWN"}},"nvd":{"publishedDate":"2022-10-06 20:15:00","lastModifiedDate":"2023-07-11 20:51:00","problem_types":["CWE-732"],"metrics":{"baseMetricV3":{"cvssV3":{"version":"3.1","vectorString":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:N","attackVector":"NETWORK","attackComplexity":"LOW","privilegesRequired":"LOW","userInteraction":"NONE","scope":"UNCHANGED","confidentialityImpact":"LOW","integrityImpact":"NONE","availabilityImpact":"NONE","baseScore":4.3,"baseSeverity":"MEDIUM"},"exploitabilityScore":2.8,"impactScore":1.4}},"configurations":{"CVE_data_version":"4.0","nodes":[{"operator":"OR","children":[],"cpe_match":[{"vulnerable":true,"cpe23Uri":"cpe:2.3:a:codeigniter:codeigniter:*:*:*:*:*:*:*:*","versionStartIncluding":"4.0.0","versionEndExcluding":"4.2.7","cpe_name":[]}]}]}},"legacy_mitre":{"record":null,"notes":[]}}}