Skip to main content
All CollectionsObservePoint Custom Tag
OP Custom Tag - Forms with PII
OP Custom Tag - Forms with PII
Luiza Gircoveanu avatar
Written by Luiza Gircoveanu
Updated over 5 months ago

Overview

This custom tag will find all forms containing fields for Social Security Numbers, first names, last names, emails.

Note: This tag indicates pages with potential PII violations, but not necessarily that violations are occurring on the pages with these forms.

Under the Variable Inventory report, select ObservePoint Data and under PII Forms you can find the relevant information.

  • SSNInForm: true/false depending on social security number field presence; Regex has been added for SSN detection to negate if alphanumeric was before/after ssn

  • firstNameInForm: true/false depending on first name field presence

  • lastNameInForm: true/false depending on last name field presence

  • emailInForm: true/false depending on email field presence

function opReqGetAsync(paramObject, acct, callback) {
var baseURL = "https://opreq.observepoint.com/?acct=" + acct;
var opReq = new XMLHttpRequest();
opReq.onreadystatechange = function() {
if (opReq.readyState == 4 && opReq.status == 200) {
callback(opReq.responseText);
}
}
opReq.open("POST", baseURL, true);
opReq.send(JSON.stringify(paramObject));
}

var obj = {
SSNInForm: false,
firstNameInForm:false,
lastNameInForm:false,
emailInForm:false
};

var forms = document.querySelectorAll('form');
forms.forEach(function(form){
if (form != null){
var ser = new XMLSerializer();
var strForm = ser.serializeToString(form);
if (strForm.search(/[^a-zA-Z\d]ssn[^a-zA-Z\d]|social security/igm) > -1) obj.SSNInForm = true;
if (strForm.search(/fname|first name/igm) > -1) obj.firstNameInForm = true;
if (strForm.search(/lname|last name/igm) > -1) obj.lastNameInForm = true;
if (strForm.search(/email/igm) > -1) obj.emailInForm = true;
}
});

opReqGetAsync(obj,'PII Forms')
Did this answer your question?