Repository navigation
mod_session_cookie: Keep the loaded session with SessionCookieRemove On [2.4.x] - #1083
Merged
arturobernalg merged 1 commit intoNov 26, 2026
Conversation
…On (apache#1080) mod_session_cookie: Keep the loaded session with SessionCookieRemove On. Since r1938655 a second session load with SessionCookieRemove On dropped the session cached in the request notes and parsed the cookie again, which the first load had already removed. Changes made to the session in between were lost, so a mod_auth_form login answered with no Set-Cookie. Reuse the cached session and only remove the cookie from the current request's headers. PR 70376 (cherry picked from commit 87b7986)
covener
approved these changes
Nov 25, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Backport of #1080 (87b7986 on trunk) to 2.4.x.
Since the CVE-2026-47360 fix, a mod_auth_form login with SessionCookieRemove On answers with no Set-Cookie. The session_cookie_load() code is the same on 2.4.x, so the patch applies as is.
2.4.x has no test/modules/session yet, so this adds the package from trunk (without test_001, which covers a trunk-only feature) plus test_002. The /form-remove/ case fails on 2.4.x without the fix and passes with it.
BZ: https://bz.apache.org/bugzilla/show_bug.cgi?id=70376
(see
SECURITY.mdandhttps://www.apache.org/security/#reporting-a-vulnerability).
APLOGNO()tag;numbers are assigned by a committer at merge time (see
docs/log-message-tags/README).changes-entries/*.txtfile is included,following the template in
README.CHANGES(not needed otherwise).test/modules/xxxdirectory matching themodules/xxxmodule source,or
test/modules/corefor core server changes. On Unix, verify thesepass locally with e.g.
make check-pytest PYTEST_DIRS=test/modules/xxx.