-
Notifications
You must be signed in to change notification settings - Fork 9.4k
Store longer X-Forwarded-For header #27221
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
Store longer X-Forwarded-For header #27221
Conversation
Hi @ihor-sviziev. Thank you for your contribution
For more details, please, review the Magento Contributor Guide documentation. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice catch, @ihor-sviziev!
The issue is relevant and must be fixed.
I guess this change can be covered by an integration test. We can either update an existing fixture or create a new one.
What do you think?
Thank you!
Will check it little bit later
…On Wed, 11 Mar 2020 at 10:24, Dmytro Cheshun ***@***.***> wrote:
***@***.**** requested changes on this pull request.
Nice catch, @ihor-sviziev <https://github.com/ihor-sviziev>!
The issue is relevant is must be fixed.
I guess this change can be covered by an integration test. We can either
update an existing fixture
<https://github.com/magento/magento2/blob/2.4-develop/dev/tests/integration/testsuite/Magento/Sales/_files/order.php>
or create a new one.
What do you think?
Thank you!
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#27221?email_source=notifications&email_token=AAOJOUOV6INLYACV7JJ4C73RG5DEPA5CNFSM4LEZLOX2YY3PNVWWK3TUL52HS4DFWFIHK3DMKJSXC5LFON2FEZLWNFSXPKTDN5WW2ZLOORPWSZGOCY2KTLI#pullrequestreview-372550061>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAOJOUJ7NV72HWPI7VULNHTRG5DEPANCNFSM4LEZLOXQ>
.
|
Unfortunately I don't have free time for implementing tests for my change. @engcom-Golf @engcom-Charlie could you help with test coverage? |
@magento run all tests |
@engcom-Charlie maybe it's better to have more real value, like IPV6 address, or multiple ipv4 IPs? |
@ihor-sviziev, |
@dmytro-ch could you review again this pr? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The changes look good to me. Thank you!
Hi @dmytro-ch, thank you for the review. |
Hi @ihor-sviziev, thank you for your contribution! |
Description (*)
Header X-Forwarded-For could contains multiple IPs
This PR allow to store longer values
For instance in my DB I had value like this:
4x.xxx.xx.xx, 1xx.xxx.xx.xx, 10.
, where xxx - masked IP address of customer, while last IP address was just cut due to limit on the field in DB.Related Pull Requests
N/A
Fixed Issues (if relevant)
Fixes #28693
Manual testing scenarios (*)
Actual result:
X-Forwarded-For header is cut
Expected result:
It shouldn't be cut
Questions or comments
Ma
Contribution checklist (*)