Exports all attachments from LastPass vault items.
Make sure you run this from a secure location (for example, an encrypted hard drive) as all of your exported attachments will be decrypted and hence, "clear text" readable.
- lastpass-cli (be sure you are already logged in, see Usage below)
- bash
- sed
- awk
- grep
- tr
- log into your LastPass vault via
lpass login <account>
- run ./lpass-att-export.sh -x
- check the
lpass-export
subdirectory for your attachments - log out of your vault (
lpass logout
)
To just get a list of your attachments and their locations, leave off the -x
parameter. Use -v
for verbose logging mode.
- Shared folders return a "Error: Could not find specified account(s)." message (03/07/2021)
- Attachments with spaces in their filename are exported with an incomplete name ending at first space (03/16/2021)
These items are from the lastpass-cli and not this exporter script:
- "Corrupted" (un-decryptable) attachments may return a "Error: Unable to decrypt attachment
<id>-<attid>
" message.- Use
lpass show <id>
to list which vault item contains the corrupted attachment.
- Use