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 convenience function for one-off token evaluations to avoid too-long filenames and possible privacy issues #21140

Merged
merged 1 commit into from
Aug 14, 2021

Conversation

demeritcowboy
Copy link
Contributor

Overview

Addresses conversation at #21064 (comment) and uses same idea as in #16733

Before

Filename like this, that also possibly unnecessarily caches personal info.

templates_c/en_US//%%27/27E/27EEDEE2%%string%3A%0A++++++first+name+%3D+Alice%0A++++++receive_date+%3D+February+1st%2C+2015+12%3A00+AM%0A++++++contribution+status+id+%3D+1%0A++++++new+style+status+%3D+Completed%0A++++++new+style+label+%3D+Completed+Label%2A%2A%0A++++++id+1%0A++++++contribution_id++-+not+valid+for+action+schedule%0A++++++cancel+date+August+9th%2C+2021+12%3A00+AM%0A++++++source+SSF%0A++++++legacy+source+%0A++++++financial+type+id+%3D+1%0A++++++financial+type+name+%3D+Donation%0A++++++financial+type+label+%3D+Donation%0A++++++payment+instrument+id+%3D+4%0A++++++payment+instrument+name+%3D+Check%0A++++++payment+instrument+label+%3D+Check%0A++++++non_deductible_amount+%3D+%E2%82%AC+10.00%0A++++++total_amount+%3D+%E2%82%AC+100.00%0A++++++net_amount+%3D+%E2%82%AC+95.00%0A++++++fee_amount+%3D+%E2%82%AC+5.00.php

After

Filename looks something like eval+var%3D%24smartySingleUseString.php

Technical Details

Comments

Has test in the sense it came up during a form of stress-testing with the tests and at least one of them calls this.

@civibot civibot bot added the master label Aug 14, 2021
@civibot
Copy link

civibot bot commented Aug 14, 2021

(Standard links)

@eileenmcnaughton
Copy link
Contributor

Ah - you had already decided to put this up - yes agree!

@eileenmcnaughton eileenmcnaughton merged commit 199c995 into civicrm:master Aug 14, 2021
@demeritcowboy demeritcowboy deleted the smarty-long branch August 15, 2021 00:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants