ມາດສກ PII ສໍາລັບ log ແລະ pipeline ໃນ Rust.

Rust implementation of mask-pii. Configure explicit masking rules for emails and phone numbers to prepare text safely before logging, auditing, or sharing data.

Email masking rule

Keeps domain visibility and masks the local part so email addresses remain traceable without exposing full PII.

Phone masking rule

Masks middle digits while preserving format and suffix visibility to keep operational troubleshooting possible.

Safe-by-default configuration

Masking is opt-in. Enable only the required rules and choose a mask character that matches your log policy.

Installation, usage, and rollout checklist

Rust [published: crates.io 0.2.0]: ໃຊ້ວິທີຕິດຕັ້ງປັດຈຸບັນດ້ານລຸ່ມ, ໂຫຼດ API ຂອງ Rust ແລະເປີດໃຊ້ຕົວຢ່າງຂັ້ນຕ່ຳ. ຕົວຢ່າງນີ້ເປີດການປິດບັງອີເມວແລະເບີໂທຢ່າງຊັດເຈນ ແລະສະແດງຜົນລັບທີ່ຄາດໄວ້.

ຕິດຕັ້ງ

cargo add mask-pii@0.2.0

ວິທີໃຊ້

src/main.rs
use mask_pii::Masker;

fn main() {
    // Configure the masker
    let masker = Masker::new()
        .mask_emails()
        .mask_phones()
        .with_mask_char('#'); // Optional: Use '#' instead of '*'

    let input = "Contact: alice@example.com or 090-1234-5678.";
    
    // Process the text
    let output = masker.process(input);

    println!("{}", output);
    // Output: "Contact: a####@example.com or ###-####-5678."
}
README and implementation notes

For rollout details such as edge cases, test strategy, and language-specific caveats, review the README before production use.

ກ່ອນໜ້າ

ພາບລວມ

ຕໍ່ໄປ

GitHub (Rust)