Skip to content

Commit bb0a262

Browse files
committed
Changed formatters to use configuration log2timeline#444
1 parent 78d16fc commit bb0a262

27 files changed

+392
-498
lines changed

data/formatters/browser.yaml

+116
Original file line numberDiff line numberDiff line change
@@ -71,13 +71,71 @@ short_message:
7171
- '({received_bytes} bytes)'
7272
---
7373
type: 'conditional'
74+
data_type: 'chrome:history:page_visited'
75+
boolean_helpers:
76+
- input_attribute: 'url_hidden'
77+
output_attribute: 'url_hidden_string'
78+
value_if_true: '(URL hidden)'
79+
enumeration_helpers:
80+
- input_attribute: 'page_transition_type'
81+
output_attribute: 'page_transition'
82+
default_value: 'UNKNOWN'
83+
# Also see: https://cs.chromium.org/chromium/src/ui/base/page_transition_types.h
84+
values:
85+
0: 'LINK - User clicked a link'
86+
1: 'TYPED - User typed the URL in the URL bar'
87+
2: 'AUTO_BOOKMARK - Got through a suggestion in the UI'
88+
3: 'AUTO_SUBFRAME - Content automatically loaded in a non-toplevel frame - user may not realize'
89+
4: 'MANUAL_SUBFRAME - Subframe explicitly requested by the user'
90+
5: 'GENERATED - User typed in the URL bar and selected an entry from the list - such as a search bar'
91+
6: 'START_PAGE - The start page of the browser'
92+
7: 'FORM_SUBMIT - A form the user has submitted values to'
93+
8: 'RELOAD - The user reloaded the page, eg by hitting the reload button or restored a session'
94+
9: 'KEYWORD - URL what was generated from a replaceable keyword other than the default search provider'
95+
10: 'KEYWORD_GENERATED - Corresponds to a visit generated from a KEYWORD'
96+
- input_attribute: 'visit_source'
97+
output_attribute: 'visit_source'
98+
default_value: 'UNKNOWN'
99+
# Also see: https://cs.chromium.org/chromium/src/ui/app_list/search/history_types.h
100+
values:
101+
0: 'SOURCE_SYNCED'
102+
1: 'SOURCE_BROWSED'
103+
2: 'SOURCE_EXTENSION'
104+
3: 'SOURCE_FIREFOX_IMPORTED'
105+
4: 'SOURCE_IE_IMPORTED'
106+
5: 'SOURCE_SAFARI_IMPORTED'
107+
message:
108+
- '{url}'
109+
- '({title})'
110+
- '[count: {typed_count}]'
111+
- 'Visit from: {from_visit}'
112+
- 'Visit Source: [{visit_source}]'
113+
- 'Type: [{page_transition}]'
114+
- '{url_hidden_string}'
115+
- '{url_typed_string}'
116+
short_message:
117+
- '{url}'
118+
- '({title})'
119+
---
120+
type: 'conditional'
74121
data_type: 'chrome:preferences:clear_history'
75122
message:
76123
- '{message}'
77124
short_message:
78125
- '{message}'
79126
---
80127
type: 'conditional'
128+
data_type: 'chrome:preferences:content_settings:exceptions'
129+
message:
130+
- 'Permission {permission}'
131+
- 'used by {primary_url}'
132+
- 'embedded in {secondary_url}'
133+
short_message:
134+
- 'Permission {permission}'
135+
- 'used by {primary_url}'
136+
- 'embedded in {secondary_url}'
137+
---
138+
type: 'conditional'
81139
data_type: 'chrome:preferences:extensions_autoupdater'
82140
message:
83141
- '{message}'
@@ -193,12 +251,53 @@ data_type: 'firefox:places:bookmark_folder'
193251
message: '{title}'
194252
short_message: '{title}'
195253
---
254+
type: 'conditional'
255+
data_type: 'firefox:places:page_visited'
256+
enumeration_helpers:
257+
- input_attribute: 'visit_type'
258+
output_attribute: 'transition_string'
259+
default_value: 'UNKOWN'
260+
# Also see: src/toolkit/components/places/nsINavHistoryService.idl
261+
values:
262+
1: 'LINK'
263+
2: 'TYPED'
264+
3: 'BOOKMARK'
265+
4: 'EMBED'
266+
5: 'REDIRECT_PERMANENT'
267+
6: 'REDIRECT_TEMPORARY'
268+
7: 'DOWNLOAD'
269+
8: 'FRAMED_LINK'
270+
message:
271+
- '{url}'
272+
- '({title})'
273+
- '[count: {visit_count}]'
274+
- 'Host: {host}'
275+
- 'visited from: {from_visit}'
276+
- '{url_hidden_string}'
277+
- '{url_typed_string}'
278+
- 'Transition: {transition_string}'
279+
short_message:
280+
- 'URL: {url}'
281+
---
196282
type: 'basic'
197283
data_type: 'firefox:downloads:download'
198284
message: '{url} ({full_path}). Received: {received_bytes} bytes out of: {total_bytes} bytes.'
199285
short_message: '{full_path} downloaded ({received_bytes} bytes)'
200286
---
201287
type: 'conditional'
288+
data_type: 'msiecf:leak'
289+
boolean_helpers:
290+
- input_attribute: 'recovered'
291+
output_attribute: 'recovered_string'
292+
value_if_true: '[Recovered Entry]'
293+
message:
294+
- 'Cached file: {cached_file_path}'
295+
- 'Cached file size: {cached_file_size}'
296+
- '{recovered_string}'
297+
short_message:
298+
- 'Cached file: {cached_file_path}'
299+
---
300+
type: 'conditional'
202301
data_type: 'msiecf:redirected'
203302
boolean_helpers:
204303
- input_attribute: 'recovered'
@@ -211,6 +310,23 @@ short_message:
211310
- 'Location: {url}'
212311
---
213312
type: 'conditional'
313+
data_type: 'msiecf:url'
314+
boolean_helpers:
315+
- input_attribute: 'recovered'
316+
output_attribute: 'recovered_string'
317+
value_if_true: '[Recovered Entry]'
318+
message:
319+
- 'Location: {url}'
320+
- 'Number of hits: {number_of_hits}'
321+
- 'Cached file: {cached_file_path}'
322+
- 'Cached file size: {cached_file_size}'
323+
- 'HTTP headers: {http_headers}'
324+
- '{recovered_string}'
325+
short_message:
326+
- 'Location: {url}'
327+
- 'Cached file: {cached_file_path}'
328+
---
329+
type: 'conditional'
214330
data_type: 'msie:webcache:container'
215331
message:
216332
- 'URL: {url}'

