Scans data objects for possible real names when package masking is enabled. This is an exact-match technical check, not a legal or institutional compliance determination. It stops processing when configured names are found.
Usage
validate_privacy_compliance(
data = NULL,
privacy_level = getOption("engager.privacy_level", "mask"),
real_names = NULL,
stop_on_violation = TRUE
)Arguments
- data
Data frame or object to inspect for possible identifier exposure
- privacy_level
Privacy level to validate against. One of
c("privacy_strict", "privacy_standard", "mask", "none"). Defaults togetOption("engager.privacy_level", "mask"). Deprecated aliases "ferpa_strict" and "ferpa_standard" are accepted with a warning.- real_names
Vector of real names to check against. If NULL, uses common name patterns to detect potential violations.
- stop_on_violation
Whether to stop processing if violations are found. Defaults to TRUE for maximum privacy protection.
Value
The logical scalar TRUE when the technical check finds no configured
real names. The function raises an error instead when a blocking exposure is found.