symbian Symbian OS v9.X SIS File Format Specification Version1.1 June 2006 Contents 1 INTRODUCTION.. 3 1.1 PURPOSE AND SCOPE SIS FILE FORMAT..... 21 OVERVIEW 2.1.1 Note on Reservation of SIS Field Values. 2.2 INTEGRITY. 2.3 EXTENSIBILITY. 2.4 COMPRESSION .4 2.5 NESTING 4 2.6 SUPPORTING THE RE-SIGNING OF A SIS FILE 2.7 PROGRAMMING CONSIDERATIONS..... 2.7.1 File Format. 4 2.7.2 Memory usage...... 2.8 SUPPORTING THE EMBEDDING OF A SIS FILE .5 2.9 BYTE ORDERING. 6 2.10 TEXT CHARACTER SET 7 2.11 FILE LIMITATIONS. .7 2.12 SIS FILE STRUCTURE OVERVIEW. 7 2123%oet 12 SIS FILE STRUCTURE. .8 3.1 FILE HEADER STRUCTURE 3131n3 3.1.4 UID Checksum. 0 SIS FIELDS.. 4.1 GENERAL SISFIELDS 411 SISS
Symbian OS v9.X SIS File Format Specification Version 1.1 June 2006 Contents 1 INTRODUCTION ....................................................................................................... 3 1.1 PURPOSE AND SCOPE ................................................................................................. 3 2 SIS FILE FORMAT.................................................................................................... 3 2.1 OVERVIEW .................................................................................................................. 3 2.1.1 Note on Reservation of SIS Field Values............................................................... 3 2.2 INTEGRITY................................................................................................................... 3 2.3 EXTENSIBILITY............................................................................................................. 4 2.4 COMPRESSION ............................................................................................................ 4 2.5 NESTING ..................................................................................................................... 4 2.6 SUPPORTING THE RE-SIGNING OF A SIS FILE ................................................................ 4 2.7 PROGRAMMING CONSIDERATIONS................................................................................ 4 2.7.1 File Format............................................................................................................. 4 2.7.2 Memory usage ....................................................................................................... 5 2.8 SUPPORTING THE EMBEDDING OF A SIS FILE ................................................................ 5 2.9 BYTE ORDERING.......................................................................................................... 6 2.10 TEXT CHARACTER SET ................................................................................................ 7 2.11 FILE LIMITATIONS ........................................................................................................ 7 2.12 SIS FILE STRUCTURE OVERVIEW................................................................................. 7 2.12.2 Alignment ............................................................................................................... 8 2.12.3 Notation.................................................................................................................. 8 3 SIS FILE STRUCTURE............................................................................................. 8 3.1 FILE HEADER STRUCTURE ........................................................................................... 8 3.1.1 UID 1...................................................................................................................... 9 3.1.2 UID 2...................................................................................................................... 9 3.1.3 UID 3...................................................................................................................... 9 3.1.4 UID Checksum....................................................................................................... 9 4 SIS FIELDS ............................................................................................................... 9 4.1 GENERAL SISFIELDS................................................................................................... 9 4.1.1 SISString................................................................................................................ 9 4.1.2 SISArray................................................................................................................. 9
symbian 4.1.3 SISCompressed. 10 10 4.1.8 SISDateTime. 41.11SS29 3 41.12 SISDatalndex. 73 4. SIS FILE META-DATA SISFIELDS 13 2, 422 erChecksum. 1 4.2.3 SISDataChecksum. 14 4 426 17 4.2.7 SISSupportedOptions T> 428 19 42 42 16 SISHash 22 4.3 SIGNATURES 4g2SScghagreCaahatecnan 131 24 4.3.3 SISSignature 4.4 EXPRESSIONS.. 25 4.4.1SSf 25 4.4.2 SISEIself 26 4.5 SIS FILE DATA 28 4.5.1 S/SData 30 APPENDIX A-ESISFIELDTYPE VALUES. .31 APPENDIX B-VARIABLE NAMES. 32 www.symbian.com
2 4.1.3 SISCompressed................................................................................................... 10 4.1.4 SISVersion ........................................................................................................... 10 4.1.5 SISVersionRange ................................................................................................ 11 4.1.6 SISDate................................................................................................................ 11 4.1.7 SISTime ............................................................................................................... 12 4.1.8 SISDateTime........................................................................................................ 12 4.1.9 SISUid.................................................................................................................. 12 4.1.10 SISLanguage ....................................................................................................... 12 4.1.11 SISBlob ................................................................................................................ 13 4.1.12 SISDataIndex....................................................................................................... 13 4.2 SIS FILE META-DATA SISFIELDS................................................................................ 13 4.2.1 SISContents......................................................................................................... 13 4.2.2 SISControllerChecksum....................................................................................... 14 4.2.3 SISDataChecksum............................................................................................... 14 4.2.4 SISController........................................................................................................ 14 4.2.5 SISInfo ................................................................................................................. 15 4.2.6 SISSupportedLanguages..................................................................................... 17 4.2.7 SISSupportedOptions .......................................................................................... 17 4.2.8 SISSupportedOption ............................................................................................ 18 4.2.9 SISPrerequisites .................................................................................................. 18 4.2.10 SISDependency................................................................................................... 18 4.2.11 SISProperties....................................................................................................... 19 4.2.12 SISProperty.......................................................................................................... 19 4.2.13 SISLogo ............................................................................................................... 19 4.2.14 SISFileDescription ............................................................................................... 19 4.2.15 SISCapabilities..................................................................................................... 22 4.2.16 SISHash............................................................................................................... 22 4.3 SIGNATURES ............................................................................................................. 23 4.3.1 SISSignatureCertificateChain .............................................................................. 23 4.3.2 SISCertificateChain.............................................................................................. 24 4.3.3 SISSignature........................................................................................................ 24 4.3.4 SISSignatureAlgorithm......................................................................................... 24 4.4 EXPRESSIONS ........................................................................................................... 25 4.4.1 SISIf ..................................................................................................................... 25 4.4.2 SISElseIf .............................................................................................................. 25 4.4.3 SISInstallBlock ..................................................................................................... 26 4.4.4 SISExpression ..................................................................................................... 26 4.5 SIS FILE DATA .......................................................................................................... 28 4.5.1 SISData................................................................................................................ 29 4.5.2 SISDataUnit ......................................................................................................... 29 4.5.3 SISFileData.......................................................................................................... 30 APPENDIX A - ESISFIELDTYPE VALUES............................................................................. 31 APPENDIX B - VARIABLE NAMES ..................................................................................... 32
symbian 1 Introduction 1.1 Purpose and Scope forcontaining files.the SIS file can contain a files for deplo influence the installation e.g.device specific installations,language-specific installations,and user- selectable optional components. theinstallaiontore that the pak mtsntybeornli can succee 2 SIS File Format 2.1 Overview ormation in the Sls file is split up two separate parts.The first part is the m e s contains all the actual file o b rder t copying the files to the device. 2.1.1 Note on Reservation of SIS Field Values Please note that Symbian reserves the right to extend the set of applicable values relating to defined SIS fields,for example,fields employing bit-indicators such as TInstalFlags. -outside t mbian OS.This may mean,therefore,that packages will fail to install. 2.2 Integrity TealeseoemtauRPoginsaialoaacaeaiceenem2beaerae8e9eeaeahe The SIS file for device. In order sup g.of vo phase only e me data of the SIS file ad The file data,and therefore the integrity of the entire is file is protected by the signed meta-data.This a being insta whilst using an untrusted component to perform any necessary decompression. Separate checksums for each of the meta-data and the file data are present in the SiS file to enable corrupt SiS files to be detected at the beginning of the installation process.These checksums are optiona. www.symbian.com
3 1 Introduction 1.1 Purpose and Scope This document describes the newly restructured and redesigned SIS file format, which is introduced to complement the Symbian OS v9.1 release of Software Install. SIS files are used as the primary means of packaging files for deployment to a device, and are interpreted accordingly by the native software installer. As well as simply containing files, the SIS file can contain conditional statements which influence the installation e.g. device specific installations, language-specific installations, and userselectable optional components. Symbian OS v9.1 delivers new security features to the device, so operations which were previously possible via software install may now no-longer be possible. In addition, the device-side native installer is now policing the installation to ensure that the package meets certain security criteria before installation can succeed. 2 SIS File Format 2.1 Overview The information in the SIS file is split up into two separate parts. The first part is the meta-data, describing the files that need to be installed. The second part of the SIS file contains all the actual file data. This enables software installation to be split into two phases, a decision and an installation phase. During the decision phase, the SIS file is examined and security checks are carried out in order to verify the install. The installation phase is only carried out if the verification is successful and is the process of copying the files to the device. 2.1.1 Note on Reservation of SIS Field Values Please note that Symbian reserves the right to extend the set of applicable values relating to defined SIS fields, for example, fields employing bit-indicators such as TInstallFlags. The generation of unspecified values – outside the context of the supported MakeSIS and/or SignSIS tools is therefore likely to cause compatibility problems with later versions of Symbian OS. This may mean, therefore, that packages will fail to install. 2.2 Integrity The SIS file format supports signatures and certificates to enable a package to be signed. These signatures are verified during installation, and can also be re-verified after the package is installed on the device. In order to support the processing of the SIS file in two phases, only the meta-data of the SIS file is signed. The metadata contains hashes for each file in the package, in order to ensure the integrity of the file data, and therefore the integrity of the entire SIS file is protected by the signed meta-data. This means that during the installation phase software install can verify the hash against the one included in the signed meta-data for each file being installed, whilst using an untrusted component to perform any necessary decompression. Separate checksums for each of the meta-data and the file data are present in the SIS file to enable corrupt SIS files to be detected at the beginning of the installation process. These checksums are optional
symbian 2.3 Extensibility Due to the effort and potential disruption involved in changing file formats,the SIS format is designed to be extensible,and uses a type-length-value (TLV)format.Since each SIsField has a specified length when parsing a SIS file the installer will ignore fields with unknown types. 2.4 Compression The new SIS file format supports the compression of each of the files in the SIS file individually,and the SIscontroller can also be compressed.This reduces the extra space needed to carry out 2.5 Nesting rejecte 2.6 Supporting the re-signing of a SIS file file. Svmbian File Header SISContents SISController SISSignatures SISData 2.7 Programming Considerations 2.7.1 File Format format it is possible to construct a C++class with just the data from the SISField. www.symbian.com
4 2.3 Extensibility Due to the effort and potential disruption involved in changing file formats, the SIS format is designed to be extensible, and uses a type-length-value (TLV) format. Since each SISField has a specified length, when parsing a SIS file the installer will ignore fields with unknown types. 2.4 Compression The new SIS file format supports the compression of each of the files in the SIS file individually, and the SISController can also be compressed. This reduces the extra space needed to carry out installation. Compression is supported by using a SISCompressed SISField which can contain another compressed SISField inside. 2.5 Nesting In order to limit the amount of resource required to install a SIS file package, the installer will now only processes the nesting of SIS files down to a depth of 8. SIS files containing embedding to a greater depth than this will be rejected. 2.6 Supporting the re-signing of a SIS file Since the SIS file format has no offsets which need to be changed it is easy to add a new signature and certificate chains to the end of the meta-data of the SIS file, even though they are in the middle of the file. SISController ….. ….. ….. SISSignatures SISData ….. SISContents ….. Symbian File Header The SISSignatures SISField will be lengthened by the addition of additional signatures and certificate chains, and the SISFields following will be moved to a position further on in the file. 2.7 Programming Considerations 2.7.1 File Format The SIS file format is designed so that each type of SISField is represented by one class. This makes it easy to construct a C++ class instance from a SISField. Since there are no offsets used in the file format it is possible to construct a C++ class with just the data from the SISField
symbian 2.7.2 Memory usage Since a SIS file may be large it is not possible to load everything into memory at once.Due to the ei8e8oiamggisr98samiomionoteahsisF76i1dcambeeadwmotieadn9 2.8 Supporting the embedding of a SIS file The SIS supports the embedding of one SIS file into another.MakeSIS is able to take an already nd mbed it into a SIS file that it is d.anc ntain he files ne led for installation are added the end of the Data Units array of the sIsData sISField.Since the SIscontrollers have a Data Embedding SIS File Resultant SIs File Symbian Header Symbian Header SISController 1 SISController 1 Index-0 SISController 2 SISData 1 Index-0 Index =1 SISData 1 Embedded SIS File Symbian Header SISController 2 Index=0 SISData 2 SISData 2 Figure 1-Embedding a SIS file In the resultant SIS file.to find the absolute index of the SIsFileData in the sIsDataunit,the data indices of each of the chain of SISControllers.from the outermost SISController to the www.symbian.com
5 2.7.2 Memory usage Since a SIS file may be large it is not possible to load everything into memory at once. Due to the structure of the file format, the meta-data information of each SISField can be read without reading all of the data in the contained SISFields. 2.8 Supporting the embedding of a SIS file The SIS supports the embedding of one SIS file into another. MakeSIS is able to take an already generated SIS file and embed it into a SIS file that it is creating. The existing SIS file will be loaded, and the SISController decompressed if necessary and inserted into the Embedded SIS Files field of the SISInstallBlock. The SISDataUnit which contains the files needed for installation are added onto the end of the Data Units array of the SISData SISField. Since the SISControllers have a Data Index field, which indicates the index of the SISDataUnit which contains the files they need, MakeSIS must iterate through the added SISControllers and change these to the correct values. SISController 1 SISData 1 Embedding SIS File SISController 2 SISData 2 Embedded SIS File SISData 1 SISData 2 SISController 1 SISController 2 Resultant SIS File Index = 0 Index = 0 Index = 0 Index = 1 Symbian Header Symbian Header Symbian Header Figure 1 – Embedding a SIS file In the resultant SIS file, to find the absolute index of the SISFileData in the SISDataUnit, the data indices of each of the chain of SISControllers, from the outermost SISController to the