data/formatters/generic.yaml

+72-1
Original file line numberDiff line numberDiff line change
@@ -182,10 +182,55 @@ message: '{filename}'
182182
short_message: '{filename}'
183183
---
184184
type: 'conditional'
185+
data_type: 'fs:ntfs:usn_change'
186+
flags_helpers:
187+
- input_attribute: 'update_reason_flags'
188+
output_attribute: 'update_reason'
189+
values:
190+
0x00000001: 'USN_REASON_DATA_OVERWRITE'
191+
0x00000002: 'USN_REASON_DATA_EXTEND'
192+
0x00000004: 'USN_REASON_DATA_TRUNCATION'
193+
0x00000010: 'USN_REASON_NAMED_DATA_OVERWRITE'
194+
0x00000020: 'USN_REASON_NAMED_DATA_EXTEND'
195+
0x00000040: 'USN_REASON_NAMED_DATA_TRUNCATION'
196+
0x00000100: 'USN_REASON_FILE_CREATE'
197+
0x00000200: 'USN_REASON_FILE_DELETE'
198+
0x00000400: 'USN_REASON_EA_CHANGE'
199+
0x00000800: 'USN_REASON_SECURITY_CHANGE'
200+
0x00001000: 'USN_REASON_RENAME_OLD_NAME'
201+
0x00002000: 'USN_REASON_RENAME_NEW_NAME'
202+
0x00004000: 'USN_REASON_INDEXABLE_CHANGE'
203+
0x00008000: 'USN_REASON_BASIC_INFO_CHANGE'
204+
0x00010000: 'USN_REASON_HARD_LINK_CHANGE'
205+
0x00020000: 'USN_REASON_COMPRESSION_CHANGE'
206+
0x00040000: 'USN_REASON_ENCRYPTION_CHANGE'
207+
0x00080000: 'USN_REASON_OBJECT_ID_CHANGE'
208+
0x00100000: 'USN_REASON_REPARSE_POINT_CHANGE'
209+
0x00200000: 'USN_REASON_STREAM_CHANGE'
210+
0x00400000: 'USN_REASON_TRANSACTED_CHANGE'
211+
0x80000000: 'USN_REASON_CLOSE'
212+
- input_attribute: 'update_source_flags'
213+
output_attribute: 'update_source'
214+
values:
215+
0x00000001: 'USN_SOURCE_DATA_MANAGEMENT'
216+
0x00000002: 'USN_SOURCE_AUXILIARY_DATA'
217+
0x00000004: 'USN_SOURCE_REPLICATION_MANAGEMENT'
218+
message:
219+
- '{filename}'
220+
- 'File reference: {file_reference}'
221+
- 'Parent file reference: {parent_file_reference}'
222+
- 'Update source: {update_source}'
223+
- 'Update reason: {update_reason}'
224+
short_message:
225+
- '{filename}'
226+
- '{file_reference}'
227+
- '{update_reason}'
228+
---
229+
type: 'conditional'
185230
data_type: 'fs:stat'
186231
boolean_helpers:
187232
- input_attribute: 'is_allocated'
188-
output_attribute: 'is_allocated'
233+
output_attribute: 'unallocated'
189234
value_if_false: 'unallocated'
190235
message:
191236
- '{display_name}'
@@ -195,6 +240,32 @@ short_message:
195240
- '{filename}'
196241
---
197242
type: 'conditional'
243+
data_type: 'fs:stat:ntfs'
244+
boolean_helpers:
245+
- input_attribute: 'is_allocated'
246+
output_attribute: 'unallocated'
247+
value_if_false: 'unallocated'
248+
enumeration_helpers:
249+
- input_attribute: 'attribute_type'
250+
output_attribute: 'attribute_name'
251+
default_value: 'UNKNOWN'
252+
values:
253+
0x00000010: '$STANDARD_INFORMATION'
254+
0x00000030: '$FILE_NAME'
255+
message:
256+
- '{display_name}'
257+
- 'File reference: {file_reference}'
258+
- 'Attribute name: {attribute_name}'
259+
- 'Name: {name}'
260+
- 'Parent file reference: {parent_file_reference}'
261+
- '({unallocated})'
262+
- 'Path hints: {path_hints}'
263+
short_message:
264+
- '{filename}'
265+
- '{file_reference}'
266+
- '{attribute_name}'
267+
---
268+
type: 'conditional'
198269
data_type: 'gdrive:snapshot:cloud_entry'
199270
boolean_helpers:
200271
- input_attribute: 'shared'

