summaryrefslogtreecommitdiffstats
path: root/magic/Magdir/apt
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-15 17:00:10 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-15 17:00:10 +0000
commit1ebbd027274333758fc3517685d81847601db676 (patch)
tree5259d053d3e3066e0745150805fa4b20184eef98 /magic/Magdir/apt
parentInitial commit. (diff)
downloadfile-1ebbd027274333758fc3517685d81847601db676.tar.xz
file-1ebbd027274333758fc3517685d81847601db676.zip
Adding upstream version 1:5.45.upstream/1%5.45upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'magic/Magdir/apt')
-rw-r--r--magic/Magdir/apt52
1 files changed, 52 insertions, 0 deletions
diff --git a/magic/Magdir/apt b/magic/Magdir/apt
new file mode 100644
index 0000000..2d9f159
--- /dev/null
+++ b/magic/Magdir/apt
@@ -0,0 +1,52 @@
+
+#------------------------------------------------------------------------------
+# $File: apt,v 1.1 2016/10/17 19:51:57 christos Exp $
+# apt: file(1) magic for APT Cache files
+# <http://www.fifi.org/doc/libapt-pkg-doc/cache.html/ch2.html>
+# <https://anonscm.debian.org/cgit/apt/apt.git/tree/apt-pkg/pkgcache.h#n292>
+
+# before version 10 ("old format"), data was in arch-specific long/short
+
+# old format 64 bit
+0 name apt-cache-64bit-be
+>12 beshort 1 \b, dirty
+>40 bequad x \b, %llu packages
+>48 bequad x \b, %llu versions
+
+# old format 32 bit
+0 name apt-cache-32bit-be
+>8 beshort 1 \b, dirty
+>40 belong x \b, %u packages
+>44 belong x \b, %u versions
+
+# new format
+0 name apt-cache-be
+>6 byte 1 \b, dirty
+>24 belong x \b, %u packages
+>28 belong x \b, %u versions
+
+0 bequad 0x98FE76DC
+>8 ubeshort <10 APT cache data, version %u
+>>10 beshort x \b.%u, 64 bit big-endian
+>>0 use apt-cache-64bit-be
+
+0 lequad 0x98FE76DC
+>8 uleshort <10 APT cache data, version %u
+>>10 leshort x \b.%u, 64 bit little-endian
+>>0 use \^apt-cache-64bit-be
+
+0 belong 0x98FE76DC
+>4 ubeshort <10 APT cache data, version %u
+>>6 ubeshort x \b.%u, 32 bit big-endian
+>>0 use apt-cache-32bit-be
+>4 ubyte >9 APT cache data, version %u
+>>5 ubyte x \b.%u, big-endian
+>>0 use apt-cache-be
+
+0 lelong 0x98FE76DC
+>4 uleshort <10 APT cache data, version %u
+>>6 uleshort x \b.%u, 32 bit little-endian
+>>0 use \^apt-cache-32bit-be
+>4 ubyte >9 APT cache data, version %u
+>>5 ubyte x \b.%u, little-endian
+>>0 use \^apt-cache-be