TestMaskEval's cases reached 5 of the 36 checks on model spans: breaking any other one by hand left it green. This adds 21 cases (39 to 60), most of them texts from modelfits_test.go and vendorchecks_test.go, the places the model was seen misreading, and records the real model's spans on them (testdata/eval-model.json). Breaking each check by hand (breaks.py: one replacement in model.go, TestMaskEval run, file restored) now turns 13 red (5 before): secret-madeID, person-2runes, email-realEmail, person-zhTrim, person-assistant, account-numberLike, account-cue, address-letter, secret-wordstart, secret-uuid, secret-hexwords, secret-hexcue, edge-delimiter. Still green, because the real model gives no such span on any text tried (24 more probed) or another check catches the same span first: secret-namesThing, secret-len8, person-snakeWord, account-madeID, cut-from-word, person-chars, person-filedot, person-pathpart, person-colon, person-lowerword (person-chars keeps the same lower-case word), account-hex, account-version, the four phone checks, secret-pattern, secret-json, secret-link, secret-base64, email-wordstart, email-modcache, email-userinfo. Their unit tests in modelfits_test.go still cover them with recorded spans. A new real miss: "hex40 ok? 1 <sha1>" is one secret span "1 <sha1>" to the model, and the hex-words check only looks at the first field. Filed as #3597 and marked Known. Totals at this head (rules / model / both, masked and wrongly): 16/40 0/89, 38/40 28/89, 39/40 1/89. Run: MAGPIE_EVAL_CACHE=$HOME/.cache go test -run TestMaskEval -v ./internal/redact (recorded, then replayed green); go test -count=1 ./internal/redact ./internal/pii ok; go vet ./internal/redact for darwin, linux and windows; gofmt -l clean; breaks.py over all 36 checks. Not tried: the full suite (only test files changed in internal/redact).
668 lines
9.2 KiB
JSON
668 lines
9.2 KiB
JSON
{
|
|
"asset-files": {
|
|
"text": "8b019ca5e2af716b",
|
|
"found": []
|
|
},
|
|
"assistant-names": {
|
|
"text": "6f312259162fb240",
|
|
"found": []
|
|
},
|
|
"assistant-prose": {
|
|
"text": "2f09c57d2bcd4a33",
|
|
"found": [
|
|
{
|
|
"Start": 7,
|
|
"End": 13,
|
|
"Label": "private_person"
|
|
},
|
|
{
|
|
"Start": 57,
|
|
"End": 64,
|
|
"Label": "private_person"
|
|
},
|
|
{
|
|
"Start": 68,
|
|
"End": 73,
|
|
"Label": "private_person"
|
|
},
|
|
{
|
|
"Start": 115,
|
|
"End": 121,
|
|
"Label": "private_person"
|
|
}
|
|
]
|
|
},
|
|
"base64-image": {
|
|
"text": "88418a5daf6d9b9a",
|
|
"found": []
|
|
},
|
|
"bearer": {
|
|
"text": "708d72f298141a4c",
|
|
"found": [
|
|
{
|
|
"Start": 31,
|
|
"End": 148,
|
|
"Label": "secret"
|
|
},
|
|
{
|
|
"Start": 150,
|
|
"End": 180,
|
|
"Label": "private_url"
|
|
}
|
|
]
|
|
},
|
|
"card": {
|
|
"text": "7387f43ca5ce5824",
|
|
"found": []
|
|
},
|
|
"ci-table": {
|
|
"text": "059b37d552df2314",
|
|
"found": [
|
|
{
|
|
"Start": 26,
|
|
"End": 36,
|
|
"Label": "account_number"
|
|
}
|
|
]
|
|
},
|
|
"code-keys": {
|
|
"text": "d5f835bbf0a332b8",
|
|
"found": [
|
|
{
|
|
"Start": 12,
|
|
"End": 50,
|
|
"Label": "secret"
|
|
},
|
|
{
|
|
"Start": 67,
|
|
"End": 108,
|
|
"Label": "secret"
|
|
},
|
|
{
|
|
"Start": 135,
|
|
"End": 175,
|
|
"Label": "secret"
|
|
}
|
|
]
|
|
},
|
|
"code-locations": {
|
|
"text": "ebbde1d7b5199206",
|
|
"found": []
|
|
},
|
|
"codex-meta": {
|
|
"text": "4978726969792675",
|
|
"found": [
|
|
{
|
|
"Start": 83,
|
|
"End": 119,
|
|
"Label": "account_number"
|
|
},
|
|
{
|
|
"Start": 155,
|
|
"End": 169,
|
|
"Label": "private_person"
|
|
},
|
|
{
|
|
"Start": 240,
|
|
"End": 253,
|
|
"Label": "secret"
|
|
}
|
|
]
|
|
},
|
|
"colors-ports": {
|
|
"text": "252b9ce2e8df3e82",
|
|
"found": [
|
|
{
|
|
"Start": 14,
|
|
"End": 21,
|
|
"Label": "secret"
|
|
}
|
|
]
|
|
},
|
|
"commit-login": {
|
|
"text": "43e1522fcf559a62",
|
|
"found": [
|
|
{
|
|
"Start": 56,
|
|
"End": 62,
|
|
"Label": "private_person"
|
|
},
|
|
{
|
|
"Start": 64,
|
|
"End": 95,
|
|
"Label": "private_email"
|
|
}
|
|
]
|
|
},
|
|
"digests": {
|
|
"text": "3b3e688a54f12e96",
|
|
"found": [
|
|
{
|
|
"Start": 8,
|
|
"End": 72,
|
|
"Label": "secret"
|
|
}
|
|
]
|
|
},
|
|
"env-file": {
|
|
"text": "c1f1a7ab84f78373",
|
|
"found": [
|
|
{
|
|
"Start": 15,
|
|
"End": 63,
|
|
"Label": "secret"
|
|
},
|
|
{
|
|
"Start": 76,
|
|
"End": 90,
|
|
"Label": "secret"
|
|
}
|
|
]
|
|
},
|
|
"event-times": {
|
|
"text": "c1fe2fbd2701c75c",
|
|
"found": [
|
|
{
|
|
"Start": 36,
|
|
"End": 46,
|
|
"Label": "account_number"
|
|
},
|
|
{
|
|
"Start": 54,
|
|
"End": 67,
|
|
"Label": "account_number"
|
|
},
|
|
{
|
|
"Start": 76,
|
|
"End": 100,
|
|
"Label": "private_date"
|
|
},
|
|
{
|
|
"Start": 111,
|
|
"End": 127,
|
|
"Label": "private_phone"
|
|
},
|
|
{
|
|
"Start": 138,
|
|
"End": 142,
|
|
"Label": "private_address"
|
|
}
|
|
]
|
|
},
|
|
"example-mail": {
|
|
"text": "a1867625846dc315",
|
|
"found": [
|
|
{
|
|
"Start": 14,
|
|
"End": 30,
|
|
"Label": "private_email"
|
|
}
|
|
]
|
|
},
|
|
"git-author": {
|
|
"text": "94a966005e2adee1",
|
|
"found": [
|
|
{
|
|
"Start": 23,
|
|
"End": 33,
|
|
"Label": "private_person"
|
|
},
|
|
{
|
|
"Start": 35,
|
|
"End": 55,
|
|
"Label": "private_email"
|
|
}
|
|
]
|
|
},
|
|
"git-log": {
|
|
"text": "8fc8f17e8817539a",
|
|
"found": []
|
|
},
|
|
"git-user-url": {
|
|
"text": "b92e10fa6b923a00",
|
|
"found": [
|
|
{
|
|
"Start": 10,
|
|
"End": 55,
|
|
"Label": "private_url"
|
|
}
|
|
]
|
|
},
|
|
"go-caches": {
|
|
"text": "e855cf322da328a9",
|
|
"found": []
|
|
},
|
|
"grep-alts": {
|
|
"text": "dab9d9ae2f7b6d01",
|
|
"found": []
|
|
},
|
|
"grep-pattern": {
|
|
"text": "0d38dbff0a086bdf",
|
|
"found": []
|
|
},
|
|
"hex-lines": {
|
|
"text": "b378b2965f1a80de",
|
|
"found": [
|
|
{
|
|
"Start": 10,
|
|
"End": 52,
|
|
"Label": "secret"
|
|
},
|
|
{
|
|
"Start": 53,
|
|
"End": 96,
|
|
"Label": "secret"
|
|
}
|
|
]
|
|
},
|
|
"home-path": {
|
|
"text": "4f79a2f3631db506",
|
|
"found": [
|
|
{
|
|
"Start": 4,
|
|
"End": 40,
|
|
"Label": "private_url"
|
|
}
|
|
]
|
|
},
|
|
"iban": {
|
|
"text": "cf32ccaec3a1dfc1",
|
|
"found": [
|
|
{
|
|
"Start": 24,
|
|
"End": 51,
|
|
"Label": "account_number"
|
|
}
|
|
]
|
|
},
|
|
"json-contact": {
|
|
"text": "8b8300472a287a74",
|
|
"found": [
|
|
{
|
|
"Start": 21,
|
|
"End": 30,
|
|
"Label": "private_person"
|
|
},
|
|
{
|
|
"Start": 41,
|
|
"End": 62,
|
|
"Label": "private_email"
|
|
},
|
|
{
|
|
"Start": 70,
|
|
"End": 90,
|
|
"Label": "private_phone"
|
|
}
|
|
]
|
|
},
|
|
"json-settings": {
|
|
"text": "17b49a014daba2fc",
|
|
"found": []
|
|
},
|
|
"log-user": {
|
|
"text": "cda01fa1bd419b1d",
|
|
"found": [
|
|
{
|
|
"Start": 0,
|
|
"End": 19,
|
|
"Label": "private_date"
|
|
},
|
|
{
|
|
"Start": 35,
|
|
"End": 52,
|
|
"Label": "private_email"
|
|
},
|
|
{
|
|
"Start": 68,
|
|
"End": 76,
|
|
"Label": "private_url"
|
|
}
|
|
]
|
|
},
|
|
"noreply": {
|
|
"text": "271c7650b6474a19",
|
|
"found": []
|
|
},
|
|
"one-letter": {
|
|
"text": "0ff1555b12fd8004",
|
|
"found": [
|
|
{
|
|
"Start": 26,
|
|
"End": 27,
|
|
"Label": "private_person"
|
|
},
|
|
{
|
|
"Start": 32,
|
|
"End": 33,
|
|
"Label": "private_person"
|
|
}
|
|
]
|
|
},
|
|
"phone-intl": {
|
|
"text": "28bf596367da1b2b",
|
|
"found": [
|
|
{
|
|
"Start": 36,
|
|
"End": 39,
|
|
"Label": "private_person"
|
|
},
|
|
{
|
|
"Start": 43,
|
|
"End": 58,
|
|
"Label": "private_phone"
|
|
}
|
|
]
|
|
},
|
|
"pixels": {
|
|
"text": "96d207f1a0461a94",
|
|
"found": []
|
|
},
|
|
"prose-password": {
|
|
"text": "b45e2539ee55a672",
|
|
"found": [
|
|
{
|
|
"Start": 27,
|
|
"End": 38,
|
|
"Label": "secret"
|
|
}
|
|
]
|
|
},
|
|
"prose-person": {
|
|
"text": "7090b229a3288b42",
|
|
"found": [
|
|
{
|
|
"Start": 13,
|
|
"End": 27,
|
|
"Label": "private_person"
|
|
}
|
|
]
|
|
},
|
|
"retina-file": {
|
|
"text": "6210ece83f6b71ab",
|
|
"found": []
|
|
},
|
|
"session-tokens": {
|
|
"text": "6170ea7af28ec9e2",
|
|
"found": [
|
|
{
|
|
"Start": 0,
|
|
"End": 83,
|
|
"Label": "secret"
|
|
}
|
|
]
|
|
},
|
|
"session-uuid": {
|
|
"text": "45ff8afdbe77e369",
|
|
"found": [
|
|
{
|
|
"Start": 39,
|
|
"End": 81,
|
|
"Label": "secret"
|
|
}
|
|
]
|
|
},
|
|
"short-values": {
|
|
"text": "0133fede621b7801",
|
|
"found": [
|
|
{
|
|
"Start": 25,
|
|
"End": 30,
|
|
"Label": "private_address"
|
|
}
|
|
]
|
|
},
|
|
"sizes-versions": {
|
|
"text": "e08a850f552a995b",
|
|
"found": []
|
|
},
|
|
"skill-list": {
|
|
"text": "535fc5de908c39dd",
|
|
"found": [
|
|
{
|
|
"Start": 116,
|
|
"End": 125,
|
|
"Label": "private_address"
|
|
}
|
|
]
|
|
},
|
|
"snake-arg": {
|
|
"text": "7ade5b7b89a61dd4",
|
|
"found": []
|
|
},
|
|
"snake-words": {
|
|
"text": "89fcc6da0d4cc9fb",
|
|
"found": []
|
|
},
|
|
"task-ids": {
|
|
"text": "faff967171e2421d",
|
|
"found": [
|
|
{
|
|
"Start": 8,
|
|
"End": 26,
|
|
"Label": "account_number"
|
|
},
|
|
{
|
|
"Start": 43,
|
|
"End": 85,
|
|
"Label": "account_number"
|
|
}
|
|
]
|
|
},
|
|
"token-count": {
|
|
"text": "359c740b1ce9a3c5",
|
|
"found": [
|
|
{
|
|
"Start": 31,
|
|
"End": 39,
|
|
"Label": "account_number"
|
|
}
|
|
]
|
|
},
|
|
"tool-ids": {
|
|
"text": "50c8c97e610d704c",
|
|
"found": [
|
|
{
|
|
"Start": 37,
|
|
"End": 67,
|
|
"Label": "account_number"
|
|
},
|
|
{
|
|
"Start": 93,
|
|
"End": 121,
|
|
"Label": "account_number"
|
|
}
|
|
]
|
|
},
|
|
"tool-result-mixed": {
|
|
"text": "f5a49344e0e7f392",
|
|
"found": [
|
|
{
|
|
"Start": 36,
|
|
"End": 50,
|
|
"Label": "private_person"
|
|
},
|
|
{
|
|
"Start": 50,
|
|
"End": 70,
|
|
"Label": "private_email"
|
|
},
|
|
{
|
|
"Start": 70,
|
|
"End": 87,
|
|
"Label": "private_phone"
|
|
},
|
|
{
|
|
"Start": 88,
|
|
"End": 99,
|
|
"Label": "private_person"
|
|
},
|
|
{
|
|
"Start": 100,
|
|
"End": 121,
|
|
"Label": "private_email"
|
|
},
|
|
{
|
|
"Start": 121,
|
|
"End": 137,
|
|
"Label": "private_phone"
|
|
}
|
|
]
|
|
},
|
|
"tool-servers": {
|
|
"text": "6b9515c4bf396f51",
|
|
"found": []
|
|
},
|
|
"tool-use-ids": {
|
|
"text": "c83ab5e49cce4b75",
|
|
"found": [
|
|
{
|
|
"Start": 37,
|
|
"End": 60,
|
|
"Label": "account_number"
|
|
},
|
|
{
|
|
"Start": 68,
|
|
"End": 95,
|
|
"Label": "secret"
|
|
},
|
|
{
|
|
"Start": 105,
|
|
"End": 126,
|
|
"Label": "secret"
|
|
}
|
|
]
|
|
},
|
|
"unix-time": {
|
|
"text": "3e3d22cf38729962",
|
|
"found": []
|
|
},
|
|
"unix-time-ms": {
|
|
"text": "7e29836c6aa4f105",
|
|
"found": []
|
|
},
|
|
"url-login": {
|
|
"text": "d6f5b2b60e384bb9",
|
|
"found": [
|
|
{
|
|
"Start": 10,
|
|
"End": 58,
|
|
"Label": "private_url"
|
|
},
|
|
{
|
|
"Start": 63,
|
|
"End": 79,
|
|
"Label": "private_url"
|
|
}
|
|
]
|
|
},
|
|
"url-userinfo": {
|
|
"text": "a74a01c8225d54da",
|
|
"found": [
|
|
{
|
|
"Start": 27,
|
|
"End": 55,
|
|
"Label": "secret"
|
|
}
|
|
]
|
|
},
|
|
"us-address": {
|
|
"text": "d73e7386a905373e",
|
|
"found": [
|
|
{
|
|
"Start": 24,
|
|
"End": 68,
|
|
"Label": "private_address"
|
|
},
|
|
{
|
|
"Start": 78,
|
|
"End": 92,
|
|
"Label": "private_phone"
|
|
}
|
|
]
|
|
},
|
|
"user-path": {
|
|
"text": "007eeda2f5ba95d3",
|
|
"found": [
|
|
{
|
|
"Start": 11,
|
|
"End": 54,
|
|
"Label": "private_url"
|
|
},
|
|
{
|
|
"Start": 84,
|
|
"End": 116,
|
|
"Label": "private_url"
|
|
}
|
|
]
|
|
},
|
|
"zh-contact": {
|
|
"text": "5d654b2bbdd23aa1",
|
|
"found": [
|
|
{
|
|
"Start": 12,
|
|
"End": 18,
|
|
"Label": "private_person"
|
|
},
|
|
{
|
|
"Start": 28,
|
|
"End": 39,
|
|
"Label": "private_phone"
|
|
},
|
|
{
|
|
"Start": 51,
|
|
"End": 93,
|
|
"Label": "private_address"
|
|
}
|
|
]
|
|
},
|
|
"zh-id": {
|
|
"text": "f058f91bb1800cbe",
|
|
"found": [
|
|
{
|
|
"Start": 13,
|
|
"End": 31,
|
|
"Label": "account_number"
|
|
}
|
|
]
|
|
},
|
|
"zh-names-edge": {
|
|
"text": "709d9aa01117e001",
|
|
"found": [
|
|
{
|
|
"Start": 18,
|
|
"End": 39,
|
|
"Label": "private_person"
|
|
},
|
|
{
|
|
"Start": 51,
|
|
"End": 63,
|
|
"Label": "private_person"
|
|
}
|
|
]
|
|
},
|
|
"zh-password": {
|
|
"text": "ca3835176b202e40",
|
|
"found": [
|
|
{
|
|
"Start": 19,
|
|
"End": 29,
|
|
"Label": "secret"
|
|
}
|
|
]
|
|
},
|
|
"zh-prose": {
|
|
"text": "c75e8925f3dddfc7",
|
|
"found": [
|
|
{
|
|
"Start": 0,
|
|
"End": 15,
|
|
"Label": "private_person"
|
|
}
|
|
]
|
|
},
|
|
"zh-words": {
|
|
"text": "dfccf70c683fe55b",
|
|
"found": []
|
|
}
|
|
}
|