InteractiveAdvertisingBureau / Global-Privacy-Platform

IAB Tech Lab Global Privacy Platform specification
74 stars 38 forks source link

TCF EU extension update #36

Open janwinkler opened 1 year ago

janwinkler commented 1 year ago

The Publisher restrictions field is not really compatible with GPP since it does not reflect one (1) datatype but mutlitple in an unknown amount. The correct datatype would be:

Name: "RestrictionDataType" (or whatever) Encoding: variable JS API output: Object of Name-Number pairs (e.g. {1: {13:2, 15:1, 17:0, 18:0}, 2:{11:2, 12:1, 13:0, 15:0}}

"RestrictionDataType" : consists of

Where "num" defines the amount of restrictions to come. for each restriction there is a prupose ID and a restriction type followed by a range of IDs for which these restrictsion are valid.

HeinzBaumann commented 1 month ago

@janwinkler this is quite old. Is this still wrong in the latest EEA/UK Section spec? This is what I currently have:

Publisher Restrictions Section The content of this section is optional EXCEPT for NumPubRestrictions. Encodes any number of single or range restriction entries. NumPubRestrictions Int(12) Number of restriction records to follow.
Value is required even if it is 0 PurposeID Int(6) The Vendor’s declared Purpose ID that the publisher has indicated that they are overriding. RestrictionType Int 0 Purpose Flatly Not Allowed by Publisher (regardless of Vendor declarations)
1 Require Consent (if Vendor has declared the Purpose IDs legal basis as Legitimate Interest and flexible)
2 Require Legitimate Interest (if Vendor has declared the Purpose IDs legal basis as Consent and flexible)
3 UNDEFINED (not used) PubRestrictionEntry* OptimizedIntRange A single or range of Vendor ID(s) who the publisher has designated as restricted under the Purpose ID in this PubRestrictionsEntry

Equivalent of the fields listed under the Publisher Restrictions Section as defined in the TCF v2 specification:
MaxVendorId,
IsRangeEncoding,
BitField, NumEntries, IsARange, StartOrOnlyVendorId, EndVendorId
janwinkler commented 4 weeks ago

The encoding would work but the JS API wouldnt know what to output. Thats why with the last iteration of the core spec we added ArrayOfRanges and N-ArrayOfRanges. ArrayOfRanges would be the correct datatype for the Restriction replacing all fields from NumPubRestrictions up to the end with one field (call it PubRestrictions or something)

janwinkler commented 4 weeks ago

ps: see tcf canada, there we already went one step further and used N-ArrayOfRanges instead of ArrayOfRanges