Skip to content

Commit a798171

Browse files
committed
addImage docs: Warn about user-generated strings
1 parent bdca366 commit a798171

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/elements.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ To add an image, use the ``addImage`` method to sections, headers, footers, text
234234
235235
$section->addImage($src, [$style]);
236236
237-
- ``$src``. String path to a local image, URL of a remote image or the image data, as a string.
237+
- ``$src``. String path to a local image, URL of a remote image or the image data, as a string. Warning: Do not pass user-generated strings here, as that would allow an attacker to read arbitrary files or perform server-side request forgery by passing file paths or URLs instead of image data.
238238
- ``$style``. See :ref:`image-style`.
239239

240240
Examples:

0 commit comments

Comments
 (0)