コード例 #1
0
        public void Reset()
        {
            UserName.Value = null;
            Sites.Clear();

            GeneratedPassword.SetValue(string.Empty);
            GeneratedForSite.SetValue(string.Empty);

            // Notify Window to reset the entered passwd
            ResetMasterPassword.SetValue(true);
        }
コード例 #2
0
        private void DoGeneratePassword()
        {
            var selectedEntry = SelectedItem.Value;

            string pw           = new System.Net.NetworkCredential(string.Empty, CurrentMasterPassword.Value).Password;
            var    masterkey    = Algorithm.CalcMasterKey(UserName.Value, pw);
            var    templateSeed = Algorithm.CalcTemplateSeed(masterkey, selectedEntry.SiteName.Value, selectedEntry.Counter.Value);

            GeneratedPassword.SetValue(Algorithm.CalcPassword(templateSeed, selectedEntry.TypeOfPassword.Value));
            GeneratedForSite.SetValue(selectedEntry.SiteName.Value);
        }