Send notetype so secure notes aren't classified as logins#737
Open
andyexeter wants to merge 1 commit into
Open
Send notetype so secure notes aren't classified as logins#737andyexeter wants to merge 1 commit into
andyexeter wants to merge 1 commit into
Conversation
The redesigned LastPass web vault decides whether an item is a secure note from a plaintext "notetype" param, not the legacy url=http://sn marker. lpass never sends it, so notes created or edited via the CLI show up as password/login items in the web vault. Capture the notetype the server already sends (previously discarded in the account parser) and echo it back unchanged on update, so existing structured notes keep their type. New secure notes that have none default to "Generic".
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The redesigned LastPass web vault (vault.lastpass.com) decides whether an item is a Secure Note from a plaintext notetype form field, not the legacy url=http://sn marker that lpass relies on.
lastpass_update_account()never sends notetype, so any secure note created or edited with the CLI shows up as a password/login item in the web vault (with http://sn displayed as a URL), even though it's otherwise byte-for-byte identical to a working secure note.lpass already receives notetype from the server when reading the blob but discards it (
skip(notetype)inaccount_parse()).This change captures it onto the account and echoes it back unchanged on update, so existing structured notes (SSH Key, Database etc.) keep their type when edited. New secure notes that have no type yet default to Generic.