Tpm2Lib.TpmHandle.GetQualifiedName C# (CSharp) Method

GetQualifiedName() public static method

Calculate the qualified name of an object presumed loaded under the provided ancestral chain in a given hierarchy.
public static GetQualifiedName ( TpmHandle hierarchyHandle, TpmPublic children ) : byte[]
hierarchyHandle TpmHandle
children TpmPublic
return byte[]
        public static byte[] GetQualifiedName(TpmHandle hierarchyHandle, TpmPublic[] children)
        {
            byte[] runningName = Marshaller.GetTpmRepresentation(hierarchyHandle);
            foreach (TpmPublic pub in children)
            {
                byte[] thisName = pub.GetName();
                runningName = Globs.Concatenate
                    (
                     Marshaller.GetTpmRepresentation(pub.nameAlg),
                     CryptoLib.HashData(pub.nameAlg, new[] {runningName, thisName})
                    );
            }
            return runningName;
        }