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

Dependencies: Bump IAB GPP library #3127

Merged
merged 9 commits into from
May 8, 2024
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
<consent-string-sdk.version>2.0.2</consent-string-sdk.version>
<iabtcf.version>2.0.10</iabtcf.version>
<maxmind-client.version>2.12.0</maxmind-client.version>
<gpp-encoder.version>3.0.10</gpp-encoder.version>
<gpp-encoder.version>3.2.0</gpp-encoder.version>
<protobuf.version>3.21.7</protobuf.version>
<protoc.version>3.17.3</protoc.version>
<json-logic.version>1.0.7</json-logic.version>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
package org.prebid.server.activity.infrastructure.privacy;

import com.iab.gpp.encoder.section.UspCaV1;
import com.iab.gpp.encoder.section.UspCoV1;
import com.iab.gpp.encoder.section.UspCtV1;
import com.iab.gpp.encoder.section.UspNatV1;
import com.iab.gpp.encoder.section.UspUtV1;
import com.iab.gpp.encoder.section.UspVaV1;
import com.iab.gpp.encoder.section.UsCaV1;
import com.iab.gpp.encoder.section.UsCoV1;
import com.iab.gpp.encoder.section.UsCtV1;
import com.iab.gpp.encoder.section.UsNatV1;
import com.iab.gpp.encoder.section.UsUtV1;
import com.iab.gpp.encoder.section.UsVaV1;

import java.util.Set;

