ID number desensitization
🛡️ Desensitization settings
💡 Instructions for use
- The mobile phone number is identified by eleven digits, with separators before and after; the first three and last four digits of the code are retained, and the middle is replaced by a covering symbol.
- By default, only the username part of the email is coded, and the domain name remains intact, making it easy to confirm which email service it is; you can also choose to cover the entire section.
- By default, the first six digits and the last four digits of ID cards and bank cards are retained, so that the place of origin or card issuing bank can be seen without exposing the complete number.
- Name recognition can easily damage common words by mistake and is turned off by default; if necessary, you can only retain the last name or only the last word.
- Custom rules are one per line. The format is matching content plus replacement content, separated by spaces. Regular expressions are supported.
- The processing is completed in the browser, and the original text is not uploaded or saved; if you need to keep the results, please copy or download the results.
The first six and last four digits of the ID number are desensitized and retained: the former can reveal the place of origin, the latter is easy to verify, and the middle date of birth is covered.
Why the middle part needs the most coverage
The middle eight digits of the ID number are the date of birth, which when combined with the name is enough to locate a specific individual in most scenarios, and is the most sensitive part. The first six digits are the administrative division code, and the last four digits include the sequence code and check digit. Once the complete number is leaked, the risk is very high. Therefore, the common coding method is to keep the front and back and cover the middle.
Two points to note when handling
- Numbers ending with a letter will also be recognized, and the check letter at the end will be retained.
- If the number is immediately preceded and followed by other numbers, it may not be recognized, and custom rules need to be used to match based on context.
- For occasions with stricter compliance requirements, it is recommended to directly choose the entire section covering.
The common practice for desensitizing ID numbers is to retain the first six digits of the area code and the last four digits, and replace them with asterisks in between. The first six digits can reflect the place of residence, the last four digits are convenient for personal verification, and the date of birth and sequence code in the middle are hidden, taking into account usability and compliance.
The minimum necessary principle should be followed during the collection process: not every business requires a complete ID number. In many scenarios, only the last number or year of birth needs to be verified. If you really need to save it, it is recommended to encrypt the storage and limit the access scope, rather than relying on display layer coding.
It is recommended not to retain the check digit of the document number. It can be used to verify whether the number segment is legal.
For occasions with strict compliance requirements, it is safer to directly cover the entire section.
📖 Glossary
- Desensitization
- On the premise of retaining the usability of the data, cover or replace sensitive parts so that others cannot directly identify specific individuals.
- coding
- The practice of covering some characters with fixed symbols, such as retaining the first three and last four characters, and replacing them with asterisks in between.
- Irreversible
- The obscured characters are no longer retained, and no one can restore the original content from the result, which is essentially different from encryption.
- pseudo-anonymization
- Replace the real identifier with a number or placeholder, and maintain a corresponding relationship table, which can be related back to the original record when necessary.
- personal information
- Information that can identify a specific individual individually or in combination, such as name, phone number, ID number, address and account number.
- minimum necessary
- Only deal with the part of the information that is really needed for the business, keep as little as possible, and cover up as much as possible.
- Accidental injury
- Ordinary content is misjudged as sensitive information and obscured, for example, ordinary words are recognized as names, requiring manual review.
- missed judgment
- Really sensitive information is not recognized, usually because the format is non-standard or mixed with other characters.
- Log desensitization
- Mask sensitive fields before logging to avoid writing personal information into the log file when troubleshooting.
- Data export
- Sending data to offshore servers involves compliance requirements, so local processing tools are more suitable for sensitive data.
🔗 All keywords and tutorials
❓ FAQ
- Can the old fifteen-digit number be recognized??
- By default, identification is based on eighteen digits; old numbers can be processed in fifteen-digit format using custom rules.
- Can it still pass the inspection after covering it??
- No. The covered bits are no longer retained, and the check bit cannot correspond to the remaining bits. This is the purpose of desensitization.