diff options
| author | Michael Williamson <mike@zwobble.org> | 2025-09-19 11:26:30 +0100 |
|---|---|---|
| committer | Michael Williamson <mike@zwobble.org> | 2025-09-19 11:26:30 +0100 |
| commit | a929dc7164a5acc6a199ee5139d8511f61780350 (patch) | |
| tree | 4cd8f3232fc0f8acdfa5c19b44ded6c775ea9609 /README.md | |
| parent | 98c98549a237be0db4689bf38436a24fc30ac111 (diff) | |
Disable external file access by default
Diffstat (limited to 'README.md')
| -rw-r--r-- | README.md | 10 |
1 files changed, 7 insertions, 3 deletions
@@ -255,9 +255,9 @@ Methods: if the document contains an embedded style map, then it is combined with the default style map. Call this to ignore any embedded style maps. -* `DocumentConvert disableExternalFileAccess()`: Source documents may reference files outside of the source document. - Call this to disable access to any such external files during the conversion process. - This is highly recommended when converting untrusted user input. +* `DocumentConverter enableExternalFileAccess()`: Source documents may reference files outside of the source document. + Access to any such external files is disabled by default. + Call this to enable access when converting trusted source documents. * `DocumentConverter preserveEmptyParagraphs()`: by default, empty paragraphs are ignored. Call this to preserve empty paragraphs in the output. @@ -330,6 +330,10 @@ For instance: automatically convert the document into HTML on the server, and embed the HTML into your website, this may allow arbitrary files on the server to be read and exfiltrated. +* + To avoid this issue, access to any such external files is disabled by default. + To enable access when converting trusted source documents, + call `enableExternalFileAccess()`. ## Writing style maps |
