diff options
| author | Michael Williamson <mike@zwobble.org> | 2025-09-19 11:20:28 +0100 |
|---|---|---|
| committer | Michael Williamson <mike@zwobble.org> | 2025-09-19 11:20:28 +0100 |
| commit | 750a5bd6f103c816281fddb6dca91a55a0617829 (patch) | |
| tree | 4bb2de15dbfc9e976f9405a9a2de1f967dff22c8 /README.md | |
| parent | a828b007d3fffc17235c120f79d4082047cd5f94 (diff) | |
Disable external file access by default
Diffstat (limited to 'README.md')
| -rw-r--r-- | README.md | 11 |
1 files changed, 6 insertions, 5 deletions
@@ -291,9 +291,9 @@ Converts the source document to HTML. pass `include_default_style_map=False`. * Source documents may reference files outside of the source document. - To disable access to any such external files during the conversion process, - pass `external_file_access=False`. - This is highly recommended when converting untrusted user input. + Access to any such external files is disabled by default. + To enable access when converting trusted source documents, + pass `external_file_access=True`. * `convert_image`: by default, images are converted to `<img>` elements with the source included inline in the `src` attribute. Set this argument to an [image converter](#image-converters) to override the default behaviour. @@ -420,8 +420,9 @@ For instance: and embed the HTML into your website, this may allow arbitrary files on the server to be read and exfiltrated. - To disable access to any such external files during the conversion process, - pass `external_file_access=False`. + To avoid this issue, access to any such external files is disabled by default. + To enable access when converting trusted source documents, + pass `external_file_access=True`. ### Document transforms |
