1c2931133SXin LI 2c2931133SXin LI#------------------------------------------------------------------------------ 3*48c779cdSXin LI# $File: kerberos,v 1.3 2019/04/19 00:42:27 christos Exp $ 4c2931133SXin LI# kerberos: MIT kerberos file binary formats 5c2931133SXin LI# 6c2931133SXin LI 7c2931133SXin LI# This magic entry is for demonstration purposes and could be improved 8c2931133SXin LI# if the following features were implemented in file: 9c2931133SXin LI# 10c2931133SXin LI# Strings inside [[ .. ]] in the descriptions have special meanings and 11c2931133SXin LI# are not printed. 12c2931133SXin LI# 13c2931133SXin LI# - Provide some form of iteration in number of components 14c2931133SXin LI# [[${counter}=%d]] in the description 15c2931133SXin LI# then append 16c2931133SXin LI# [${counter}--] in the offset of the entries 17c2931133SXin LI# - Provide a way to round the next offset 18c2931133SXin LI# Add [R:4] after the offset? 19c2931133SXin LI# - Provide a way to have optional entries 20c2931133SXin LI# XXX: Syntax: 21c2931133SXin LI# - Provide a way to "save" entries to print them later. 22c2931133SXin LI# if the description is [[${name}=%s]], then nothing is 23c2931133SXin LI# printed and a subsequent entry in the same magic file 24c2931133SXin LI# can refer to ${name} 25c2931133SXin LI# - Provide a way to format strings as hex values 26c2931133SXin LI# 27*48c779cdSXin LI# https://www.gnu.org/software/shishi/manual/html_node/\ 28c2931133SXin LI# The-Keytab-Binary-File-Format.html 29c2931133SXin LI# 30c2931133SXin LI 31c2931133SXin LI0 name keytab_entry 32c2931133SXin LI#>0 beshort x \b, size=%d 33c2931133SXin LI#>2 beshort x \b, components=%d 34c2931133SXin LI>4 pstring/H x \b, realm=%s 35c2931133SXin LI>>&0 pstring/H x \b, principal=%s/ 36c2931133SXin LI>>>&0 pstring/H x \b%s 37c2931133SXin LI>>>>&0 belong x \b, type=%d 38c2931133SXin LI>>>>>&0 bedate x \b, date=%s 39c2931133SXin LI>>>>>>&0 byte x \b, kvno=%u 40c2931133SXin LI#>>>>>>>&0 pstring/H x 41c2931133SXin LI#>>>>>>>>&0 belong x 42c2931133SXin LI#>>>>>>>>>>&0 use keytab_entry 43c2931133SXin LI 44c2931133SXin LI0 belong 0x05020000 Kerberos Keytab file 45c2931133SXin LI>4 use keytab_entry 46