Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

PHP Session Cookie gets set despite setting use_cookies = false #45105

Copy link
Copy link
Closed
@hoebelix

Description

@hoebelix
Issue body actions

Symfony version(s) affected

5.4

Description

Similar as in #13668, I have a small AP and I need to maintain a session without using cookies. In my case, the client passes the session ID in a custom HTTP header.

The PR #15123 added support for this use case. But despite the setting use_cookies: false, Symfony sets a PHP session cookie. This seems to be the case at least since commit b3e4f66

This commit also seems to always read the session id from the cookies - independently of use_cookies = false.

How to reproduce

In framework.yaml set

framework:
    session:
        use_cookies: false

and somewhere in a controller read the session via

$request->getSession()->all()

Possible Solution

No response

Additional Context

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.