Skip to content

Commit

Permalink
Changes for acstore
Browse files Browse the repository at this point in the history
  • Loading branch information
joachimmetz committed Apr 6, 2024
1 parent f889a38 commit e7b4bd3
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 24 deletions.
2 changes: 1 addition & 1 deletion config/dpkg/control
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Description: Data files for plaso (log2timeline)

Package: python3-plaso
Architecture: all
Depends: plaso-data (>= ${binary:Version}), libbde-python3 (>= 20220121), libcaes-python3 (>= 20240114), libcreg-python3 (>= 20200725), libesedb-python3 (>= 20220806), libevt-python3 (>= 20191104), libevtx-python3 (>= 20220724), libewf-python3 (>= 20131210), libfcrypto-python3 (>= 20240114), libfsapfs-python3 (>= 20220709), libfsext-python3 (>= 20220829), libfsfat-python3 (>= 20220925), libfshfs-python3 (>= 20220831), libfsntfs-python3 (>= 20211229), libfsxfs-python3 (>= 20220829), libfvde-python3 (>= 20220121), libfwnt-python3 (>= 20210717), libfwsi-python3 (>= 20240225), liblnk-python3 (>= 20230716), libluksde-python3 (>= 20220121), libmodi-python3 (>= 20210405), libmsiecf-python3 (>= 20150314), libolecf-python3 (>= 20151223), libphdi-python3 (>= 20220228), libqcow-python3 (>= 20201213), libregf-python3 (>= 20201002), libscca-python3 (>= 20190605), libsigscan-python3 (>= 20230109), libsmdev-python3 (>= 20140529), libsmraw-python3 (>= 20140612), libvhdi-python3 (>= 20201014), libvmdk-python3 (>= 20140421), libvsapm-python3 (>= 20230506), libvsgpt-python3 (>= 20211115), libvshadow-python3 (>= 20160109), libvslvm-python3 (>= 20160109), python3-acstore (>= 20240121), python3-artifacts (>= 20220219), python3-bencode, python3-certifi (>= 2016.9.26), python3-cffi-backend (>= 1.9.1), python3-chardet (>= 2.0.1), python3-dateutil (>= 1.5), python3-defusedxml (>= 0.5.0), python3-dfdatetime (>= 20240330), python3-dfvfs (>= 20240115), python3-dfwinreg (>= 20240229), python3-dtfabric (>= 20230518), python3-flor (>= 1.1.3), python3-future (>= 0.16.0), python3-idna (>= 2.5), python3-lz4 (>= 0.10.0), python3-opensearch, python3-pefile (>= 2021.5.24), python3-psutil (>= 5.4.3), python3-pyparsing (>= 3.0.0), python3-pytsk3 (>= 20210419), python3-redis (>= 3.4), python3-requests (>= 2.18.0), python3-six (>= 1.1.0), python3-tz, python3-urllib3 (>= 1.21.1), python3-xattr (>= 0.7.2), python3-xlsxwriter (>= 0.9.3), python3-yaml (>= 3.10), python3-yara (>= 3.4.0), python3-zmq (>= 2.1.11), python3-zstd (>= 1.3.0.2), ${misc:Depends}
Depends: plaso-data (>= ${binary:Version}), libbde-python3 (>= 20220121), libcaes-python3 (>= 20240114), libcreg-python3 (>= 20200725), libesedb-python3 (>= 20220806), libevt-python3 (>= 20191104), libevtx-python3 (>= 20220724), libewf-python3 (>= 20131210), libfcrypto-python3 (>= 20240114), libfsapfs-python3 (>= 20220709), libfsext-python3 (>= 20220829), libfsfat-python3 (>= 20220925), libfshfs-python3 (>= 20220831), libfsntfs-python3 (>= 20211229), libfsxfs-python3 (>= 20220829), libfvde-python3 (>= 20220121), libfwnt-python3 (>= 20210717), libfwsi-python3 (>= 20240225), liblnk-python3 (>= 20230716), libluksde-python3 (>= 20220121), libmodi-python3 (>= 20210405), libmsiecf-python3 (>= 20150314), libolecf-python3 (>= 20151223), libphdi-python3 (>= 20220228), libqcow-python3 (>= 20201213), libregf-python3 (>= 20201002), libscca-python3 (>= 20190605), libsigscan-python3 (>= 20230109), libsmdev-python3 (>= 20140529), libsmraw-python3 (>= 20140612), libvhdi-python3 (>= 20201014), libvmdk-python3 (>= 20140421), libvsapm-python3 (>= 20230506), libvsgpt-python3 (>= 20211115), libvshadow-python3 (>= 20160109), libvslvm-python3 (>= 20160109), python3-acstore (>= 20240406), python3-artifacts (>= 20220219), python3-bencode, python3-certifi (>= 2016.9.26), python3-cffi-backend (>= 1.9.1), python3-chardet (>= 2.0.1), python3-dateutil (>= 1.5), python3-defusedxml (>= 0.5.0), python3-dfdatetime (>= 20240330), python3-dfvfs (>= 20240115), python3-dfwinreg (>= 20240229), python3-dtfabric (>= 20230518), python3-flor (>= 1.1.3), python3-future (>= 0.16.0), python3-idna (>= 2.5), python3-lz4 (>= 0.10.0), python3-opensearch, python3-pefile (>= 2021.5.24), python3-psutil (>= 5.4.3), python3-pyparsing (>= 3.0.0), python3-pytsk3 (>= 20210419), python3-redis (>= 3.4), python3-requests (>= 2.18.0), python3-six (>= 1.1.0), python3-tz, python3-urllib3 (>= 1.21.1), python3-xattr (>= 0.7.2), python3-xlsxwriter (>= 0.9.3), python3-yaml (>= 3.10), python3-yara (>= 3.4.0), python3-zmq (>= 2.1.11), python3-zstd (>= 1.3.0.2), ${misc:Depends}
Description: Python 3 module of plaso (log2timeline)
Plaso (log2timeline) is a framework to create super timelines. Its
purpose is to extract timestamps from various files found on typical
Expand Down
2 changes: 1 addition & 1 deletion dependencies.ini
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[acstore]
dpkg_name: python3-acstore
minimum_version: 20240121
minimum_version: 20240406
rpm_name: python3-acstore
version_property: __version__

