From ddeeb743873ffdafac99aa4ef77a34066f1b7e4a Mon Sep 17 00:00:00 2001 From: Christian Herdtweck Date: Thu, 21 Mar 2019 17:49:39 +0100 Subject: [PATCH] tests: add encrypted excel samples --- tests/olevba/test_basic.py | 4 ++++ tests/test-data/encrypted/autostart-encrypt-standardpassword.xlsb | Bin 0 -> 18944 bytes tests/test-data/encrypted/autostart-encrypt-standardpassword.xlsm | Bin 0 -> 19456 bytes 3 files changed, 4 insertions(+), 0 deletions(-) create mode 100755 tests/test-data/encrypted/autostart-encrypt-standardpassword.xlsb create mode 100755 tests/test-data/encrypted/autostart-encrypt-standardpassword.xlsm diff --git a/tests/olevba/test_basic.py b/tests/olevba/test_basic.py index d319a12..5b90f5c 100644 --- a/tests/olevba/test_basic.py +++ b/tests/olevba/test_basic.py @@ -28,7 +28,11 @@ class TestOlevbaBasic(unittest.TestCase): CRYPT_DIR = join(DATA_BASE_DIR, 'encrypted') CRYPT_RETURN_CODE = 9 ADD_ARGS = [], ['-d', ], ['-a', ], ['-j', ], ['-t', ] + EXCEPTIONS = ['autostart-encrypt-standardpassword.xlsm', + 'autostart-encrypt-standardpassword.xlsb'] for filename in os.listdir(CRYPT_DIR): + if filename in EXCEPTIONS: + continue full_name = join(CRYPT_DIR, filename) for args in ADD_ARGS: try: diff --git a/tests/test-data/encrypted/autostart-encrypt-standardpassword.xlsb b/tests/test-data/encrypted/autostart-encrypt-standardpassword.xlsb new file mode 100755 index 0000000..b905d7c Binary files /dev/null and b/tests/test-data/encrypted/autostart-encrypt-standardpassword.xlsb differ diff --git a/tests/test-data/encrypted/autostart-encrypt-standardpassword.xlsm b/tests/test-data/encrypted/autostart-encrypt-standardpassword.xlsm new file mode 100755 index 0000000..2b2e113 Binary files /dev/null and b/tests/test-data/encrypted/autostart-encrypt-standardpassword.xlsm differ -- libgit2 0.21.4