<feed xmlns='http://www.w3.org/2005/Atom'>
<title>Tianocore/edk2.git/SecurityPkg/Include/Library/Tpm2CommandLib.h, branch master</title>
<subtitle>EDK II (mirror)</subtitle>
<id>https://git.radix-linux.su/Tianocore/edk2.git/atom?h=master</id>
<link rel='self' href='https://git.radix-linux.su/Tianocore/edk2.git/atom?h=master'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/'/>
<updated>2026-02-23T21:01:28+00:00</updated>
<entry>
<title>SecurityPkg: Replace include guards with #pragma once</title>
<updated>2026-02-23T21:01:28+00:00</updated>
<author>
<name>Michael Kubacki</name>
<email>michael.kubacki@microsoft.com</email>
</author>
<published>2026-02-03T19:20:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=9326c0eb0a9b5b82fef335e46fbd85868d318a7d'/>
<id>urn:sha1:9326c0eb0a9b5b82fef335e46fbd85868d318a7d</id>
<content type='text'>
Replace traditional `#ifndef`/`#define`/`#endif` include guards with
`#pragma` once.

`#pragma once` is a widely supported preprocessor directive that
prevents header files from being included multiple times. It is
supported by all toolchains used to build edk2: GCC, Clang/LLVM, and
MSVC.

Compared to macro-based include guards, `#pragma once`:

- Eliminates the risk of macro name collisions or copy/paste errors
  where two headers inadvertently use the same guard macro.
- Eliminate inconsistency in the way include guard macros are named
  (e.g., some files use `__FILE_H__`, others use `FILE_H_`, etc.).
- Reduces boilerplate (three lines replaced by one).
- Avoids polluting the macro namespace with guard symbols.
- Can improve build times as the preprocessor can skip re-opening the
  file entirely, rather than re-reading it to find the matching
  `#endif` ("multiple-include optimization").
  - Note that some compilers may already optimize traditional include
    guards, by recognzining the idiomatic pattern.

This change is made acknowledging that overall portability of the
code will technically be reduced, as `#pragma once` is not part of the
C/C++ standards.

However, this is considered acceptable given:

1. edk2 already defines a subset of supported compilers in
   BaseTools/Conf/tools_def.template, all of which have supported
   `#pragma once` for over two decades.
2. There have been concerns raised to the project about inconsistent
   include guard naming and potential macro collisions.

Approximate compiler support dates:

