Export by cli for Keepass

Hi everyone,

I would like to know if there is a way to export an account to a keepass database by CLI ?

I want to export by cron, in case of security problem, or if passbolt server is inaccessible but we want to have access to some information.

I want to explore all the possibility if there is a problem in our infrastructure :slight_smile:
Thank you !

Hello @Cedric2

I think it will be hard to do. The reason is that to export to Keepass you will need to decrypt the secrets from the Passbolt database before creating a Keepass database file.
But, the thing is that in the Passbolt’s database the secret are encrypted for the users who have access to the secrets with their own public keys. Thus, to decrypt the secrets you will need the user’s private keys to proceed, which you normally don’t have and would brake the security IMO.

However, what I understand from your message is that you could go with a backup on your Passbolt instance. If so, yes, you can do stuffs with cli.

Here’s a help page to proceed with backup if you wish

1 Like

Hi @Steph,

Thank you for your answer. You confirm what I thought but wanted to be sure.

I knew that I could backup the mysql database by cli, but I wanted to explore other possibilities.

I guess we will do this manually from our account.

Thank you again and have a nice day :wink:

Thinking about it (I should have thought out of the box at first).

If it’s for a specific user only you could go maybe with the GO-cli: GitHub - passbolt/go-passbolt-cli: A CLI tool to interact with Passbolt, a Open source Password Manager for Teams
There’s a way to export to Keepass

I took a look and you could actually do that with the go cli (after the client is configured)

passbolt export keepass -p password

It will generate a file passbolt-export.kdbx (the name can be change with the option -f )


Thank you ! I’ll take a look to this and come back to tell you.

Thanks again

1 Like