Learn it on Mainframe Path. Do it with Mainframe KIT.Learn on Mainframe Path ▸
Mainframe KIT ● Nothing leaves this tab

Test data masker

Replace names, accounts and other sensitive fields in a mainframe file with realistic fake values.Use this when you need a copy of a production-shaped file for testing, without real names, accounts or balances in it.

Checked against IBM rulesON THIS DEVICE · NOTHING UPLOADEDCounting requests…
How to use this tool

What it does

Uses your copybook to replace chosen fields in a mainframe file with fake values, keeping the record layout valid.

How to use it

  1. Paste the copybook and choose the data file (or paste it as hex).
  2. Choose what to do with each field, then press Mask the file.
  3. Read the report, then download the masked file.

What it cannot do

  • It is not anonymisation: fields you keep, free text and keys can still identify people.
  • Some field types are copied unchanged, and the report lists them.

copybook and data

1 · Copybook

2 · Data

3 · Key

Use one key for files that must still match each other after masking. A typed key should be long and kept private, never sent with the masked file: anyone with the key and a guess of a real value can check that guess. Masked values can repeat by chance, and masking replaces values; it does not by itself make a file anonymous.

4 · Fields to mask

Paste a copybook first, or load the example.

Selective masking, not anonymisation. Only the fields you choose are changed. Fields you leave on Keep, values the tool cannot change, and free text can still identify real people. Read the completion report before you share the file.

ACCURACY · CHECKED AGAINST IBM RULES

Masks byte by byte with the copybook layout, so record lengths and unmasked bytes are unchanged and masked numbers stay valid; covered by tests. Scrambling a number keeps it a valid number of the same size but changes its magnitude (a small balance can become a large one); text keeps its length and character types. It replaces values, it does not certify a file as anonymous: free text, keys and unmarked fields can still identify people, so follow your organisation's data rules.

What it checks

  • ConfirmedReplaces the fields you choose (text, zoned, packed and binary) byte by byte, using the copybook layout.
  • ConfirmedKeeps every record length and every unmasked byte unchanged, and keeps masked numbers valid for their type and sign.
  • ConfirmedThe same key and the same value always give the same masked value, so files still match after masking.
  • ConfirmedA completion report says what was and was not changed; the download stays locked until you accept a partial mask.

What it does not check

  • Depends on your systemIt is not anonymisation: fields you keep, free text, keys and values it cannot change can still identify people.
  • Depends on your systemWhich fields are sensitive: suggestions are a starting point, and your organisation's data rules decide.
  • UnsupportedFloating point, pointer and index, national (UTF-16), DBCS and scaled (P) fields are copied unchanged, and the report lists them.
  • Depends on your systemMasked values can repeat by chance, and a short or guessable key can be tested by someone who knows a real value.

Source

  • Mainframe KIT's own code page tables (A-Z, a-z and 0-9 share byte values across the offered code pages), checked by tests/unit/mask.test.ts
  • Same encodings and signs as the packed decimal calculator (docs/FACTS.md)
  • Keyed HMAC-SHA256 (Web Crypto): design note stated on the page

Checked against IBM rules. Status labels: Confirmed Depends on your system Unsupported (a rule with an official source; depends on your catalog, security, installation defaults or compiler options; not parsed and shown instead of guessing).

Input limits and example

  • File: up to 50 MB; up to 1,000,000 records are masked, the rest is copied unchanged and the report says so.
  • Copybook, hex and key boxes: 200,000 characters each.
  • On a phone or small screen a file over 5.0 MB shows a warning.

EXAMPLE INPUT

Copybook: 05 NAME PIC X(20).  05 BAL PIC S9(7)V99 COMP-3.
Choose NAME: scramble, BAL: scramble, key: any long private phrase

Check it yourself in one minute

  1. Open your browser's developer tools: in Chrome or Edge press F12 or right-click and choose Inspect; in Firefox press Ctrl+Shift+E for the Network Monitor; in Safari first turn on Show features for web developers under Settings, Advanced. Then open the Network tab.
  2. Keep the log across page loads (Chrome: Preserve log; Firefox: Persist Logs), then use the tool: paste your text or open a file and press the button.
  3. Look at the list. You will see only this page and its own files, loaded when the page opened. Nothing new appears when you use the tool.
  4. Still unsure? Switch Wi-Fi off and try again. The tool still works.

What the badge counts: requests the browser logged after this page finished loading, other than the site's own files. It reads the browser's own record and makes no request of its own. If your browser cannot give that record, the badge says so. The badge is a convenience; the developer tools are the proof.

The rule that enforces it

Every page carries this Content Security Policy. The browser itself refuses any request outside it; connect-src 'none' blocks fetch, XHR and WebSocket.

default-src 'none';
script-src 'self';
style-src 'self';
img-src 'self' data:;
font-src 'self';
connect-src 'none';
object-src 'none';
form-action 'none';
base-uri 'none';
manifest-src 'self';
worker-src 'self'