Clipboard history feature security & on disk storage location

I am concerned about the security of the clipboard history feature. Where on disk is the history stored? What I am worried about is whether someone will have access to passwords that I have copied and that would exist in the clipboard history and that those files may be backed up and stored on a disc external to my main machine. I want to make sure that nobody can have access to my plaintext passwords (which I store in a password manager) by looking at the history file that BTT uses to store the clipboard information in. I would like to be able to exclude this particular file from backups. If I happen to use passwords I usually purge the information from the clipboard history but I want to make sure that they are not left on disc anywhere or potentially on backups.
Thank you.

The clipboard data is stored in ~/Library/Application Support/BetterTouchTool/
Specifically in the files named BTTClipboardManager.sqlite*

In general I'd recommend to do only encrypted backups, that works really well with Time Machine.

Thanks for the quick response. So is text in the clipboard is stored in the clear in this file?
When I clear the clipboard managers history on the settings section of clipboard manager does that safely purge the clipboard entry from this sqlite db file?
I want to be able to copy a password into the clipboard, paste it into a webpage and then immediately clear the clipboard manager and be confident that malware etc that may periodically harvest data from the db file will not have access to the clipboard contents. Would you advise this or turning off clipboard manager when using particularly sensitive passwords?
Thanks again.

Malware can access your clipboard without restriction, without you knowing. Thus securing the db would not really make a difference - if an attacker has access to your computer like that.
Are you copying the passwords from a password manager?

Yes, from lastpass browser addon on chrome/firefox. I'm trying to minimise exposure so other than restarting the machine I don't know how to ensure the clipboard contents is only at risk in the clear in memory or on disk for as short a time as possible.

Most password managers add a flag to their clipboard contents so BTT can ignore them.
I don't know about Lastpass though. Could you check whether this setting is disabled?

Yes, it's disabled. ie there is no tick in the box.

And it is still recording the lastpass passwords?

In that case this would be a good feature request for Lastpass ( describes the issue )

I don't think there is anything you can do to make it more secure in BTT.

ok, thank you.
I shall disable the clipboard manager feature of BTT at least when I will be using passwords in the clipboard.

Maybe looking at 1Password could also be a good idea. Personally I like it much better than Lastpass and it does handle the clipboard stuff nicely.