Microsoft.Xades.XadesSignedXml.CheckHashDataInfosForTimeStamp C# (CSharp) Method

CheckHashDataInfosForTimeStamp() private method

private CheckHashDataInfosForTimeStamp ( TimeStamp timeStamp ) : bool
timeStamp TimeStamp
return bool
        private bool CheckHashDataInfosForTimeStamp(TimeStamp timeStamp)
        {
            bool retVal = true;

            for (int referenceCounter = 0; retVal == true && (referenceCounter < this.SignedInfo.References.Count); referenceCounter++)
            {
                string referenceId = ((Reference) this.SignedInfo.References[referenceCounter]).Id;
                string referenceUri = ((Reference) this.SignedInfo.References[referenceCounter]).Uri;
                if (referenceUri != ("#" + this.XadesObject.QualifyingProperties.SignedProperties.Id))
                {
                    bool hashDataInfoFound = false;
                    for (int hashDataInfoCounter = 0; hashDataInfoFound == false && (hashDataInfoCounter < timeStamp.HashDataInfoCollection.Count); hashDataInfoCounter++)
                    {
                        HashDataInfo hashDataInfo = timeStamp.HashDataInfoCollection[hashDataInfoCounter];
                        hashDataInfoFound = (("#" + referenceId) == hashDataInfo.UriAttribute);
                    }
                    retVal = hashDataInfoFound;
                }
            }

            return retVal;
        }