Cannot delete credential after manual change email from Credential Manager Windows
tiennguyen15 opened this issue · comments
Prerequisites
- Put an X between the brackets on this line if you have done all of the following:
- Reproduced the problem in Safe Mode: https://flight-manual.atom.io/hacking-atom/sections/debugging/#using-safe-mode
- Followed all applicable steps in the debugging guide: https://flight-manual.atom.io/hacking-atom/sections/debugging/
- Checked the FAQs on the message board for common solutions: https://discuss.atom.io/c/faq
- Checked that your issue isn't already filed: https://github.com/issues?utf8=✓&q=is%3Aissue+user%3Aatom
- Checked that there is not already an Atom package that provides the described functionality: https://atom.io/packages
Description
Steps to Reproduce
- Create A new Credential from node-keytar, Check from Credential Manger. We will see the format:
- Internet or network address: DesktopApp/tiennguyen15@gmail.com
- username: tiennguyen15@gmail.com
- password: *****
- Open Credential Manager - click edit change email to tiennguyen151@gmail.com. You will see
- Internet or network address: DesktopApp/tiennguyen15@gmail.com
- username: tiennguyen151@gmail.com
- password: *****
- When we find credential from keytar.findCredentials( 'DesktopApp') -> it returns
[ {account:tiennguyen15@gmail.com, password:****} ]
- But when we use keytar.deletePassword( 'DesktopApp') will not work. As I can see the source (keytar_win.cc) that the deletePassword, will combine service and account
KEYTAR_OP_RESULT DeletePassword(const std::string& service, const std::string& account, std::string* errStr) { LPWSTR target_name = utf8ToWideChar(service + '/' + account);
Expected behavior:
keytar.deletePassword can delete without combine service and account
Actual behavior:
keytar.deletePassword cannot delete
Reproduces how often:
100%
Versions
keytar: 7.7.0
Windows OS: 10
Electron Version 13.1.1
Additional Information
I think we should have another option from the delete like a force to delete with combination service/account or only service only