public enum PrivacySection {

NATIONAL(UspNatV1.ID),
CALIFORNIA(UspCaV1.ID),
VIRGINIA(UspVaV1.ID),
COLORADO(UspCoV1.ID),
UTAH(UspUtV1.ID),
CONNECTICUT(UspCtV1.ID);
NATIONAL(UsNatV1.ID),
CALIFORNIA(UsCaV1.ID),
VIRGINIA(UsVaV1.ID),
COLORADO(UsCoV1.ID),
UTAH(UsUtV1.ID),
CONNECTICUT(UsCtV1.ID);

public static final Set<PrivacySection> US_PRIVACY_SECTIONS = Set.of(
NATIONAL,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,28 +1,28 @@
package org.prebid.server.activity.infrastructure.privacy.uscustomlogic.reader;

import com.iab.gpp.encoder.GppModel;
import com.iab.gpp.encoder.section.UspCaV1;
import com.iab.gpp.encoder.section.UsCaV1;
import org.prebid.server.activity.infrastructure.privacy.uscustomlogic.USCustomLogicGppReader;
import org.prebid.server.util.ObjectUtil;

import java.util.List;

public class USCaliforniaGppReader implements USCustomLogicGppReader {

private final UspCaV1 consent;
private final UsCaV1 consent;

public USCaliforniaGppReader(GppModel gppModel) {
consent = gppModel != null ? gppModel.getUspCaV1Section() : null;
consent = gppModel != null ? gppModel.getUsCaV1Section() : null;
}

@Override
public Integer getVersion() {
return ObjectUtil.getIfNotNull(consent, UspCaV1::getVersion);
return ObjectUtil.getIfNotNull(consent, UsCaV1::getVersion);
}

@Override
public Boolean getGpc() {
return ObjectUtil.getIfNotNull(consent, UspCaV1::getGpc);
return ObjectUtil.getIfNotNull(consent, UsCaV1::getGpc);
}

@Override
Expand All @@ -32,17 +32,17 @@ public Boolean getGpcSegmentType() {

@Override
public Boolean getGpcSegmentIncluded() {
return ObjectUtil.getIfNotNull(consent, UspCaV1::getGpcSegmentIncluded);
return ObjectUtil.getIfNotNull(consent, UsCaV1::getGpcSegmentIncluded);
}

@Override
public Integer getSaleOptOut() {
return ObjectUtil.getIfNotNull(consent, UspCaV1::getSaleOptOut);
return ObjectUtil.getIfNotNull(consent, UsCaV1::getSaleOptOut);
}

@Override
public Integer getSaleOptOutNotice() {
return ObjectUtil.getIfNotNull(consent, UspCaV1::getSaleOptOutNotice);
return ObjectUtil.getIfNotNull(consent, UsCaV1::getSaleOptOutNotice);
}

@Override
Expand All @@ -52,12 +52,12 @@ public Integer getSharingNotice() {

@Override
public Integer getSharingOptOut() {
return ObjectUtil.getIfNotNull(consent, UspCaV1::getSharingOptOut);
return ObjectUtil.getIfNotNull(consent, UsCaV1::getSharingOptOut);
}

@Override
public Integer getSharingOptOutNotice() {
return ObjectUtil.getIfNotNull(consent, UspCaV1::getSharingOptOutNotice);
return ObjectUtil.getIfNotNull(consent, UsCaV1::getSharingOptOutNotice);
}

@Override
Expand All @@ -72,12 +72,12 @@ public Integer getTargetedAdvertisingOptOutNotice() {

@Override
public Integer getSensitiveDataLimitUseNotice() {
return ObjectUtil.getIfNotNull(consent, UspCaV1::getSensitiveDataLimitUseNotice);
return ObjectUtil.getIfNotNull(consent, UsCaV1::getSensitiveDataLimitUseNotice);
}

@Override
public List<Integer> getSensitiveDataProcessing() {
return ObjectUtil.getIfNotNull(consent, UspCaV1::getSensitiveDataProcessing);
return ObjectUtil.getIfNotNull(consent, UsCaV1::getSensitiveDataProcessing);
}

@Override
Expand All @@ -87,26 +87,26 @@ public Integer getSensitiveDataProcessingOptOutNotice() {

@Override
public List<Integer> getKnownChildSensitiveDataConsents() {
return ObjectUtil.getIfNotNull(consent, UspCaV1::getKnownChildSensitiveDataConsents);
return ObjectUtil.getIfNotNull(consent, UsCaV1::getKnownChildSensitiveDataConsents);
}

@Override
public Integer getPersonalDataConsents() {
return ObjectUtil.getIfNotNull(consent, UspCaV1::getPersonalDataConsents);
return ObjectUtil.getIfNotNull(consent, UsCaV1::getPersonalDataConsents);
}

@Override
public Integer getMspaCoveredTransaction() {
return ObjectUtil.getIfNotNull(consent, UspCaV1::getMspaCoveredTransaction);
return ObjectUtil.getIfNotNull(consent, UsCaV1::getMspaCoveredTransaction);
}

@Override
public Integer getMspaServiceProviderMode() {
return ObjectUtil.getIfNotNull(consent, UspCaV1::getMspaServiceProviderMode);
return ObjectUtil.getIfNotNull(consent, UsCaV1::getMspaServiceProviderMode);
}

@Override
public Integer getMspaOptOutOptionMode() {
return ObjectUtil.getIfNotNull(consent, UspCaV1::getMspaOptOutOptionMode);
return ObjectUtil.getIfNotNull(consent, UsCaV1::getMspaOptOutOptionMode);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,28 +2,28 @@
package org.prebid.server.activity.infrastructure.privacy.uscustomlogic.reader;

import com.iab.gpp.encoder.GppModel;
import com.iab.gpp.encoder.section.UspCoV1;
import com.iab.gpp.encoder.section.UsCoV1;
import org.prebid.server.activity.infrastructure.privacy.uscustomlogic.USCustomLogicGppReader;
import org.prebid.server.util.ObjectUtil;

import java.util.List;

public class USColoradoGppReader implements USCustomLogicGppReader {

private final UspCoV1 consent;
private final UsCoV1 consent;

public USColoradoGppReader(GppModel gppModel) {
consent = gppModel != null ? gppModel.getUspCoV1Section() : null;
consent = gppModel != null ? gppModel.getUsCoV1Section() : null;
}

@Override
public Integer getVersion() {
return ObjectUtil.getIfNotNull(consent, UspCoV1::getVersion);
return ObjectUtil.getIfNotNull(consent, UsCoV1::getVersion);
}

@Override
public Boolean getGpc() {
return ObjectUtil.getIfNotNull(consent, UspCoV1::getGpc);
return ObjectUtil.getIfNotNull(consent, UsCoV1::getGpc);
}

@Override
Expand All @@ -33,22 +33,22 @@ public Boolean getGpcSegmentType() {

@Override
public Boolean getGpcSegmentIncluded() {
return ObjectUtil.getIfNotNull(consent, UspCoV1::getGpcSegmentIncluded);
return ObjectUtil.getIfNotNull(consent, UsCoV1::getGpcSegmentIncluded);
}

@Override
public Integer getSaleOptOut() {
return ObjectUtil.getIfNotNull(consent, UspCoV1::getSaleOptOut);
return ObjectUtil.getIfNotNull(consent, UsCoV1::getSaleOptOut);
}

@Override
public Integer getSaleOptOutNotice() {
return ObjectUtil.getIfNotNull(consent, UspCoV1::getSaleOptOutNotice);
return ObjectUtil.getIfNotNull(consent, UsCoV1::getSaleOptOutNotice);
}

@Override
public Integer getSharingNotice() {
return ObjectUtil.getIfNotNull(consent, UspCoV1::getSharingNotice);
return ObjectUtil.getIfNotNull(consent, UsCoV1::getSharingNotice);
}

@Override
Expand All @@ -63,12 +63,12 @@ public Integer getSharingOptOutNotice() {

@Override
public Integer getTargetedAdvertisingOptOut() {
return ObjectUtil.getIfNotNull(consent, UspCoV1::getTargetedAdvertisingOptOut);
return ObjectUtil.getIfNotNull(consent, UsCoV1::getTargetedAdvertisingOptOut);
}

@Override
public Integer getTargetedAdvertisingOptOutNotice() {
return ObjectUtil.getIfNotNull(consent, UspCoV1::getTargetedAdvertisingOptOutNotice);
return ObjectUtil.getIfNotNull(consent, UsCoV1::getTargetedAdvertisingOptOutNotice);
}

@Override
Expand All @@ -78,7 +78,7 @@ public Integer getSensitiveDataLimitUseNotice() {

@Override
public List<Integer> getSensitiveDataProcessing() {
return ObjectUtil.getIfNotNull(consent, UspCoV1::getSensitiveDataProcessing);
return ObjectUtil.getIfNotNull(consent, UsCoV1::getSensitiveDataProcessing);
}

@Override
Expand All @@ -88,7 +88,7 @@ public Integer getSensitiveDataProcessingOptOutNotice() {

@Override
public Integer getKnownChildSensitiveDataConsents() {
return ObjectUtil.getIfNotNull(consent, UspCoV1::getKnownChildSensitiveDataConsents);
return ObjectUtil.getIfNotNull(consent, UsCoV1::getKnownChildSensitiveDataConsents);
}

@Override
Expand All @@ -98,16 +98,16 @@ public Integer getPersonalDataConsents() {

@Override
public Integer getMspaCoveredTransaction() {
return ObjectUtil.getIfNotNull(consent, UspCoV1::getMspaCoveredTransaction);
return ObjectUtil.getIfNotNull(consent, UsCoV1::getMspaCoveredTransaction);
}

@Override
public Integer getMspaServiceProviderMode() {
return ObjectUtil.getIfNotNull(consent, UspCoV1::getMspaServiceProviderMode);
return ObjectUtil.getIfNotNull(consent, UsCoV1::getMspaServiceProviderMode);
}

@Override
public Integer getMspaOptOutOptionMode() {
return ObjectUtil.getIfNotNull(consent, UspCoV1::getMspaOptOutOptionMode);
return ObjectUtil.getIfNotNull(consent, UsCoV1::getMspaOptOutOptionMode);
}
}
Original file line number Diff line number Diff line change
@@ -1,28 +1,28 @@
package org.prebid.server.activity.infrastructure.privacy.uscustomlogic.reader;

import com.iab.gpp.encoder.GppModel;
import com.iab.gpp.encoder.section.UspCtV1;
import com.iab.gpp.encoder.section.UsCtV1;
import org.prebid.server.activity.infrastructure.privacy.uscustomlogic.USCustomLogicGppReader;
import org.prebid.server.util.ObjectUtil;

import java.util.List;

public class USConnecticutGppReader implements USCustomLogicGppReader {

private final UspCtV1 consent;
private final UsCtV1 consent;

public USConnecticutGppReader(GppModel gppModel) {
consent = gppModel != null ? gppModel.getUspCtV1Section() : null;
consent = gppModel != null ? gppModel.getUsCtV1Section() : null;
}

@Override
public Integer getVersion() {
return ObjectUtil.getIfNotNull(consent, UspCtV1::getVersion);
return ObjectUtil.getIfNotNull(consent, UsCtV1::getVersion);
}

@Override
public Boolean getGpc() {
return ObjectUtil.getIfNotNull(consent, UspCtV1::getGpc);
return ObjectUtil.getIfNotNull(consent, UsCtV1::getGpc);
}

@Override
Expand All @@ -32,22 +32,22 @@ public Boolean getGpcSegmentType() {

@Override
public Boolean getGpcSegmentIncluded() {
return ObjectUtil.getIfNotNull(consent, UspCtV1::getGpcSegmentIncluded);
return ObjectUtil.getIfNotNull(consent, UsCtV1::getGpcSegmentIncluded);
}

@Override
public Integer getSaleOptOut() {
return ObjectUtil.getIfNotNull(consent, UspCtV1::getSaleOptOut);
return ObjectUtil.getIfNotNull(consent, UsCtV1::getSaleOptOut);
}

@Override
public Integer getSaleOptOutNotice() {
return ObjectUtil.getIfNotNull(consent, UspCtV1::getSaleOptOutNotice);
return ObjectUtil.getIfNotNull(consent, UsCtV1::getSaleOptOutNotice);
}

@Override
public Integer getSharingNotice() {
return ObjectUtil.getIfNotNull(consent, UspCtV1::getSharingNotice);
return ObjectUtil.getIfNotNull(consent, UsCtV1::getSharingNotice);
}

@Override
Expand All @@ -62,12 +62,12 @@ public Integer getSharingOptOutNotice() {

@Override
public Integer getTargetedAdvertisingOptOut() {
return ObjectUtil.getIfNotNull(consent, UspCtV1::getTargetedAdvertisingOptOut);
return ObjectUtil.getIfNotNull(consent, UsCtV1::getTargetedAdvertisingOptOut);
}

@Override
public Integer getTargetedAdvertisingOptOutNotice() {
return ObjectUtil.getIfNotNull(consent, UspCtV1::getTargetedAdvertisingOptOutNotice);
return ObjectUtil.getIfNotNull(consent, UsCtV1::getTargetedAdvertisingOptOutNotice);
}

@Override
Expand All @@ -77,7 +77,7 @@ public Integer getSensitiveDataLimitUseNotice() {

@Override
public List<Integer> getSensitiveDataProcessing() {
return ObjectUtil.getIfNotNull(consent, UspCtV1::getSensitiveDataProcessing);
return ObjectUtil.getIfNotNull(consent, UsCtV1::getSensitiveDataProcessing);
}

@Override
Expand All @@ -87,7 +87,7 @@ public Integer getSensitiveDataProcessingOptOutNotice() {

@Override
public List<Integer> getKnownChildSensitiveDataConsents() {
return ObjectUtil.getIfNotNull(consent, UspCtV1::getKnownChildSensitiveDataConsents);
return ObjectUtil.getIfNotNull(consent, UsCtV1::getKnownChildSensitiveDataConsents);
}

@Override
Expand All @@ -97,16 +97,16 @@ public Integer getPersonalDataConsents() {

@Override
public Integer getMspaCoveredTransaction() {
return ObjectUtil.getIfNotNull(consent, UspCtV1::getMspaCoveredTransaction);
return ObjectUtil.getIfNotNull(consent, UsCtV1::getMspaCoveredTransaction);
}

@Override
public Integer getMspaServiceProviderMode() {
return ObjectUtil.getIfNotNull(consent, UspCtV1::getMspaServiceProviderMode);
return ObjectUtil.getIfNotNull(consent, UsCtV1::getMspaServiceProviderMode);
}

@Override
public Integer getMspaOptOutOptionMode() {
return ObjectUtil.getIfNotNull(consent, UspCtV1::getMspaOptOutOptionMode);
return ObjectUtil.getIfNotNull(consent, UsCtV1::getMspaOptOutOptionMode);
}
}
Loading
Loading