-
Notifications
You must be signed in to change notification settings - Fork 764
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
Fix: setuid endpoint sets cookie when both GDPR and GPP are set #3165
Conversation
…P is set in the request
endpoints/setuid.go
Outdated
w.Write([]byte("Warning: " + err.Error())) | ||
w.Header().Add("Warning", err.Error()) |
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.
We'd rather not add a warning as a header. Instead, I think we should skip sending a warning in the response altogether. We can simply delete this line which should cause the endpoint to set the cookie when both GDPR and GPP are set.
I don't think this is necessarily required but you could explore adding a metric to surface the warning.
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.
as per the suggestion, removed the line
endpoints/setuid_test.go
Outdated
}, | ||
{ | ||
uri: "/setuid?f=i&bidder=pubmatic&uid=123&gpp_sid=2,4&gpp=DBABMA~CPXxRfAPXxRfAAfKABENB-CgAAAAAAAAAAYgAAAAAAAA" + | ||
"gdpr=1&gdpr_consent=BONciguONcjGKADACHENAOLS1rAHDAFAAEAASABQAMwAeACEAFw", |
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.
Did you mean "&gdpr=1
at the beginning of the line?
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.
yes, added missing & separator
Possible fix for - #3166