Skip to content

fix sid generation in cookie middleware #5

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Dec 21, 2022

Conversation

yani
Copy link
Contributor

@yani yani commented Dec 21, 2022

I had to change this in order for sid generation to work.

Is there a specific reason for using the translated native sid generation from the session extension?
I feel a normal random string generator would be better. And ignore session.sid_length and session.sid_bits_per_character.

@compwright compwright self-requested a review December 21, 2022 03:25
@compwright
Copy link
Owner

Is there a specific reason for using the translated native sid generation from the session extension?

I'm confused by your question, can you elaborate?

@compwright compwright merged commit 0fe1c63 into compwright:master Dec 21, 2022
@yani
Copy link
Contributor Author

yani commented Dec 21, 2022

Is there a specific reason for using the translated native sid generation from the session extension?

I'm confused by your question, can you elaborate?

Why doesn't SessionId->create_sid() use a simple string generator instead of the bits and bytes way of doing it?

(I have this coded btw, have a look at: 9b8e5e5
I even have a nice PR pre-written for it :))

@compwright
Copy link
Owner

@yani it's done that way because that's how https://www.php.net/manual/en/function.session-create-id.php does it

compwright pushed a commit that referenced this pull request Dec 29, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants