Skip to content

Send notetype so secure notes aren't classified as logins#737

Open
andyexeter wants to merge 1 commit into
lastpass:masterfrom
andyexeter:fix-securenote-notetype
Open

Send notetype so secure notes aren't classified as logins#737
andyexeter wants to merge 1 commit into
lastpass:masterfrom
andyexeter:fix-securenote-notetype

Conversation

@andyexeter

Copy link
Copy Markdown

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) in account_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.

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".
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant