xref: /dflybsd-src/contrib/file/magic/Magdir/sql (revision 82c5fa3ed529d94b87e8a4447aaa75bcff807696)
1327e51cbSPeter Avalos
2327e51cbSPeter Avalos#------------------------------------------------------------------------------
3*82c5fa3eSPeter Avalos# $File: sql,v 1.15 2014/04/30 21:41:02 christos Exp $
4327e51cbSPeter Avalos# sql:  file(1) magic for SQL files
5327e51cbSPeter Avalos#
6327e51cbSPeter Avalos# From: "Marty Leisner" <mleisner@eng.mc.xerox.com>
7327e51cbSPeter Avalos# Recognize some MySQL files.
8e8af9738SPeter Avalos# Elan Ruusamae <glen@delfi.ee>, added MariaDB signatures
9e8af9738SPeter Avalos# from https://bazaar.launchpad.net/~maria-captains/maria/5.5/view/head:/support-files/magic
10327e51cbSPeter Avalos#
11327e51cbSPeter Avalos0	beshort			0xfe01		MySQL table definition file
12327e51cbSPeter Avalos>2	byte			x		Version %d
13e8af9738SPeter Avalos0	belong&0xffffff00	0xfefe0700	MySQL MyISAM index file
14327e51cbSPeter Avalos>3	byte			x		Version %d
15e8af9738SPeter Avalos0	belong&0xffffff00	0xfefe0800	MySQL MyISAM compressed data file
16e8af9738SPeter Avalos>3	byte			x		Version %d
17e8af9738SPeter Avalos0	belong&0xffffff00	0xfefe0900	MySQL Maria index file
18e8af9738SPeter Avalos>3	byte			x		Version %d
19e8af9738SPeter Avalos0	belong&0xffffff00	0xfefe0A00	MySQL Maria compressed data file
20327e51cbSPeter Avalos>3	byte			x		Version %d
21327e51cbSPeter Avalos0	belong&0xffffff00	0xfefe0500	MySQL ISAM index file
22327e51cbSPeter Avalos>3	byte			x		Version %d
23327e51cbSPeter Avalos0	belong&0xffffff00	0xfefe0600	MySQL ISAM compressed data file
24327e51cbSPeter Avalos>3	byte			x		Version %d
25327e51cbSPeter Avalos0	string			\376bin		MySQL replication log
26e8af9738SPeter Avalos0	belong&0xffffff00	0xfefe0b00
27e8af9738SPeter Avalos>4	string			MARIALOG	MySQL Maria transaction log file
28e8af9738SPeter Avalos>>3	byte			x		Version %d
29e8af9738SPeter Avalos0	belong&0xffffff00	0xfefe0c00
30e8af9738SPeter Avalos>4	string			MACF		MySQL Maria control file
31e8af9738SPeter Avalos>>3	byte			x		Version %d
32327e51cbSPeter Avalos
33327e51cbSPeter Avalos#------------------------------------------------------------------------------
34327e51cbSPeter Avalos# iRiver H Series database file
35327e51cbSPeter Avalos# From Ken Guest <ken@linux.ie>
36327e51cbSPeter Avalos# As observed from iRivNavi.iDB and unencoded firmware
37327e51cbSPeter Avalos#
38327e51cbSPeter Avalos0   string		iRivDB	iRiver Database file
39327e51cbSPeter Avalos>11  string	>\0	Version %s
40327e51cbSPeter Avalos>39  string		iHP-100	[H Series]
41327e51cbSPeter Avalos
42327e51cbSPeter Avalos#------------------------------------------------------------------------------
43327e51cbSPeter Avalos# SQLite database files
44327e51cbSPeter Avalos# Ken Guest <ken@linux.ie>, Ty Sarna, Zack Weinberg
45327e51cbSPeter Avalos#
46327e51cbSPeter Avalos# Version 1 used GDBM internally; its files cannot be distinguished
47327e51cbSPeter Avalos# from other GDBM files.
48327e51cbSPeter Avalos#
49327e51cbSPeter Avalos# Version 2 used this format:
50327e51cbSPeter Avalos0	string	**\ This\ file\ contains\ an\ SQLite  SQLite 2.x database
51327e51cbSPeter Avalos
52327e51cbSPeter Avalos# Version 3 of SQLite allows applications to embed their own "user version"
53e8af9738SPeter Avalos# number in the database at offset 60.  Later, SQLite added an "application id"
54e8af9738SPeter Avalos# at offset 68 that is preferred over "user version" for indicating the
55e8af9738SPeter Avalos# associated application.
56e8af9738SPeter Avalos#
57327e51cbSPeter Avalos0   string  SQLite\ format\ 3
58e8af9738SPeter Avalos>60 belong  =0x5f4d544e  Monotone source repository - SQLite3 database
59e8af9738SPeter Avalos>68 belong  =0x0f055112  Fossil checkout - SQLite3 database
60e8af9738SPeter Avalos>68 belong  =0x0f055113  Fossil global configuration - SQLite3 database
61e8af9738SPeter Avalos>68 belong  =0x0f055111  Fossil repository - SQLite3 database
62e8af9738SPeter Avalos>68 belong  =0x42654462  Bentley Systems BeSQLite Database - SQLite3 database
63e8af9738SPeter Avalos>68 belong  =0x42654c6e  Bentley Systems Localization File - SQLite3 database
64e8af9738SPeter Avalos>68 belong  =0x47504b47  OGC GeoPackage file - SQLite3 database
65e8af9738SPeter Avalos>68 default x            SQLite 3.x database
66e8af9738SPeter Avalos>>68 belong  !0          \b, application id %u
67e8af9738SPeter Avalos>>60 belong  !0          \b, user version %d
68e8af9738SPeter Avalos
69e8af9738SPeter Avalos# SQLite Write-Ahead Log from SQLite version >= 3.7.0
70e8af9738SPeter Avalos# http://www.sqlite.org/fileformat.html#walformat
71e8af9738SPeter Avalos0	belong&0xfffffffe	0x377f0682	SQLite Write-Ahead Log,
72*82c5fa3eSPeter Avalos>4	belong	x	version %d
73e8af9738SPeter Avalos
74e8af9738SPeter Avalos# SQLite Rollback Journal
75e8af9738SPeter Avalos# http://www.sqlite.org/fileformat.html#rollbackjournal
76e8af9738SPeter Avalos0	string	\xd9\xd5\x05\xf9\x20\xa1\x63\xd7	SQLite Rollback Journal
77e8af9738SPeter Avalos
78e8af9738SPeter Avalos# Panasonic channel list database svl.bin or svl.db added by Joerg Jenderek
79e8af9738SPeter Avalos# http://www.ullrich.es/job/service-menue/panasonic/panasonic-sendersortierung-sat-am-pc/
80e8af9738SPeter Avalos# pceditor_V2003.jar
81e8af9738SPeter Avalos0	string		PSDB\0			Panasonic channel list database
82e8af9738SPeter Avalos>126	string		SQLite\ format\ 3
83e8af9738SPeter Avalos>>&-15	indirect	x			\b; contains
84