Movatterモバイル変換


[0]ホーム

URL:


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

Sign up
Appearance settings

[Dotenv] Get env using $_SERVER to work with fastcgi_param and workaround thread safety issues#23949

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
fabpot merged 1 commit intosymfony:3.3fromnicolas-grekas:no-getenv
Aug 22, 2017

Conversation

@nicolas-grekas
Copy link
Member

QA
Branch?3.3
Bug fix?yes
New feature?no
BC breaks?no
Deprecations?no
Tests pass?yes
Fixed tickets#23502
LicenseMIT
Doc PR-

getenv() is not thread safe, and doesn't work withfastcgi_param, see links in linked issue.

putenv("$name=$value");
$_ENV[$name] =$value;
$_SERVER[$name] =$value;
if ($notHttpName) {
Copy link
MemberAuthor

@nicolas-grekasnicolas-grekasAug 22, 2017
edited
Loading

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

with this, env vars that start withHTTP_* do not populate$_SERVER anymore.
this is to mitigate security issues with$_SERVER mixing several sources (env+http headers+etc).

@fabpot
Copy link
Member

Thank you@nicolas-grekas.

@fabpotfabpot merged commitf76e420 intosymfony:3.3Aug 22, 2017
fabpot added a commit that referenced this pull requestAug 22, 2017
… and workaround thread safety issues (nicolas-grekas)This PR was merged into the 3.3 branch.Discussion----------[Dotenv] Get env using $_SERVER to work with fastcgi_param and workaround thread safety issues| Q             | A| ------------- | ---| Branch?       | 3.3| Bug fix?      | yes| New feature?  | no| BC breaks?    | no| Deprecations? | no| Tests pass?   | yes| Fixed tickets |#23502| License       | MIT| Doc PR        | -`getenv()` is not thread safe, and doesn't work with `fastcgi_param`, see links in linked issue.Commits-------f76e420 [Dotenv] Get env using $_SERVER to work with fastcgi_param and workaround thread safety issues
@nicolas-grekasnicolas-grekas deleted the no-getenv branchAugust 22, 2017 16:01
@fabpotfabpot mentioned this pull requestAug 28, 2017
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@fabpotfabpotfabpot approved these changes

+1 more reviewer

@SimperfitSimperfitSimperfit approved these changes

Reviewers whose approvals may not affect merge requirements

Assignees

No one assigned

Projects

None yet

Milestone

3.3

Development

Successfully merging this pull request may close these issues.

4 participants

@nicolas-grekas@fabpot@Simperfit@carsonbot

[8]ページ先頭

©2009-2025 Movatter.jp