Beispiel #1
0
        protected void Page_Load(object sender, EventArgs e)
        {
            _badPass.Visible = false;
            if (IsPostBack)
            {
                SharedConfig.SharedConfig config = new SharedConfig.SharedConfig();

                Byte[] submittedPassBytes;
                Byte[] encodedBytes;
                MD5    md5;
                string amereSalt = "0ç__è-(''\"'-°\"Bhj5s9867";
                md5 = new MD5CryptoServiceProvider();
                submittedPassBytes = ASCIIEncoding.Default.GetBytes(amereSalt + this._oldpassTextBox.Text);
                encodedBytes       = md5.ComputeHash(submittedPassBytes);
                string hash = BitConverter.ToString(encodedBytes);
                if (hash == config.AdminPwdHash)
                {
                    submittedPassBytes = ASCIIEncoding.Default.GetBytes(amereSalt + this._newPassBisTextBox.Text);
                    encodedBytes       = md5.ComputeHash(submittedPassBytes);
                    hash = BitConverter.ToString(encodedBytes);

                    config.PropertyValues["AdminPwdHash"].PropertyValue    = hash;
                    config.PropertyValues["LastUpdatedDate"].PropertyValue = DateTime.Now;
                    config.PropertyValues["LastUpdatedFrom"].PropertyValue = "Here";
                    config.Save();
                    _badPass.Visible = false;
                    Session.Abandon();
                }
                else
                {
                    _badPass.Visible = true;
                }
            }
        }
Beispiel #2
0
        protected void Page_Load(object sender, EventArgs e)
        {
            _badPass.Visible = false;
            if (IsPostBack)
            {
                SharedConfig.SharedConfig config = new SharedConfig.SharedConfig();
               
                Byte[] submittedPassBytes;
                Byte[] encodedBytes;
                MD5 md5;
                string amereSalt = "0ç__è-(''\"'-°\"Bhj5s9867";
                md5 = new MD5CryptoServiceProvider();
                submittedPassBytes = ASCIIEncoding.Default.GetBytes(amereSalt + this._oldpassTextBox.Text);
                encodedBytes = md5.ComputeHash(submittedPassBytes);
                string hash = BitConverter.ToString(encodedBytes);
                if (hash == config.AdminPwdHash)
                {
                    submittedPassBytes = ASCIIEncoding.Default.GetBytes(amereSalt + this._newPassBisTextBox.Text);
                    encodedBytes = md5.ComputeHash(submittedPassBytes);
                    hash = BitConverter.ToString(encodedBytes);
                    
                    config.PropertyValues["AdminPwdHash"].PropertyValue = hash;
                    config.PropertyValues["LastUpdatedDate"].PropertyValue = DateTime.Now;
                    config.PropertyValues["LastUpdatedFrom"].PropertyValue = "Here";
                    config.Save(); 
                    _badPass.Visible = false;
                    Session.Abandon();
                    
                }
                else
                    _badPass.Visible = true;
            }

        }
Beispiel #3
0
        protected void Page_Load(object sender, EventArgs e)
        {
            if (IsPostBack)
            {
                SharedConfig.SharedConfig config = new SharedConfig.SharedConfig();
                config.PropertyValues["MppsPort"].PropertyValue = _MppsAETTextBox.Text;
                config.PropertyValues["MppsPort"].PropertyValue = Int32.Parse(_MppsListeningPort.Text);
                config.PropertyValues["LastUpdatedDate"].PropertyValue = DateTime.Now;
                config.PropertyValues["LastUpdatedFrom"].PropertyValue = "Here";
                config.Save();
                Label3.Visible = true;
                
            }
            else
                Label3.Visible = false;

        }
Beispiel #4
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (IsPostBack)
     {
         SharedConfig.SharedConfig config = new SharedConfig.SharedConfig();
         config.PropertyValues["MppsPort"].PropertyValue        = _MppsAETTextBox.Text;
         config.PropertyValues["MppsPort"].PropertyValue        = Int32.Parse(_MppsListeningPort.Text);
         config.PropertyValues["LastUpdatedDate"].PropertyValue = DateTime.Now;
         config.PropertyValues["LastUpdatedFrom"].PropertyValue = "Here";
         config.Save();
         Label3.Visible = true;
     }
     else
     {
         Label3.Visible = false;
     }
 }
        protected void Page_Load(object sender, EventArgs e)
        {
            if (IsPostBack)
            {
                SharedConfig.SharedConfig config = new SharedConfig.SharedConfig();
                config.PropertyValues["MwlAETitle"].PropertyValue                = _MwlAETTextBox.Text;
                config.PropertyValues["MwlPort"].PropertyValue                   = Int32.Parse(_MwlListeningPort.Text);
                config.PropertyValues["MWLMaxResponsesToSend"].PropertyValue     = Int32.Parse(_maxResponsesTextBox.Text);
                config.PropertyValues["MWLResponseBufferCapacity"].PropertyValue = Int32.Parse(_bufferCapacityTextBox.Text);
                config.PropertyValues["LastUpdatedDate"].PropertyValue           = DateTime.Now;
                config.PropertyValues["LastUpdatedFrom"].PropertyValue           = "Here";

                config.Save();
                Label3.Visible = true;
            }
            else
            {
                Label3.Visible = false;
            }
        }
Beispiel #6
0
        protected void Page_Load(object sender, EventArgs e)
        {
            if (IsPostBack)
            {
                SharedConfig.SharedConfig config = new SharedConfig.SharedConfig();
                config.PropertyValues["MwlAETitle"].PropertyValue = _MwlAETTextBox.Text;
                config.PropertyValues["MwlPort"].PropertyValue = Int32.Parse(_MwlListeningPort.Text);
                config.PropertyValues["MWLMaxResponsesToSend"].PropertyValue = Int32.Parse(_maxResponsesTextBox.Text);
                config.PropertyValues["MWLResponseBufferCapacity"].PropertyValue = Int32.Parse(_bufferCapacityTextBox.Text);
                config.PropertyValues["LastUpdatedDate"].PropertyValue = DateTime.Now;
                config.PropertyValues["LastUpdatedFrom"].PropertyValue = "Here";
                
                config.Save();
                Label3.Visible = true;

            }
            else
                Label3.Visible = false;


        }