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

Use negative lookahead to allow openssl_* functions #80

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

dero
Copy link

@dero dero commented May 11, 2017

The vary_cache_on_function method will disallow all functions containing the substring open. This is likely to prevent the user from creating functions that use fopen, opendir and similar. However it also prevents users from using all functions from the openssl_* family.

Our use case is the following:

  • On a VIP site we want to differentiate cache variants for premium and non-premium users.
  • We want to be able to use openssl_decrypt to decrypt a userdata cookie and then we set the variant based on whether the current user has purchased a subscription or not.

This PR adds a negative lookahead to allow the openssl_* functions inside vary_cache_on_function.

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.

1 participant