1 2#------------------------------------------------------------------------------ 3# $File: commands,v 1.77 2024/11/10 16:55:15 christos Exp $ 4# commands: file(1) magic for various shells and interpreters 5# 6#0 string/w : shell archive or script for antique kernel text 70 string/fwt #!\ /bin/sh POSIX shell script text executable 8!:mime text/x-shellscript 90 string/fwb #!\ /bin/sh POSIX shell script executable (binary data) 10!:mime text/x-shellscript 11>10 string #\040This\040script\040was\040generated\040using\040Makeself \b, self-executable archive 12>>53 string x \b, Makeself %s 13 140 string/fwt #!\ /bin/csh C shell script text executable 15!:mime text/x-shellscript 16 17# korn shell magic, sent by George Wu, gwu@clyde.att.com 180 string/fwt #!\ /bin/ksh Korn shell script text executable 19!:mime text/x-shellscript 200 string/fwb #!\ /bin/ksh Korn shell script executable (binary data) 21!:mime text/x-shellscript 22 230 string/fwt #!\ /bin/tcsh Tenex C shell script text executable 24!:mime text/x-shellscript 250 string/fwt #!\ /usr/bin/tcsh Tenex C shell script text executable 26!:mime text/x-shellscript 270 string/fwt #!\ /usr/local/tcsh Tenex C shell script text executable 28!:mime text/x-shellscript 290 string/fwt #!\ /usr/local/bin/tcsh Tenex C shell script text executable 30!:mime text/x-shellscript 31 32# 33# zsh/ash/ae/nawk/gawk magic from cameron@cs.unsw.oz.au (Cameron Simpson) 340 string/fwt #!\ /bin/zsh Paul Falstad's zsh script text executable 35!:mime text/x-shellscript 360 string/fwt #!\ /usr/bin/zsh Paul Falstad's zsh script text executable 37!:mime text/x-shellscript 380 string/fwt #!\ /usr/local/bin/zsh Paul Falstad's zsh script text executable 39!:mime text/x-shellscript 400 string/fwt #!\ /usr/bin/env\ zsh Paul Falstad's zsh script text executable 41!:mime text/x-shellscript 42 430 string/fwt #!\ /bin/ash Neil Brown's ash script text executable 44!:mime text/x-shellscript 450 string/fwt #!\ /usr/bin/ash Neil Brown's ash script text executable 46!:mime text/x-shellscript 470 string/fwt #!\ /usr/local/bin/ash Neil Brown's ash script text executable 48!:mime text/x-shellscript 490 string/fwt #!\ /usr/local/bin/ae Neil Brown's ae script text executable 50!:mime text/x-shellscript 510 string/fwt #!\ /bin/nawk new awk script text executable 52!:mime text/x-nawk 530 string/fwt #!\ /usr/bin/nawk new awk script text executable 54!:mime text/x-nawk 550 string/fwt #!\ /usr/local/bin/nawk new awk script text executable 56!:mime text/x-nawk 570 string/fwt #!\ /bin/gawk GNU awk script text executable 58!:mime text/x-gawk 590 string/wt #!\ /usr/bin/gawk GNU awk script text executable 60!:mime text/x-gawk 610 string/fwt #!\ /usr/local/bin/gawk GNU awk script text executable 62!:mime text/x-gawk 63# 640 string/fwt #!\ /bin/awk awk script text executable 65!:mime text/x-awk 660 string/fwt #!\ /usr/bin/awk awk script text executable 67!:mime text/x-awk 680 regex/4096 =^[\040\t\f\r\n]{0,100}BEGIN[\040\t\f\r\n]{0,100}[{] awk or perl script text 69 70# AT&T Bell Labs' Plan 9 shell 710 string/fwt #!\ /bin/rc Plan 9 rc shell script text executable 72 73# bash shell magic, from Peter Tobias (tobias@server.et-inf.fho-emden.de) 740 string/fwt #!\ /bin/bash Bourne-Again shell script text executable 75!:mime text/x-shellscript 760 string/fwb #!\ /bin/bash Bourne-Again shell script executable (binary data) 77!:mime text/x-shellscript 780 string/fwt #!\ /usr/bin/bash Bourne-Again shell script text executable 79!:mime text/x-shellscript 800 string/fwb #!\ /usr/bin/bash Bourne-Again shell script executable (binary data) 81!:mime text/x-shellscript 820 string/fwt #!\ /usr/local/bash Bourne-Again shell script text executable 83!:mime text/x-shellscript 840 string/fwb #!\ /usr/local/bash Bourne-Again shell script executable (binary data) 85!:mime text/x-shellscript 860 string/fwt #!\ /usr/local/bin/bash Bourne-Again shell script text executable 87!:mime text/x-shellscript 880 string/fwb #!\ /usr/local/bin/bash Bourne-Again shell script executable (binary data) 89!:mime text/x-shellscript 900 string/fwt #!\ /usr/bin/env\ bash Bourne-Again shell script text executable 91!:mime text/x-shellscript 920 string/fwt #!\ /bin/env\ bash Bourne-Again shell script text executable 93!:mime text/x-shellscript 94 950 string/fwt #!\ /bin/dash Dash shell script text executable 96!:mime text/x-shellscript 970 string/fwt #!\ /usr/bin/dash Dash shell script text executable 98!:mime text/x-shellscript 99 100# Fish shell magic 101# From: Benjamin Lowry <ben@ben.gmbh> 1020 string/fwt #!\ /usr/local/bin/fish fish shell script text executable 103!:mime text/x-shellscript 1040 string/fwt #!\ /usr/bin/fish fish shell script text executable 105!:mime text/x-shellscript 1060 string/fwt #!\ /usr/bin/env\ fish fish shell script text executable 107!:mime text/x-shellscript 108 1090 search/1/fwt #!\ /usr/bin/tclsh Tcl/Tk script text executable 110!:mime text/x-tcl 111 1120 search/1/fwt #!\ /usr/bin/texlua LuaTex script text executable 113!:mime text/x-luatex 114 1150 search/1/fwt #!\ /usr/bin/luatex LuaTex script text executable 116!:mime text/x-luatex 117 1180 search/1/fwt #!\ /usr/bin/stap Systemtap script text executable 119!:mime text/x-systemtap 1200 search/1/fwt #!\ /sbin/openrc-run OpenRC script text executable 121!:mime text/x-shellscript 122 123# From: Kylie McClain <kylie@somas.is> 124# Type: execline scripts 125# URL: https://skarnet.org/software/execline/ 1260 string/fwt #!\ /command/execlineb execline script text executable 127!:mime text/x-execline 1280 string/fwt #!\ /bin/execlineb execline script text executable 129!:mime text/x-execline 1300 string/fwt #!\ /usr/bin/execlineb execline script text executable 131!:mime text/x-execline 1320 string/fwt #!\ /usr/bin/env\ execlineb execline script text executable 133!:mime text/x-execline 134 1350 string #! 136>0 regex \^#!.*/bin/execlineb([[:space:]].*)*$ execline script text executable 137!:mime text/x-execline 138 1390 string #!/nix/store/ 140>&-11 string/T x a %s script text executable 141 142# PHP scripts 143# Ulf Harnhammar <ulfh@update.uu.se> 1440 search/1/c =<?php PHP script text 145!:strength + 30 146!:mime text/x-php 1470 search/1 =<?\n PHP script text 148!:mime text/x-php 1490 search/1 =<?\r PHP script text 150!:mime text/x-php 1510 search/1/w #!\ /usr/local/bin/php PHP script text executable 152!:strength + 10 153!:mime text/x-php 1540 search/1/w #!\ /usr/bin/php PHP script text executable 155!:strength + 10 156!:mime text/x-php 157# Smarty compiled template, https://www.smarty.net/ 158# Elan Ruusamae <glen@delfi.ee> 1590 string =<?php 160>5 regex [\ \n] 161>>6 string /*\ Smarty\ version Smarty compiled template 162>>>24 regex [0-9.]+ \b, version %s 163!:mime text/x-php 164 1650 string Zend\x00 PHP script Zend Optimizer data 166 167# From: Anatol Belski <ab@php.net> 1680 string OPCACHE 169>7 ubyte 0 PHP opcache filecache data 170 1710 search/64 --TEST-- 172>16 search/64 --FILE-- 173>24 search/8192 --EXPECT PHP core test 174!:ext phpt 175 176# https://www.php.net/manual/en/phar.fileformat.signature.php 177-4 string GBMB PHP phar archive 178>-8 ubyte 0x1 with MD5 signature 179!:ext phar 180>-8 ubyte 0x2 with SHA1 signature 181!:ext phar 182>-8 ubyte 0x3 with SHA256 signature 183!:ext phar 184>-8 ubyte 0x4 with SHA512 signature 185!:ext phar 186>-8 ubyte 0x10 with OpenSSL signature 187!:ext phar 188>-8 ubyte 0x11 with OpenSSL SHA256 signature 189!:ext phar 190>-8 ubyte 0x12 with OpenSSL SHA512 signature 191!:ext phar 192 1930 string/t $! DCL command file 194 195# Type: Pdmenu 196# URL: https://packages.debian.org/pdmenu 197# From: Edward Betts <edward@debian.org> 1980 string #!/usr/bin/pdmenu Pdmenu configuration file text 199 200# From Danny Weldon 2010 string \x0b\x13\x08\x00 202>0x04 uleshort <4 ksh byte-code version %d 203 204# From: arno <arenevier@fdn.fr> 205# mozilla xpconnect typelib 206# see https://www.mozilla.org/scriptable/typelib_file.html 2070 string XPCOM\nTypeLib\r\n\032 XPConnect Typelib 208>0x10 byte x version %d 209>>0x11 byte x \b.%d 210 2110 string/fwt #!\ /usr/bin/env\ runghc GHC script executable 2120 string/fwt #!\ /usr/bin/env\ runhaskell Haskell script executable 2130 string/fwt #!\ /usr/bin/env\ julia Julia script executable 214