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

Consent management: use last consent provided by CMP on timeout (6.29.x) #8540

Merged
merged 3 commits into from
Jun 10, 2022

Conversation

dgirardi
Copy link
Collaborator

@dgirardi dgirardi commented Jun 8, 2022

Type of change

  • Bugfix

Description of change

This changes the timeout behavior of the consentManagement module (for TCF v2 only).

If after gdpr.timeout the user has not provided consent (and therefore the CMP did not emit a tcloaded or useractioncomplete event), use the last consent data provided by any other CMP event instead of null.

According to the TCF spec, CMPs should always emit at least one event regardless of what the user does.

Note: The addEventListener callback shall be immediately called upon registration with the current TC data, even if the CMP status is loading and the CMP has incomplete TC Data, so that the calling script may have access to its registered listenerId. Furthermore, on every TC String change the callback shall be called unless it is removed via removeEventListener.

In my testing some implementations provide an empty consent string when the user does not dismiss the UI - in that case we ignore the consent object.

Other information

Fixes #7156
Same change for 7.x: #8524

@ChrisHuie ChrisHuie requested review from SKOCHERI and smenzer June 8, 2022 14:55
@ChrisHuie ChrisHuie requested a review from jsnellbaker June 8, 2022 14:55
@smenzer smenzer added the needs 2nd review Core module updates require two approvals from the core team label Jun 8, 2022
Copy link
Collaborator

@jsnellbaker jsnellbaker left a comment

Choose a reason for hiding this comment

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

I think this looks fine. Just to clarify, is there going to be a corresponding change on master as well? Or did the edits made in 7.0 already account for this capture of the tcfData if there was a timeout?

@dgirardi
Copy link
Collaborator Author

dgirardi commented Jun 9, 2022

there's another pr for master - #8524

@ChrisHuie ChrisHuie removed the needs 2nd review Core module updates require two approvals from the core team label Jun 9, 2022
@ChrisHuie ChrisHuie merged commit f0e1f2b into prebid:6.29.x-legacy Jun 10, 2022
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.

4 participants