internal bool CheckValueForKeyPermit(DBConnectionString parsetable)
        {
            if (null == parsetable)
            {
                return(false);
            }

            bool hasMatch = false;

            NameValuePermission[] keytree = _tree; // _tree won't mutate but Add will replace it
            if (null != keytree)
            {
                hasMatch = parsetable.IsEmpty(); // MDAC 86773

                // which key do we follow the key-value chain on
                for (int i = 0; i < keytree.Length; ++i)
                {
                    NameValuePermission permitKey = keytree[i];
                    string keyword = permitKey._value;
#if DATAPERMIT
                    Debug.WriteLine("DBDataPermission keyword: <" + keyword + ">");
#endif
#if DEBUG
                    Debug.Assert(null == permitKey._entry, "key member has no restrictions");
#endif
                    if (parsetable.Contains(keyword))
                    {
                        string valueInQuestion = (string)parsetable[keyword];

                        // keyword is restricted to certain values
                        NameValuePermission permitValue = permitKey.CheckKeyForValue(valueInQuestion);
                        if (null != permitValue)
                        {
                            //value does match - continue the chain down that branch
                            if (permitValue.CheckValueForKeyPermit(parsetable))
                            {
                                hasMatch = true;
                            }
                            else
                            {
#if DATAPERMIT
                                Debug.WriteLine("DBDataPermission failed branch checking");
#endif
                                return(false);
                            }
                        }
                        else   // value doesn't match to expected values - fail here
                        {
#if DATAPERMIT
                            Debug.WriteLine("DBDataPermission failed to match expected value");
#endif
                            return(false);
                        }
                    }
                    // else try next keyword
                }
                // partial chain match, either leaf-node by shorter chain or fail mid-chain if (null == _restrictions)
            }
#if DATAPERMIT
            else
            {
                Debug.WriteLine("leaf node");
            }
#endif
            DBConnectionString entry = _entry;
            if (null != entry)
            {
                return(entry.IsSubsetOf(parsetable));
            }
#if DATAPERMIT
            Debug.WriteLine("DBDataPermission failed on non-terminal node");
#endif
            return(hasMatch); // mid-chain failure
        }