Skip to content

Commit 976e3f2

Browse files
committed
add new test case for PDF files
1 parent 404b0ea commit 976e3f2

File tree

3 files changed

+2
-2
lines changed

3 files changed

+2
-2
lines changed

.idea/runConfigurations/RunAllUnitTests.xml renamed to .idea/runConfigurations/Run_Unt_Tests.xml

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/test/java/eu/righettod/TestSecurityUtils.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ public void isRelativeURL() {
168168

169169
@Test
170170
public void isPDFSafe() {
171-
List<String> unsafeFileList = Arrays.asList("test-putty.exe.pdf", "test-pdf-with-link-to-malicious-file.pdf", "test-dynamic-doc.pdf");
171+
List<String> unsafeFileList = Arrays.asList("test-putty.exe.pdf", "test-pdf-with-link-to-malicious-file.pdf", "test-dynamic-doc.pdf", "test-pdf-with-js-code.pdf");
172172
unsafeFileList.forEach(f -> {
173173
String testFile = getTestFilePath(f);
174174
assertFalse(SecurityUtils.isPDFSafe(testFile), String.format(TEMPLATE_MESSAGE_FALSE_NEGATIVE_FOR_FILE, testFile));
681 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)