{
  "method": {
    "corpora": [
      "GovDocs1 (2009-era US government documents; threads 000, 050, ... 950; the same 4,840 PDFs as the metadata, redaction and page-size studies)",
      "CC-MAIN-2021-31-PDF-UNTRUNCATED (PDFs from a July/August 2021 web crawl; zips 0000, 1600, 3200, 4800, 6400)"
    ],
    "sampleRule": "every extracted PDF of both corpora (a census, no sample)",
    "encrypted": "a file whose newest trailer has an /Encrypt entry, read with pdf-lib's ignoreEncryption. The cipher is read from the /Encrypt dictionary: /V 1 is RC4 with a 40-bit key, /V 2 and 3 RC4 with the dictionary's /Length, /V 4 the crypt filter named by /StmF (/CFM V2 is RC4 128, AESV2 is AES 128), /V 5 AESV3 (AES 256)",
    "ownerOnly": "an encrypted file that PDF.js opens with no password (it tries the empty user password, as every reader does). 'open-password' is an encrypted file it cannot open without one",
    "permissions": "the /P word's eight flags (print, edit, copy, annotate, fill forms, accessibility, assemble pages, high-quality print), read from the low 12 bits whether the producer wrote P signed or unsigned. Counted over owner-only files, where the flags bite without a password",
    "herepdf": "the unlock gate's sniff (lib/pdfUnlock.js looksEncrypted + encryptionKind), the loader (lib/pdfLoad.js loadPdf then lib/pdfErrors.js classifyLoadError), and, on a file PDF.js opens, the four flags HerePDF honours (printing, editing, copying, annotating) and whether assertCopyAllowed refuses it",
    "protect": "lib/pdfProtect.js protectPdf with the password 'Study-Password-2026-x' over the first 300 unencrypted GovDocs1 files with 3 to 40 pages and at most 3 MB (lowest SHA-256 of the file name). A string counts as readable in the output only if the same scan could read it in the original: page 1's first 8-character run (PDF.js), each Info field of 8 or more letters and digits, /MediaBox and /Type /Pages. The scan is tests/wholeFileText.js (raw bytes plus every inflated stream plus hex strings)",
    "protectFix": "the first run of the Password Protect arm found 2 files whose output still held readable content: an object pdf-lib cannot parse is written back as it was, so it was never encrypted. The tool now refuses such a file; the arm was run again, and the first run is kept as protectBeforeFix",
    "limits": "two public collections of PDFs found on the web, one from 2009 and one from 2021: they say nothing about the documents people keep private, such as bank statements and contracts. No password is known for an open-password file, so none was opened. A restriction counted here is what the file declares, not what any one program enforces",
    "sampleIdsSha256": {
      "govdocs1": "67d4e54dc5793ae9ad4887adca9974bf58b5703012e5c870bf038631897a2457",
      "cc2021": "e280f39a85a608d1ae955439808ffe07ab4a6ff0426f2f0bbe455d269e2f1996",
      "protect": "4741e9c6394a1bfbf109f33d1b040a3fe22727c0085f6d101a6a3bbb70be310c",
      "protectBeforeFix": "4741e9c6394a1bfbf109f33d1b040a3fe22727c0085f6d101a6a3bbb70be310c"
    },
    "tool": {
      "pdfLib": "2.11.1",
      "pdfjs": "6.4.299"
    },
    "generatedOn": "2026-10-27",
    "commit": "53f6943 (plus uncommitted changes)"
  },
  "govdocs1": {
    "label": "GovDocs1",
    "year": 2009,
    "tried": 4840,
    "completed": 4840,
    "notCompleted": {},
    "encrypted": 197,
    "ownerOnly": 197,
    "openPassword": 0,
    "cipher": {
      "RC4-128": 90,
      "RC4-40": 106,
      "RC4-64": 1
    },
    "cipherOwnerOnly": {
      "RC4-128": 90,
      "RC4-40": 106,
      "RC4-64": 1
    },
    "cipherOpenPassword": {},
    "metadataInTheClear": 1,
    "permissions": {
      "files": 197,
      "turnedOff": {
        "print": 7,
        "modify": 167,
        "copy": 49,
        "annotate": 139,
        "fillForms": 72,
        "accessibility": 10,
        "assemble": 76,
        "printHighRes": 9
      },
      "nothingRestricted": 28,
      "patterns": [
        {
          "set": "edit + annotate + fill forms + assemble pages",
          "files": 42
        },
        {
          "set": "edit + annotate",
          "files": 41
        },
        {
          "set": "nothing",
          "files": 28
        },
        {
          "set": "edit",
          "files": 26
        },
        {
          "set": "edit + copy + annotate + fill forms + assemble pages",
          "files": 19
        },
        {
          "set": "edit + copy + annotate",
          "files": 16
        }
      ],
      "distinctPatterns": 16
    },
    "herepdf": {
      "loaderSays": {
        "restricted": 197
      },
      "gateSees": {
        "restricted": 197
      },
      "gateSeesInAnUnencryptedFile": 0,
      "ownerOnlyHonouredRestrictions": {
        "files": 197,
        "none": 29,
        "printing": 7,
        "editing": 167,
        "copying": 49,
        "annotating": 139
      },
      "copyRefused": 49
    }
  },
  "cc2021": {
    "label": "Web crawl",
    "year": 2021,
    "tried": 4986,
    "completed": 4985,
    "notCompleted": {
      "failed": 1
    },
    "encrypted": 110,
    "ownerOnly": 106,
    "openPassword": 4,
    "cipher": {
      "RC4-128": 49,
      "AES-256": 10,
      "AES-128": 36,
      "RC4-40": 15
    },
    "cipherOwnerOnly": {
      "RC4-128": 49,
      "AES-256": 10,
      "AES-128": 35,
      "RC4-40": 12
    },
    "cipherOpenPassword": {
      "AES-128": 1,
      "RC4-40": 3
    },
    "metadataInTheClear": 7,
    "permissions": {
      "files": 106,
      "turnedOff": {
        "print": 11,
        "modify": 102,
        "copy": 69,
        "annotate": 77,
        "fillForms": 69,
        "accessibility": 26,
        "assemble": 95,
        "printHighRes": 20
      },
      "nothingRestricted": 1,
      "patterns": [
        {
          "set": "edit + copy + annotate + fill forms + assemble pages",
          "files": 24
        },
        {
          "set": "edit + annotate + fill forms + assemble pages",
          "files": 15
        },
        {
          "set": "edit + copy + annotate + fill forms + accessibility + assemble pages",
          "files": 7
        },
        {
          "set": "edit + assemble pages",
          "files": 6
        },
        {
          "set": "edit + copy + assemble pages",
          "files": 6
        },
        {
          "set": "print + edit + copy + annotate + fill forms + assemble pages + print in high quality",
          "files": 6
        }
      ],
      "distinctPatterns": 27
    },
    "herepdf": {
      "loaderSays": {
        "restricted": 106,
        "needs-password": 4
      },
      "gateSees": {
        "restricted": 105,
        "needs-password": 4,
        "none": 1
      },
      "gateSeesInAnUnencryptedFile": 0,
      "ownerOnlyHonouredRestrictions": {
        "files": 106,
        "none": 2,
        "printing": 11,
        "editing": 102,
        "copying": 69,
        "annotating": 77
      },
      "copyRefused": 69
    }
  },
  "protect": {
    "tried": 300,
    "completed": 298,
    "refused": 2,
    "notCompleted": {
      "refused": 2
    },
    "cipher": {
      "AES-256 (V 5, R 6)": 298
    },
    "everyPermissionGranted": 298,
    "opensWithoutPassword": 0,
    "opensWithWrongPassword": 0,
    "pdfjsOpensWithPassword": 298,
    "unlockGivesBackEveryPage": 298,
    "unlockedTextSame": {
      "checked": 298,
      "same": 298
    },
    "anyReadableInOutput": 1,
    "unlockedCopyStillEncrypted": 0,
    "outputSmaller": 298,
    "pageText": {
      "files": 284,
      "readableInOriginal": 150,
      "readableInOutput": 0
    },
    "infoStrings": {
      "inOriginal": 914,
      "readableInOutput": 0
    },
    "mediaBox": {
      "inOriginal": 298,
      "readableInOutput": 1
    },
    "pageTree": {
      "inOriginal": 298,
      "readableInOutput": 0
    }
  },
  "protectBeforeFix": {
    "tried": 300,
    "completed": 300,
    "refused": 0,
    "notCompleted": {},
    "cipher": {
      "AES-256 (V 5, R 6)": 300
    },
    "everyPermissionGranted": 300,
    "opensWithoutPassword": 0,
    "opensWithWrongPassword": 0,
    "pdfjsOpensWithPassword": 300,
    "unlockGivesBackEveryPage": 300,
    "unlockedTextSame": {
      "checked": 0,
      "same": 0
    },
    "anyReadableInOutput": 2,
    "unlockedCopyStillEncrypted": 0,
    "outputSmaller": 300,
    "pageText": {
      "files": 286,
      "readableInOriginal": 152,
      "readableInOutput": 1
    },
    "infoStrings": {
      "inOriginal": 918,
      "readableInOutput": 0
    },
    "mediaBox": {
      "inOriginal": 300,
      "readableInOutput": 1
    },
    "pageTree": {
      "inOriginal": 300,
      "readableInOutput": 0
    }
  }
}
