TCG Published
Total Page:16
File Type:pdf, Size:1020Kb
TSS System Level API and TPM Command Transmission Interface Specification Family "2.0" Level 00, Revision 01.00 26 January 2015 Contact: [email protected] TCG Published TCG Copyright © TCG 2013 - 2015 Family "2.0" TSS System Level API and TCTI Specification Disclaimers, Notices, and License Terms THIS SPECIFICATION IS PROVIDED "AS IS" WITH NO WARRANTIES WHATSOEVER, INCLUDING ANY WARRANTY OF MERCHANTABILITY, NONINFRINGEMENT, FITNESS FOR ANY PARTICULAR PURPOSE, OR ANY WARRANTY OTHERWISE ARISING OUT OF ANY PROPOSAL, SPECIFICATION OR SAMPLE. Without limitation, TCG disclaims all liability, including liability for infringement of any proprietary rights, relating to use of information in this specification and to the implementation of this specification, and TCG disclaims all liability for cost of procurement of substitute goods or services, lost profits, loss of use, loss of data or any incidental, consequential, direct, indirect, or special damages, whether under contract, tort, warranty or otherwise, arising in any way out of use or reliance upon this specification or any information herein. This document is copyrighted by Trusted Computing Group (TCG), and no license, express or implied, is granted herein other than as follows: You may not copy or reproduce the document or distribute it to others without written permission from TCG, except that you may freely do so for the purposes of (a) examining or implementing TCG specifications or (b) developing, testing, or promoting information technology standards and best practices, so long as you distribute the document with these disclaimers, notices, and license terms. Contact the Trusted Computing Group at www.trustedcomputinggroup.org for information on specification licensing through membership agreements. Any marks and brands contained herein are the property of their respective owners. Family "2.0" TCG Published Page 1 Level 00, Revision 01.00 Copyright © 2013-2015 26 January 2015 TSS System Level API and TCTI Specification Family "2.0" CONTENTS TCG Published ............................................................................................................................................... i CONTENTS................................................................................................................................................... 2 FIGURES ...................................................................................................................................................... 4 1 Introduction ............................................................................................................................................ 5 1.1 TSS Overview ................................................................................................................................. 5 1.2 SAPI and TCTI Target Systems ..................................................................................................... 7 2 Definition of Terms ................................................................................................................................ 8 3 Architecture ........................................................................................................................................... 9 4 Acronyms............................................................................................................................................. 10 5 Overall Design Requirements ............................................................................................................. 11 5.1 Threading Model ........................................................................................................................... 11 6 Common Data Structures .................................................................................................................... 13 6.1.1 Application Binary Interface (ABI) Negotiation ..................................................................... 13 6.1.2 Error Codes .......................................................................................................................... 14 7 TPM Command Transmission Interface .............................................................................................. 17 7.1 Intro ............................................................................................................................................... 17 7.1.1 Purpose & Goal .................................................................................................................... 17 7.2 TCTI data structures ..................................................................................................................... 17 7.3 TCTI Context data structures ........................................................................................................ 18 7.3.1 TCTI Context ........................................................................................................................ 18 7.3.2 Function Invocation .............................................................................................................. 18 7.3.3 Non-opaque Area ................................................................................................................. 19 7.4 Compatibility ................................................................................................................................. 22 7.4.1 Old and Not Useful Version .................................................................................................. 23 7.4.2 New but Useful Version ........................................................................................................ 23 7.4.3 New and Not Useful Version ................................................................................................ 23 7.4.4 New Version with Deprecated Functions ............................................................................. 23 7.5 Opaque Area................................................................................................................................. 23 8 SAPI .................................................................................................................................................... 24 8.1 Overall functionality ...................................................................................................................... 24 8.2 Design requirements ..................................................................................................................... 24 8.3 Design rules .................................................................................................................................. 25 8.4 Architecture ................................................................................................................................... 26 8.5 SAPI data structures ..................................................................................................................... 28 8.5.1 Part 2 Data Types ................................................................................................................ 28 8.5.2 sysContext structure ............................................................................................................. 29 8.5.3 Command and response session structures ........................................................................ 29 8.6 Command Parameters .................................................................................................................. 30 Page 2 TCG Published Family "2.0" 26 January 2015 Copyright © 2013-2015 Level 00, Revision 01.00 Family "2.0" TSS System Level API and TCTI Specification 8.6.1 System API Parameter Rules .............................................................................................. 30 8.7 SAPI Function APIs (by Category) ............................................................................................... 30 8.7.1 Command Context Allocation Functions .............................................................................. 31 8.7.2 Command Preparation Functions ........................................................................................ 33 8.7.3 Command Execution Functions ........................................................................................... 36 8.7.4 Command Completion .......................................................................................................... 40 9 Appendices .......................................................................................................................................... 46 9.1 SAPI ABI Negotiation Pseudo Code ............................................................................................. 46 Family "2.0" TCG Published Page 3 Level 00, Revision 01.00 Copyright © 2013-2015 26 January 2015 TSS System Level API and TCTI Specification Family "2.0" FIGURES Figure 1 — Example Implementation Architectures ..................................................................................... 6 Figure 2 — TSS Stack .................................................................................................................................. 7 Figure 3 — Low level stack details ............................................................................................................. 28 Page 4 TCG Published Family "2.0" 26 January 2015 Copyright © 2013-2015 Level 00, Revision 01.00 Family "2.0" TSS System Level API and TCTI Specification 1 Introduction The scope of this document is to describe all the software