internal static bool IsMessageUsingWSSecurity(UnderstoodHeaders understoodHeaders) { foreach (MessageHeaderInfo headerInfo in understoodHeaders) { if (string.Equals(headerInfo.Namespace, "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd", StringComparison.Ordinal) || //wsu string.Equals(headerInfo.Namespace, "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd", StringComparison.Ordinal) || //wsse string.Equals(headerInfo.Namespace, "http://docs.oasis-open.org/wss/oasis-wss-wsecurity-secext-1.1.xsd", StringComparison.Ordinal)) //wsse11 { return true; } } return false; }
static HashSet<string> CreateKeys(UnderstoodHeaders headers) { HashSet<string> toReturn = new HashSet<string>(); foreach (MessageHeaderInfo header in headers) { toReturn.Add(MessageHeaderKey(header)); } return toReturn; }