data/formatters/windows.yaml

+56-7
Original file line numberDiff line numberDiff line change
@@ -160,6 +160,28 @@ short_message:
160160
- ': {dest_port}'
161161
---
162162
type: 'conditional'
163+
data_type: 'windows:lnk:link'
164+
message:
165+
- '[{description}]'
166+
- 'File size: {file_size}'
167+
- 'File attribute flags: 0x{file_attribute_flags:08x}'
168+
- 'Drive type: {drive_type}'
169+
- 'Drive serial number: 0x{drive_serial_number:08x}'
170+
- 'Volume label: {volume_label}'
171+
- 'Local path: {local_path}'
172+
- 'Network path: {network_path}'
173+
- 'cmd arguments: {command_line_arguments}'
174+
- 'env location: {env_var_location}'
175+
- 'Relative path: {relative_path}'
176+
- 'Working dir: {working_directory}'
177+
- 'Icon location: {icon_location}'
178+
- 'Link target: {link_target}'
179+
short_message:
180+
- '[{description}]'
181+
- '{linked_path}'
182+
- '{command_line_arguments}'
183+
---
184+
type: 'conditional'
163185
data_type: 'windows:metadata:deleted_item'
164186
enumeration_helpers:
165187
- input_attribute: 'drive_number'
@@ -201,15 +223,17 @@ short_message:
201223
- 'Deleted file: {original_filename}'
202224
---
203225
type: 'conditional'
204-
data_type: 'windows:registry:explorer:programcache'
226+
data_type: 'windows:prefetch:execution'
205227
message:
206-
- 'Key: {key_path}'
207-
- 'Value: {value_name}'
208-
- 'Entries: [{entries}]'
228+
- 'Prefetch'
229+
- '[{executable}] was executed -'
230+
- 'run count {run_count}'
231+
- 'path hints: {path_hints}'
232+
- 'hash: 0x{prefetch_hash:08X}'
233+
- '{volumes_string}'
209234
short_message:
210-
- 'Key: {key_path}'
211-
- 'Value: {value_name}'
212-
- 'Entries: [{entries}]'
235+
- '{executable} was run'
236+
- '{run_count} time(s)'
213237
---
214238
type: 'conditional'
215239
data_type: 'windows:registry:amcache'
@@ -278,6 +302,17 @@ message: '[{key_path}] ImagePath: {image_path}'
278302
short_message: '[{key_path}] ImagePath: {image_path}'
279303
---
280304
type: 'conditional'
305+
data_type: 'windows:registry:explorer:programcache'
306+
message:
307+
- 'Key: {key_path}'
308+
- 'Value: {value_name}'
309+
- 'Entries: [{entries}]'
310+
short_message:
311+
- 'Key: {key_path}'
312+
- 'Value: {value_name}'
313+
- 'Entries: [{entries}]'
314+
---
315+
type: 'conditional'
281316
data_type: 'windows:registry:installation'
282317
message:
283318
- '{product_name}'
@@ -592,6 +627,20 @@ message: '[{key_path}] {entries}'
592627
short_message: '[{key_path}] {entries}'
593628
---
594629
type: 'conditional'
630+
data_type: 'windows:shell_item:file_entry'
631+
message:
632+
- 'Name: {name}'
633+
- 'Long name: {long_name}'
634+
- 'Localized name: {localized_name}'
635+
- 'NTFS file reference: {file_reference}'
636+
- 'Shell item path: {shell_item_path}'
637+
- 'Origin: {origin}'
638+
short_message:
639+
- 'Name: {file_entry_name}'
640+
- 'NTFS file reference: {file_reference}'
641+
- 'Origin: {origin}'
642+
---
643+
type: 'conditional'
595644
data_type: 'windows:srum:application_usage'
596645
message:
597646
- 'Application: {application}'

0 commit comments

Comments
 (0)