Expand Down
2 changes: 1 addition & 1 deletion plaso/dependencies.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
# Where version_attribute_name is either a name of an attribute,
# property or method.
PYTHON_DEPENDENCIES = {
'acstore': ('__version__', '20240121', None, True),
'acstore': ('__version__', '20240406', None, True),
'artifacts': ('__version__', '20220219', None, True),
'bencode': ('', '', None, True),
'certifi': ('__version__', '2016.9.26', None, True),
Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
PyYAML >= 3.10
XlsxWriter >= 0.9.3
acstore >= 20240121
acstore >= 20240406
artifacts >= 20220219
bencode.py
certifi >= 2016.9.26
Expand Down
28 changes: 8 additions & 20 deletions tests/serializer/json_serializer.py
Original file line number Diff line number Diff line change
Expand Up @@ -159,13 +159,13 @@ def testReadAndWriteSerializedEventDataStream(self):

volume_path_spec = path_spec_factory.Factory.NewPathSpec(
dfvfs_definitions.TYPE_INDICATOR_OS, location=test_file_path)
path_spec = path_spec_factory.Factory.NewPathSpec(
test_path_spec = path_spec_factory.Factory.NewPathSpec(
dfvfs_definitions.TYPE_INDICATOR_TSK, location='/',
parent=volume_path_spec)

expected_event_data_stream = events.EventDataStream()
expected_event_data_stream.md5_hash = 'e3df0d2abd2c27fbdadfb41a47442520'
expected_event_data_stream.path_spec = path_spec
expected_event_data_stream.path_spec = test_path_spec

json_string = (
json_serializer.JSONAttributeContainerSerializer.WriteSerialized(
Expand All @@ -182,25 +182,19 @@ def testReadAndWriteSerializedEventDataStream(self):

expected_event_data_stream_dict = {
'md5_hash': 'e3df0d2abd2c27fbdadfb41a47442520',
'path_spec': {
'__type__': 'PathSpec',
'location': '/',
'parent': {
'__type__': 'PathSpec',
'location': test_file_path,
'type_indicator': 'OS'},
'type_indicator': 'TSK'}}
'path_spec': test_path_spec}

event_data_stream_dict = event_data_stream.CopyToDict()

self.assertEqual(event_data_stream_dict, expected_event_data_stream_dict)

def testReadAndWriteSerializedEventObject(self):
"""Test ReadSerialized and WriteSerialized of EventObject."""
test_date_time = dfdatetime_posix_time.PosixTime(timestamp=1621839644)

expected_event = events.EventObject()
expected_event._event_data_identifier = 'event_data.1'
expected_event.date_time = dfdatetime_posix_time.PosixTime(
timestamp=1621839644)
expected_event.date_time = test_date_time
expected_event.timestamp = 1621839644
expected_event.timestamp_desc = definitions.TIME_DESCRIPTION_MODIFICATION

Expand All @@ -218,10 +212,7 @@ def testReadAndWriteSerializedEventObject(self):

expected_event_dict = {
'_event_data_identifier': 'event_data.1',
'date_time': {
'__class_name__': 'PosixTime',
'__type__': 'DateTimeValues',
'timestamp': 1621839644},
'date_time': test_date_time,
'timestamp': 1621839644,
'timestamp_desc': definitions.TIME_DESCRIPTION_MODIFICATION}

Expand Down Expand Up @@ -249,10 +240,7 @@ def testReadAndWriteSerializedEventSource(self):
self.assertIsInstance(event_source, event_sources.EventSource)

expected_event_source_dict = {
'path_spec': {
'__type__': 'PathSpec',
'location': '/opt/plaso.txt',
'type_indicator': 'FAKE'}}
'path_spec': test_path_spec}

event_source_dict = event_source.CopyToDict()

Expand Down

0 comments on commit e7b4bd3

Please sign in to comment.