Read Mozilla keyrings from command line

Arian Fm
Dec 9, 2023

--

I was recently working from home and needed a saved password from Firefox on my dev machine at work. Seeing as the only connection I had with the remote machine was through ssh, this meant the only option I had was to retrieve the password through the commandline.

nss-passwords -d <your mozila profile path on the host> <your website url>

Example:

nss-passwords -d ~/snap/firefox/common/.mozila/firefox/ki0kxda2.defualt localhost:3001


result:

| http://localhost:3001 | arian@mailinator.com | oRvr2x^4#w8X@sPd |
| http://localhost:3001 | arianfm@mailinator.com | veryxilu

--

--