- MSVC: Supported since Visual C++ 4.2 (1996)
- GCC: Supported since 3.4 (2004)
  (http://gnu.ist.utl.pt/software/gcc/gcc-3.4/changes.html)
- Clang (LLVM based): Since initial release in 2007

Signed-off-by: Michael Kubacki &lt;michael.kubacki@microsoft.com&gt;
</content>
</entry>
<entry>
<title>SecurityPkg/Tpm2CommandLib: Add new digest list copy and size functions</title>
<updated>2025-06-13T17:42:43+00:00</updated>
<author>
<name>Michael Kubacki</name>
<email>michael.kubacki@microsoft.com</email>
</author>
<published>2023-11-28T16:31:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=617e061830f6218ef985b599b981bf0ee53ad7da'/>
<id>urn:sha1:617e061830f6218ef985b599b981bf0ee53ad7da</id>
<content type='text'>
REF:https://bugzilla.tianocore.org/show_bug.cgi?id=3267

Adds two new helper functions.

Currently, a function exists in Tpm2CommandLib to copy a digest list
to a buffer. A function to perform the inverse operation - copying
from a buffer to a digest list is added.

A function is also added to compute the total digest size for a given
hash algorithm mask.

Cc: Jiewen Yao &lt;jiewen.yao@intel.com&gt;
Cc: Rahul Kumar &lt;rahul1.kumar@intel.com&gt;
Signed-off-by: Michael Kubacki &lt;michael.kubacki@microsoft.com&gt;
</content>
</entry>
<entry>
<title>SecurityPkg: Add TCG PFP 1.06 support.</title>
<updated>2024-04-30T02:21:13+00:00</updated>
<author>
<name>Wenxing Hou</name>
<email>wenxing.hou@intel.com</email>
</author>
<published>2024-04-18T09:28:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=c3f615a1bd7d64f42e7962f5a4d53f1f1a4423e6'/>
<id>urn:sha1:c3f615a1bd7d64f42e7962f5a4d53f1f1a4423e6</id>
<content type='text'>
Add new api Tpm2ExtendNvIndex.
It is uesd in HashCompleteAndExtend when PcrIndex &gt; MAX_PCR_INDEX.

Cc: Jiewen Yao &lt;jiewen.yao@intel.com&gt;
Cc: Rahul Kumar &lt;rahul1.kumar@intel.com&gt;
Signed-off-by: Wenxing Hou &lt;wenxing.hou@intel.com&gt;
Reviewed-by: Jiewen Yao &lt;jiewen.yao@intel.com&gt;
</content>
</entry>
<entry>
<title>SecurityPkg: Debug code to audit BIOS TPM extend operations</title>
<updated>2021-12-17T15:03:43+00:00</updated>
<author>
<name>Rodrigo Gonzalez del Cueto</name>
<email>rodrigo.gonzalez.del.cueto@intel.com</email>
</author>
<published>2021-12-17T02:47:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=8ed8568922be9b5f7111fc1297317106aba7ab52'/>
<id>urn:sha1:8ed8568922be9b5f7111fc1297317106aba7ab52</id>
<content type='text'>
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2858

In V2: Fixed patch format and uncrustify cleanup

In V1: Add debug functionality to examine TPM extend operations
performed by BIOS and inspect the PCR 00 value prior to
any BIOS measurements.

Signed-off-by: Rodrigo Gonzalez del Cueto &lt;rodrigo.gonzalez.del.cueto@intel.com&gt;
Cc: Jiewen Yao &lt;jiewen.yao@intel.com&gt;
Cc: Jian J Wang &lt;jian.j.wang@intel.com&gt;
Reviewed-by: Jiewen Yao &lt;jiewen.yao@intel.com&gt;
</content>
</entry>
<entry>
<title>SecurityPkg: Apply uncrustify changes</title>
<updated>2021-12-07T17:24:28+00:00</updated>
<author>
<name>Michael Kubacki</name>
<email>michael.kubacki@microsoft.com</email>
</author>
<published>2021-12-05T22:54:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=c411b485b63a671a1e276700cff025c73997233c'/>
<id>urn:sha1:c411b485b63a671a1e276700cff025c73997233c</id>
<content type='text'>
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3737

Apply uncrustify changes to .c/.h files in the SecurityPkg package

Cc: Andrew Fish &lt;afish@apple.com&gt;
Cc: Leif Lindholm &lt;leif@nuviainc.com&gt;
Cc: Michael D Kinney &lt;michael.d.kinney@intel.com&gt;
Signed-off-by: Michael Kubacki &lt;michael.kubacki@microsoft.com&gt;
Reviewed-by: Jian J Wang &lt;jian.j.wang@intel.com&gt;
</content>
</entry>
<entry>
<title>SecurityPkg: Change OPTIONAL keyword usage style</title>
<updated>2021-12-07T17:24:28+00:00</updated>
<author>
<name>Michael D Kinney</name>
<email>michael.d.kinney@intel.com</email>
</author>
<published>2021-12-03T02:00:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=12710fe93bf669540b4dfc783fbcc31db287a5db'/>
<id>urn:sha1:12710fe93bf669540b4dfc783fbcc31db287a5db</id>
<content type='text'>
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3760

Update all use of ', OPTIONAL' to ' OPTIONAL,' for function params.

Cc: Andrew Fish &lt;afish@apple.com&gt;
Cc: Leif Lindholm &lt;leif@nuviainc.com&gt;
Cc: Michael Kubacki &lt;michael.kubacki@microsoft.com&gt;
Signed-off-by: Michael D Kinney &lt;michael.d.kinney@intel.com&gt;
Reviewed-by: Jian J Wang &lt;jian.j.wang@intel.com&gt;
</content>
</entry>
<entry>
<title>SecurityPkg/Tpm2CommandLib: add a new function</title>
<updated>2020-07-28T09:56:25+00:00</updated>
<author>
<name>Zhang, Qi</name>
<email>qi1.zhang@intel.com</email>
</author>
<published>2020-07-28T08:20:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=1b0d659e6dc987d27f63da94c9fe3f26ba171d15'/>
<id>urn:sha1:1b0d659e6dc987d27f63da94c9fe3f26ba171d15</id>
<content type='text'>
 Tpm2GetCapabilityIsCommandImplemented

REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2793

check if the commad is supported by comparing the command code with
command index.

Cc: Jiewen Yao &lt;jiewen.yao@intel.com&gt;
Cc: Jian J Wang &lt;jian.j.wang@intel.com&gt;
Cc: Chao Zhang &lt;chao.b.zhang@intel.com&gt;
Cc: Rahul Kumar &lt;rahul1.kumar@intel.com&gt;
Signed-off-by: Qi Zhang &lt;qi1.zhang@intel.com&gt;
Reviewed-by: Jiewen Yao &lt;jiewen.yao@intel.com&gt;
</content>
</entry>
<entry>
<title>SecurityPkg: Fix spelling errors</title>
<updated>2019-10-23T17:23:23+00:00</updated>
<author>
<name>Sean Brogan</name>
<email>sean.brogan@microsoft.com</email>
</author>
<published>2019-10-09T07:20:15+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=d6b926e76e3d639ac37610e97d33ff9e3a6281eb'/>
<id>urn:sha1:d6b926e76e3d639ac37610e97d33ff9e3a6281eb</id>
<content type='text'>
https://bugzilla.tianocore.org/show_bug.cgi?id=2265

Cc: Jiewen Yao &lt;jiewen.yao@intel.com&gt;
Cc: Jian J Wang &lt;jian.j.wang@intel.com&gt;
Cc: Chao Zhang &lt;chao.b.zhang@intel.com&gt;
Signed-off-by: Michael D Kinney &lt;michael.d.kinney@intel.com&gt;
Reviewed-by: Jiewen Yao &lt;Jiewen.yao@intel.com&gt;
Reviewed-by: Jian J Wang &lt;jian.j.wang@intel.com&gt;
</content>
</entry>
<entry>
<title>SecurityPkg: Replace BSD License with BSD+Patent License</title>
<updated>2019-04-09T17:58:23+00:00</updated>
<author>
<name>Michael D Kinney</name>
<email>michael.d.kinney@intel.com</email>
</author>
<published>2019-04-03T23:06:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=289b714b77008aa4200c0be25c4b4e25df04955a'/>
<id>urn:sha1:289b714b77008aa4200c0be25c4b4e25df04955a</id>
<content type='text'>
https://bugzilla.tianocore.org/show_bug.cgi?id=1373

Replace BSD 2-Clause License with BSD+Patent License.  This change is
based on the following emails:

  https://lists.01.org/pipermail/edk2-devel/2019-February/036260.html
  https://lists.01.org/pipermail/edk2-devel/2018-October/030385.html

RFCs with detailed process for the license change:

  V3: https://lists.01.org/pipermail/edk2-devel/2019-March/038116.html
  V2: https://lists.01.org/pipermail/edk2-devel/2019-March/037669.html
  V1: https://lists.01.org/pipermail/edk2-devel/2019-March/037500.html

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Michael D Kinney &lt;michael.d.kinney@intel.com&gt;
Reviewed-by: Jiewen Yao &lt;Jiewen.yao@intel.com&gt;
Reviewed-by: Jian J Wang &lt;jian.j.wang@intel.com&gt;
</content>
</entry>
<entry>
<title>SecurityPkg: Clean up source files</title>
<updated>2018-06-28T03:19:50+00:00</updated>
<author>
<name>Liming Gao</name>
<email>liming.gao@intel.com</email>
</author>
<published>2018-06-27T13:13:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=b3548d32ddb553a9e95503457c66d11462622d16'/>
<id>urn:sha1:b3548d32ddb553a9e95503457c66d11462622d16</id>
<content type='text'>
1. Do not use tab characters
2. No trailing white space in one line
3. All files must end with CRLF

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Liming Gao &lt;liming.gao@intel.com&gt;
</content>
</entry>
</feed>
