Skip to content
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

Improve local IP detection #33031

Merged
merged 4 commits into from
Jul 26, 2022
Merged

Improve local IP detection #33031

merged 4 commits into from
Jul 26, 2022

Conversation

come-nc
Copy link
Contributor

@come-nc come-nc commented Jun 27, 2022

Signed-off-by: Côme Chilliet [email protected]

@come-nc come-nc added the 3. to review Waiting for reviews label Jun 27, 2022
@come-nc come-nc added this to the Nextcloud 25 milestone Jun 27, 2022
@come-nc come-nc requested a review from a team June 27, 2022 14:50
@come-nc come-nc self-assigned this Jun 27, 2022
@come-nc come-nc requested review from PVince81, ArtificialOwl and icewind1991 and removed request for a team June 27, 2022 14:50
@come-nc
Copy link
Contributor Author

come-nc commented Jun 27, 2022

/backport to stable24

@come-nc
Copy link
Contributor Author

come-nc commented Jun 27, 2022

/backport to stable23

@come-nc
Copy link
Contributor Author

come-nc commented Jun 27, 2022

/backport to stable22

@come-nc come-nc force-pushed the fix/improve-local-ip-detection branch from ee4fba1 to f1037b9 Compare June 27, 2022 15:14
@come-nc come-nc requested a review from tcitworld June 28, 2022 09:36
@kesselb
Copy link
Contributor

kesselb commented Jun 28, 2022

Does it make sense to add the $localIps check to

if (!filter_var($ipv4Address, FILTER_VALIDATE_IP, FILTER_FLAG_NO_PRIV_RANGE | FILTER_FLAG_NO_RES_RANGE)) {
as well?

@come-nc
Copy link
Contributor Author

come-nc commented Jun 28, 2022

Good catch, I suppose it makes sense

@come-nc
Copy link
Contributor Author

come-nc commented Jul 12, 2022

/rebase

@github-actions
Copy link
Contributor

Possible performance regression detected

Show Output
1 queries added

≠ /remote.php/dav/files/test with 1 queries added
  + UPDATE "oc_preferences" SET "configvalue" = :dcValue1 WHERE ("userid" = :dcValue2) AND ("appid" = :dcValue3) AND ("configkey" = :dcValue4)
= /remote.php/dav/files/test/test.txt
= /remote.php/dav/files/test/many_files
= /remote.php/dav/files/test/new_file.txt
= /remote.php/dav/files/test/new_file.txt

@github-actions
Copy link
Contributor

Possible performance regression detected

Show Output
2 queries added

≠ /remote.php/dav/files/test with 1 queries added
  + UPDATE "oc_preferences" SET "configvalue" = :dcValue1 WHERE ("userid" = :dcValue2) AND ("appid" = :dcValue3) AND ("configkey" = :dcValue4)
≠ /remote.php/dav/files/test/test.txt with 1 queries removed
  - UPDATE "oc_preferences" SET "configvalue" = :dcValue1 WHERE ("userid" = :dcValue2) AND ("appid" = :dcValue3) AND ("configkey" = :dcValue4)
≠ /remote.php/dav/files/test/many_files with 1 queries added
  + UPDATE "oc_preferences" SET "configvalue" = :dcValue1 WHERE ("userid" = :dcValue2) AND ("appid" = :dcValue3) AND ("configkey" = :dcValue4)
= /remote.php/dav/files/test/new_file.txt
≠ /remote.php/dav/files/test/new_file.txt with 1 queries added
  + UPDATE "oc_preferences" SET "configvalue" = :dcValue1 WHERE ("userid" = :dcValue2) AND ("appid" = :dcValue3) AND ("configkey" = :dcValue4)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3. to review Waiting for reviews
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants