sensitiveFields top-level constant
List of field names that should be considered sensitive and masked/encrypted in logs, error reports, and debug output
Implementation
const sensitiveFields = [
// Authentication & Authorization
'authorization',
'auth',
'authenticate',
'bearer',
'basic_auth',
'api_key',
'apikey',
'api-key',
'client_secret',
'client-secret',
'secret',
'private_key',
'privatekey',
'private-key',
'public_key',
'publickey',
'public-key',
// Tokens
'token',
'access_token',
'accesstoken',
'access-token',
'refresh_token',
'refreshtoken',
'refresh-token',
'id_token',
'idtoken',
'id-token',
'jwt',
'session_token',
'sessiontoken',
'session-token',
// Passwords
'password',
'passwd',
'pass',
'pwd',
'secret_key',
'secretkey',
'secret-key',
'passphrase',
// Financial Information
'credit_card',
'creditcard',
'credit-card',
'card_number',
'cardnumber',
'card-number',
'cvv',
'cvc',
'ccv',
'security_code',
'securitycode',
'security-code',
'expiry',
'expiration',
'bank_account',
'bankaccount',
'bank-account',
'routing_number',
'routingnumber',
'routing-number',
'account_number',
'accountnumber',
'account-number',
'iban',
'swift',
'bic',
// Personal Identifiable Information (PII)
'ssn',
'social_security',
'socialsecurity',
'social-security',
'tax_id',
'taxid',
'tax-id',
'passport',
'passport_number',
'passportnumber',
'passport-number',
'drivers_license',
'driverslicense',
'drivers-license',
'license_number',
'licensenumber',
'license-number',
// Healthcare Information
'medical_record',
'medicalrecord',
'medical-record',
'health_id',
'healthid',
'health-id',
'insurance_id',
'insuranceid',
'insurance-id',
// Biometric Data
'fingerprint',
'facial_data',
'facialdata',
'facial-data',
'biometric',
'retina_scan',
'retinascan',
'retina-scan',
// Contact Information
'phone',
'phone_number',
'phonenumber',
'phone-number',
'mobile',
'mobile_number',
'mobilenumber',
'mobile-number',
// Recovery Information
'security_question',
'securityquestion',
'security-question',
'security_answer',
'securityanswer',
'security-answer',
'recovery_code',
'recoverycode',
'recovery-code',
// Device & Location
'device_id',
'deviceid',
'device-id',
'imei',
'mac_address',
'macaddress',
'mac-address',
'geolocation',
'coordinates',
'location',
// Generic Sensitive Terms
'private',
'sensitive',
'confidential',
'restricted',
'hidden',
'protected',
'secure',
'encrypted',
];