xref: /freebsd/contrib/file/magic/Magdir/ssh (revision ae316d1d1cffd71ab7751f94e10118777a88e027)
1b6cee71dSXin LI# Type:	OpenSSH key files
2b6cee71dSXin LI# From:	Nicolas Collignon <tsointsoin@gmail.com>
3*ae316d1dSXin LI# Update:	Joerg Jenderek
4*ae316d1dSXin LI# URL:		https://en.wikipedia.org/wiki/Secure_Shell_Protocol
5b6cee71dSXin LI
6898496eeSXin LI0	string	SSH\040PRIVATE\040KEY	OpenSSH RSA1 private key,
7b6cee71dSXin LI>28	string	>\0			version %s
8898496eeSXin LI0	string	-----BEGIN\040OPENSSH\040PRIVATE\040KEY-----	OpenSSH private key
9*ae316d1dSXin LI!:mime	application/x-pem-file
10898496eeSXin LI# https://www.rfc-editor.org/rfc/rfc5958
11898496eeSXin LI0	string	-----BEGIN\040PRIVATE\040KEY-----	OpenSSH private key (no password)
12*ae316d1dSXin LI#!:mime		text/plain
13*ae316d1dSXin LI!:mime		text/x-ssh-private-key
14*ae316d1dSXin LI!:ext		key
15898496eeSXin LI0	string	-----BEGIN\040ENCRYPTED\040PRIVATE\040KEY-----	OpenSSH private key (with password)
16*ae316d1dSXin LI# https://download.qemu.org/qemu-9.0.0.tar.xz
17*ae316d1dSXin LI# qemu-9.0.0/roms/skiboot/libstb/crypto/mbedtls/tests/data_files/format_gen.pub
18*ae316d1dSXin LI0	string	-----BEGIN\040PUBLIC\040KEY-----		OpenSSH public key
19*ae316d1dSXin LI#!:mime		text/plain
20*ae316d1dSXin LI!:mime		text/x-ssh-public-key
21*ae316d1dSXin LI!:ext		pub
22b6cee71dSXin LI
23*ae316d1dSXin LI# Reference:	http://mark0.net/download/triddefs_xml.7z/defs/p/pub-ssh-dss.trid.xml
24*ae316d1dSXin LI# Note:		called "SSH-DSS Public key" by TrID
25898496eeSXin LI0	string	ssh-dss\040		OpenSSH DSA public key
26*ae316d1dSXin LI#!:mime		text/plain
27*ae316d1dSXin LI!:mime		text/x-ssh-public-key
28*ae316d1dSXin LI!:ext		pub
29*ae316d1dSXin LI# Reference:	http://mark0.net/download/triddefs_xml.7z/defs/p/pub-ssh-rsa.trid.xml
30*ae316d1dSXin LI# Note:		called "SSH-RSA Public key" by TrID
31898496eeSXin LI0	string	ssh-rsa\040		OpenSSH RSA public key
32*ae316d1dSXin LI#!:mime		text/plain
33*ae316d1dSXin LI!:mime		text/x-ssh-public-key
34*ae316d1dSXin LI!:ext		pub
35b6cee71dSXin LI0	string	ecdsa-sha2-nistp256	OpenSSH ECDSA public key
36*ae316d1dSXin LI#!:mime		text/plain
37*ae316d1dSXin LI!:mime		text/x-ssh-public-key
38*ae316d1dSXin LI!:ext		pub
39*ae316d1dSXin LI# https://cvsweb.openbsd.org/src/usr.bin/ssh/PROTOCOL.u2f?annotate=HEAD
40*ae316d1dSXin LI0	string	sk-ecdsa-sha2-nistp256@openssh.com	OpenSSH U2F ECDSA public key
41*ae316d1dSXin LI#!:mime		text/plain
42*ae316d1dSXin LI!:mime		text/x-ssh-public-key
43*ae316d1dSXin LI!:ext		pub
44b6cee71dSXin LI0	string	ecdsa-sha2-nistp384	OpenSSH ECDSA public key
45*ae316d1dSXin LI#!:mime		text/plain
46*ae316d1dSXin LI!:mime		text/x-ssh-public-key
47*ae316d1dSXin LI!:ext		pub
48b6cee71dSXin LI0	string	ecdsa-sha2-nistp521	OpenSSH ECDSA public key
49*ae316d1dSXin LI#!:mime		text/plain
50*ae316d1dSXin LI!:mime		text/x-ssh-public-key
51*ae316d1dSXin LI!:ext		pub
52c2931133SXin LI0	string	ssh-ed25519		OpenSSH ED25519 public key
53*ae316d1dSXin LI#!:mime		text/plain
54*ae316d1dSXin LI!:mime		text/x-ssh-public-key
55*ae316d1dSXin LI!:ext		pub
56*ae316d1dSXin LI0	string	sk-ssh-ed25519@openssh.com	OpenSSH U2F ED25519 public key
57*ae316d1dSXin LI#!:mime		text/plain
58*ae316d1dSXin LI!:mime		text/x-ssh-public-key
59*ae316d1dSXin LI!:ext		pub
60*ae316d1dSXin LI
61*ae316d1dSXin LI
62d38c30c0SXin LI
63d38c30c0SXin LI0	string	SSHKRL\n\0
64d38c30c0SXin LI>8	ubelong	1		OpenSSH key/certificate revocation list, format %u
65d38c30c0SXin LI>>12	ubequad	x		\b, version %llx
66d38c30c0SXin LI>>>20	beqdate	x		\b, generated %s
67d38c30c0SXin LI
682726a701SXin LI# From:		Joerg Jenderek
692726a701SXin LI# URL:		https://en.wikipedia.org/wiki/PuTTY
702726a701SXin LI# Reference:	https://the.earth.li/~sgtatham/putty/latest/putty-0.73.tar.gz
712726a701SXin LI#		/sshpubk.c
722726a701SXin LI0	string		PuTTY-User-Key-File-	PuTTY Private Key File
732726a701SXin LI#!:mime	text/plain
742726a701SXin LI# https://github.com/github/putty/blob/master/windows/installer.wxs
752726a701SXin LI!:mime	application/x-putty-private-key
762726a701SXin LI!:ext	ppk
772726a701SXin LI# version 1 or 2
782726a701SXin LI>20	string		x			\b, version %.1s
792726a701SXin LI# name of the algorithm like: ssh-dss ssh-rsa ecdsa-sha2-nistp256 ssh-ed25519
802726a701SXin LI>23	string		x			\b, algorithm %s
812726a701SXin LI# next line says "Encryption: " plus an encryption type like aes256-cbc or none
822726a701SXin LI>32	search/13	Encryption:\040		\b, Encryption
832726a701SXin LI>>&0	string		x			%s
842726a701SXin LI# next line says "Comment: " plus the comment string
852726a701SXin LI>>>&0	search/3	Comment:\040
862726a701SXin LI>>>>&0	string		x			"%s"
872726a701SXin LI
88