iosswiftadmobccpa

Swift iOS -Admob how to determine if the user is a California state resident to prepare for the California Consumer Privacy Act (CCPA)


I just received an email from Google:

Important updates about the California Consumer Privacy Act (CCPA)

Basically it's a lite version of the GDPR rules in Europe but for California residents that will kick in on Jan 1, 2020. Google says:

The following products require action to enable restricted data processing: AdMob

When I click the AdMob link it says:

Some publishers may choose not to display a “Do Not Sell My Personal Information” link on their properties.

Alternatively, other publishers may choose to display a “Do Not Sell My Personal Information” link

When using the Google GDPR Consent Form SDK it makes my life very easy. The sdk can determine if the user is inside a GDPR region using the below code:

import PersonalizedAdConsent
PACConsentInformation.sharedInstance.debugGeography = .EEA
if PACConsentInformation.sharedInstance.isRequestLocationInEEAOrUnknown { ... }

If the user is inside the region I can present them the following form:

enter image description here

The CCPA code for the iOS page says to add this code:

let request = DFPRequest()
let adNetworkExtras = GADExtras()
adNetworkExtras.additionalParameters = [ "rdp" : "1" ]
request.register(adNetworkExtras)

I can show the user an alert that says “Do Not Sell My Personal Information” with a Yes/No option and if they want to opt out then the above code gets set. Unlike the GDPR consent form the big problem here is determining wether or not the user is or isn't a CA state resident.

The law establishes various rights for California state residents. I only want to present the form to users who are California state residents but there is a dilemma.

1- the user is located IN CA and IS a CA state resident (present them the alert)

2- the user is located OUTSIDE CA and IS a CA state resident (present them the alert)

3- the user is located IN CA and IS NOT a CA state resident (don't present anything)

4- the user is located OUTSIDE CA and IS NOT a CA state resident (don't present anything)

How can I determine if the user is located in CA vs them being a resident of CA so I know who to present the “Do Not Sell My Personal Information” alert to?

These are 4 very real situations that I cannot figure out how to parse.


Solution

  • This answer doesn't really answer my own question only because there doesn't seem a viable way for a small developer to work around this issue.

    In the comments underneath the question @matt suggested to just show the form to everyone in the US but that gives everyone in every state the option to opt-out. As a solo developer every dollar counts. I can understand the larger issue at hand but I need money to survive and to support my app business. If everyone everywhere has the option to opt-out I can loose income from the few people I currently have using my app (non-personalized ads brings in less revenue).

    If I serve personalized ads to CA state residents without giving them the option to opt-out I'm in violation of the law.

    It's like a "you're damned if you do and you're damned if you don't” type situation smh.

    Outside of simply presenting an alert that asks the user if they are or aren't a CA state resident to avoid problems with the law the safest bet is just to let Google decide.

    Go to AdMob, login, and follow the 3 steps in red in the pic below:

    enter image description here

    It should be noted that Google decides for both options and I choose restricted. Maybe you want to choose Don't Restrict but Google will make a determination on that also.