PlatformCertificate.Proto.ProtoFiles 2.0.8

dotnet add package PlatformCertificate.Proto.ProtoFiles --version 2.0.8                
NuGet\Install-Package PlatformCertificate.Proto.ProtoFiles -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.ProtoFiles" 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.ProtoFiles --version 2.0.8                
#r "nuget: PlatformCertificate.Proto.ProtoFiles, 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.ProtoFiles as a Cake Addin
#addin nuget:?package=PlatformCertificate.Proto.ProtoFiles&version=2.0.8

// Install PlatformCertificate.Proto.ProtoFiles as a Cake Tool
#tool nuget:?package=PlatformCertificate.Proto.ProtoFiles&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/

There are no supported framework assets in this package.

Learn more about Target Frameworks and .NET Standard.

This package has no dependencies.

NuGet packages (1)

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

Package Downloads
paccor.HardwareManifestPlugin

Package Description

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
2.0.8 155 11/19/2024
2.0.7 305 4/11/2024