@@ -14,7 +14,7 @@ SQLite Dissect is a SQLite parser with recovery abilities over SQLite databases
1414and their accompanying journal files. If no options are set other than the file
1515name, the default behaviour will be to check for any journal files and print to
1616the console the output of the SQLite files. The directory of the SQLite file
17- specified will be searched through to find the associated journal files. If
17+ specified will be searched through to find the associated journal files. If
1818they are not in the same directory as the specified file, they will not be found
1919and their location will need to be specified in the command. SQLite carving
2020will not be done by default. Please see the options below to enable carving.
@@ -23,7 +23,7 @@ will not be done by default. Please see the options below to enable carving.
2323
2424| Argument | Description | Example Usage |
2525| -------------| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| --------------------------------|
26- | SQLITE_PATH | The path and filename of the SQLite file or directory to be carved. If a directory is provided, it will recursively search for files with the extensions: ` .db ` , ` .sqlite ` , ` .sqlite3 ` . | ` sqlite_dissect SQLITE_PATH ` |
26+ | SQLITE_PATH | The path and filename of the SQLite file or directory to be carved. If a directory is provided, it will recursively search for files with the extensions: ` .db ` , ` .sqlite ` , ` .sqlite3 ` . | ` sqlite_dissect SQLITE_PATH ` |
2727
2828
2929#### Optional Arguments:
@@ -85,18 +85,18 @@ sqlite_dissect [SQLITE_PATH] --signatures -d [OUTPUT_DIRECTORY] -e sqlite --carv
8585sqlite_dissect [SQLITE_PATH] -d [OUTPUT_DIRECTORY] -e sqlite --carve --carve-freelists -b [TABLES]
8686```
8787
88- 6 . Parse a SQLite database file and print the output to a xlsx workbook along with generating signatures and
89- carving entries. The schema history (schema updates throughout the WAL are included if a WAL file is detected) and
88+ 6 . Parse a SQLite database file and print the output to a xlsx workbook along with generating signatures and
89+ carving entries. The schema history (schema updates throughout the WAL are included if a WAL file is detected) and
9090 signatures will be printed to standard output. The log level will be set to debug and all log messages will be
9191 output to the specified log file.
9292
9393``` shell
9494sqlite_dissect [SQLITE_PATH] -d [OUTPUT_DIRECTORY] -e xlsx --schema-history --carve --signatures --log-level debug -i [LOG_FILE]
9595```
9696
97- 7 . Parse a SQLite database file along with a specified rollback journal file and send the output to CSV files.
97+ 7 . Parse a SQLite database file along with a specified rollback journal file and send the output to CSV files.
9898 (CSV is the only output option currently implemented for rollback journal files)
99-
99+
100100``` shell
101101sqlite_dissect [SQLITE_PATH] -d [OUTPUT_DIRECTORY] -e csv --carve -j [ROLLBACK_JOURNAL]
102102```
@@ -149,17 +149,17 @@ export SQLD_EXPORT_TYPE="[text, sqlite, case]"
149149This application focuses on carving by analyzing the allocated content within each of the SQLite
150150database tables and creating signatures. Where there is no content in the table, the signature
151151is based off of analyzing the create table statement in the master schema table. The signature
152- contains the series of possible serial types that can be stored within the file for that table.
152+ contains the series of possible serial types that can be stored within the file for that table.
153153This signature is then applied to the unallocated content and freeblocks of the table b-tree in
154- the file. This includes both interior and leaf table b-tree pages for that table. The signatures
154+ the file. This includes both interior and leaf table b-tree pages for that table. The signatures
155155are only applied to the pages belonging to the particular b-tree page it was generated from due
156156to initial research showing that the pages when created or pulled from the freelist set are
157157overwritten with zeros for the unallocated portions. Fragments within the pages can be reported
158158on but, due to the size (<4 bytes), are not carved. Due to the fact that entries are added into
159159tables in SQLite from the end of the page and moving toward the beginning, the carving works
160- in the same manner in order to detect previously partially overwritten entries better. This
160+ in the same manner in order to detect previously partially overwritten entries better. This
161161carving can also be applied to the set of freelist pages within the SQLite file if specified
162- but the freelist pages are currently treated as sets of unallocated data with the exception
162+ but the freelist pages are currently treated as sets of unallocated data with the exception
163163of the freelist page metadata.
164164
165165The carving process does not currently account for index b-trees as the more pertinent information
@@ -185,12 +185,12 @@ a full unallocated block and only support export to csv files.
185185SQLite Dissect can support output to various forms: text, csv, xlsx, and sqlite. Due to certain
186186constraints on what can be written to some file types, certain modifications need to be made. For
187187instance, when writing SQLite columns such as row_id that are already going to pre-exist in the table
188- for export to a SQLite file we need to preface the columns with "sd_ " so they will not conflict with
189- the actual row_id column. This also applies to internal schema objects. If certain SQLite tables are
190- requested to be written to a SQLite file, than these will be prefaced with "iso_ " so they will not
191- conflict with similar internal schema objects that may already exist in the SQLite file bring written
192- to. In xlsx or csv, due to a "=" symbol indicating a type of equation, these are prefaced with a " "
193- character to avoid this issue. More details can be found in the code documentation of the export classes
188+ for export to a SQLite file we need to preface the columns with "sd_ " so they will not conflict with
189+ the actual row_id column. This also applies to internal schema objects. If certain SQLite tables are
190+ requested to be written to a SQLite file, than these will be prefaced with "iso_ " so they will not
191+ conflict with similar internal schema objects that may already exist in the SQLite file bring written
192+ to. In xlsx or csv, due to a "=" symbol indicating a type of equation, these are prefaced with a " "
193+ character to avoid this issue. More details can be found in the code documentation of the export classes
194194themselves.
195195
196196SQLite Dissect opens the file as read only and acts as a read only interpreter when parsing and carving
@@ -203,10 +203,10 @@ specified for output.
203203 (WAL or rollback) file. Journal files by themselves are not supported yet.
204204
205205#### Currently not implemented:
206- 1 . Signatures and carving are not implemented for "without rowid" tables or indexes. This will not cause an error
206+ 1 . Signatures and carving are not implemented for "without rowid" tables or indexes. This will not cause an error
207207 but will skip signature generation and carving processes.
208- 2 . Signatures and carving are not implemented for virtual tables. This will not cause an error but will skip
209- signature generation and carving processes. `Note: Even though virtual tables are skipped, virtual tables may
208+ 2 . Signatures and carving are not implemented for virtual tables. This will not cause an error but will skip
209+ signature generation and carving processes. `Note: Even though virtual tables are skipped, virtual tables may
210210 create other non-virtual tables which are not skipped. Currently nothing ties these tables back to the virtual
211211 table that created them.`
2122123 . Invalidated frames in WAL files are currently skipped and not parsed. `Note: This applies to previous WAL records
@@ -286,16 +286,16 @@ TODO:
286286- [ ] Incorporate signature generation input and output files once implemented.
287287- [ ] Incorporate "store in memory" arguments (currently set to False, more in depth operations may want it True).
288288- [ ] Implement multiple passes/depths.
289- - [ ] Test use cases for exempted tables with rollback journal and when combined with specified tables.
290- - [ ] Check on name vs table_name properties of the master schema entry.
289+ - [ ] Test use cases for exempted tables with rollback journal and when combined with specified tables.
290+ - [ ] Check on name vs table_name properties of the master schema entry.
291291- [ ] Test cases where the schema changes throughout the WAL file.
292292- [ ] Investigate handling of virtual and "without rowid" tables when creating table signatures through the interface.
293293- [ ] Documentation on "without rowid" tables and indexes in references to carving in help documentation.
294294- [ ] Make sure to address/print unallocated space (especially uncarved) from updated page numbers in commit records.
295295- [ ] Research if there can be journal files with a zero length database file or zero-length journal files.
296296- [ ] Research if there can be combinations and of multiple rollback journal and WAL files with the SQLite database.
297297- [ ] Validate initial research that allocation of freelist pages to a b-tree results in a wipe of the page data.
298- - [ ] Add additional logging messages to the master schema entries skipped in signature generation.
298+ - [ ] Add additional logging messages to the master schema entries skipped in signature generation.
299299- [ ] Integrate in the SQLite Forensic Corpus into tests.
300300- [ ] Look into updating terminology for versioning to timelining.
301301- [ ] Create PyUnit tests.
0 commit comments