PlatformCertificate.Proto 2.0.8

dotnet add package PlatformCertificate.Proto --version 2.0.8                
NuGet\Install-Package PlatformCertificate.Proto -Version 2.0.8                
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="PlatformCertificate.Proto" Version="2.0.8" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add PlatformCertificate.Proto --version 2.0.8                
#r "nuget: PlatformCertificate.Proto, 2.0.8"                
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install PlatformCertificate.Proto as a Cake Addin
#addin nuget:?package=PlatformCertificate.Proto&version=2.0.8

// Install PlatformCertificate.Proto as a Cake Tool
#tool nuget:?package=PlatformCertificate.Proto&version=2.0.8                

This lightweight library attempts to capture sequences from the TCG Platform Certificate 2.0 Information Model into Google's Protobuf format. Those protobuf messages are compiled as C# Objects and made available by referencing this package in a project.

The library is available via Nuget https://www.nuget.org/packages/PlatformCertificate.Proto for inclusion into .NET projects.

The proto source files are available on GitHub and can be compiled into any language supported by Protobuf.

They are also available in a follow-on Nuget package: https://www.nuget.org/packages/PlatformCertificate.Proto.ProtoFiles. This ProtoFiles package will allow others to import the original protobuf files into subsequent projects.

Usage

Reference this library in your .NET project. Then you can use the objects.

using PlatformCertificateFromProto;

namespace YourNamespace {
    public class YourClass {
	    public void YourMethod {
			ComponentIdentifierTrait trait = new();
			...
			trait.ToString();  // Each object can be serialized to JSON
		}
	}
}

Read information from a JSON file:

using PlatformCertificateFromProto;

namespace YourNamespace {
    public class YourClass {
	    public void YourMethod {
			string json = File.ReadAllText(PLATFORMATTRIBUTECERTIFICATE_A1_TRAITS_PATH);
			PlatformAttributeCertificate result = PlatformAttributeCertificate.Parser.WithDiscardUnknownFields(true).ParseJson(json);
			...
		}
	}
}

Oids.proto is a reference for many Oids, and the full OID can be queried and returned as a string.

using OidsProto;
using PlatformCertificateFromProto;

namespace YourNamespace {
    public class YourClass {
	    public void YourMethod {
			ObjectIdentifier oid = OidsUtils.Find(TCG_TR_ID_NODE.TcgTrIdBoolean); // oid.Oid = 2.23.133.19.1.1
		}
	}
}
Compile

The .NET project should compile the C# files from the proto files on every build and pack them into a nuget package.

https://trustedcomputinggroup.org/resource/tcg-platform-certificate-profile/

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (2)

Showing the top 2 NuGet packages that depend on PlatformCertificate.Proto:

Package Downloads
paccor.paccor_scripts

Package Description

paccor.HardwareManifestPlugin

Package Description

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
2.0.8 73 11/19/2024
2.0.3 234 4/11/2024
1.0.0 3,143 6/2/2022