Beispiel #1
0
 private string query = "select value from environment where name like '%Whitelist-network'"; ///$$$ Remove to external file
 public NetworkContext() :  base()
 {
     using (var db = new Scamps.DataTools(System.Configuration.ConfigurationManager.ConnectionStrings["SCAMPs"])) //$$$ Hardcoded string!
     {
         db.GetResultSet(query);
         InitConfigKeys(db);
     }
 }
Beispiel #2
0
        protected Regex simpleEndpointRE = new Regex(@".*/$");              //$$$Externalize

        /// <summary>
        /// This is to checks request http context and evaluate if the endpoint allows RSO or
        /// special handling
        /// </summary>
        public EndpointContext() : base()
        {
            //TODO read from DB
            //Select "WhitelistEndpoints" from DB
            string query = "select value from environment where name like '%Whitelist-endpoint'"; //$$$ Remove to external file

            using (var db = new Scamps.DataTools(System.Configuration.ConfigurationManager.ConnectionStrings["SCAMPs"]))
            {
                db.GetResultSet(query);
                //cseed = db.GetValue("select value from environment where name like '%Whitelist-endpoint'").ToString();
                InitConfigKeys(db);
            }
        }