{"id":13478896,"url":"https://github.com/unode/firefox_decrypt","last_synced_at":"2025-10-05T20:54:58.601Z","repository":{"id":13313686,"uuid":"16000225","full_name":"unode/firefox_decrypt","owner":"unode","description":"Firefox Decrypt is a tool to extract passwords from Mozilla (Firefox™, Waterfox™, Thunderbird®, SeaMonkey®) profiles","archived":false,"fork":false,"pushed_at":"2024-11-08T13:52:34.000Z","size":521,"stargazers_count":2199,"open_issues_count":2,"forks_count":320,"subscribers_count":49,"default_branch":"main","last_synced_at":"2025-05-21T12:12:55.547Z","etag":null,"topics":["command-line-tool","extract-passwords","firefox","firefox-decrypt","libnss3","mozilla","python","seamonkey","thunderbird","waterfox"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/unode.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2014-01-17T13:25:02.000Z","updated_at":"2025-05-19T23:52:46.000Z","dependencies_parsed_at":"2023-12-23T20:19:59.615Z","dependency_job_id":"93234d3a-6c13-4703-8f7a-e0d5f8a3498e","html_url":"https://github.com/unode/firefox_decrypt","commit_stats":null,"previous_names":[],"tags_count":19,"template":false,"template_full_name":null,"purl":"pkg:github/unode/firefox_decrypt","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/unode%2Ffirefox_decrypt","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/unode%2Ffirefox_decrypt/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/unode%2Ffirefox_decrypt/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/unode%2Ffirefox_decrypt/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/unode","download_url":"https://codeload.github.com/unode/firefox_decrypt/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/unode%2Ffirefox_decrypt/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278518905,"owners_count":26000177,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-05T02:00:06.059Z","response_time":54,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["command-line-tool","extract-passwords","firefox","firefox-decrypt","libnss3","mozilla","python","seamonkey","thunderbird","waterfox"],"created_at":"2024-07-31T16:02:05.394Z","updated_at":"2025-10-05T20:54:58.572Z","avatar_url":"https://github.com/unode.png","language":"Python","readme":"### Firefox Decrypt\n\n![GitHub Actions status](https://github.com/unode/firefox_decrypt/actions/workflows/main.yml/badge.svg)\n[![Gitmoji badge](https://img.shields.io/badge/gitmoji-%20😜%20😍-FFDD67.svg?style=flat-square)](https://gitmoji.dev)\n\nAs of 1.0.0 Python 3.9+ is required. Python 2 is no longer supported.\nIf you encounter a problem, try the latest [release](https://github.com/unode/firefox_decrypt/releases) or check open issues for ongoing work.\n\nIf you definitely need to use Python 2, [Firefox Decrypt 0.7.0](https://github.com/unode/firefox_decrypt/releases/tag/0.7.0) is your best bet, although no longer supported.\n\n### Table of contents \n\n* [About](#about)\n* [Usage](#usage)\n    * [Advanced Usage](#advanced-usage)\n    * [Non-Interactive mode](#non-interactive-mode)\n* Ouput formats\n    * [CSV/Tabular](#format-csv)\n    * [Pass - Password Store](#format-pass---passwordstore)\n* [Troubleshooting](#troubleshooting)\n    * [Windows](#windows)\n    * [MacOSX](#macosdarwin)\n* [Testing](#testing)\n* [Derived works](#spin-off-derived-and-related-works)\n\n#### About\n\n**Firefox Decrypt** is a tool to extract passwords from profiles of Mozilla (Fire/Water)fox™, Thunderbird®, SeaMonkey® and derivates.\n\nIt can be used to recover passwords from a profile protected by a Master Password as long as the latter is known.\nIf a profile is not protected by a Master Password, passwords are displayed without prompt.\n\nThis tool does not try to crack or brute-force the Master Password in any way.\nIf the Master Password is not known it will simply fail to recover any data.\n\nIt requires access to libnss3, included with most Mozilla products.\nThe script is usually able to find a compatible library but may in some cases\nload an incorrect/incompatible version. If you encounter this situation please file a bug report.\n\nAlternatively, you can install libnss3 (Debian/Ubuntu) or nss (Arch/Gentoo/…).\nlibnss3 is part of https://developer.mozilla.org/docs/Mozilla/Projects/NSS\n\nIf you need to decode passwords from Firefox 3 or older, although not officially supported,\nthere is a patch in [this pull request](https://github.com/unode/firefox_decrypt/pull/36).\n\n\n#### Usage\n\nRun:\n\n```\npython firefox_decrypt.py\n```\n\nThe tool will present a numbered list of profiles. Enter the relevant number. \n\nThen, a prompt to enter the *master password* for the profile: \n\n- if no password was set, no master password will be asked.\n- if a password was set and is known, enter it and hit key \u003ckbd\u003eReturn\u003c/kbd\u003e or \u003ckbd\u003eEnter\u003c/kbd\u003e\n- if a password was set and is no longer known, you can not proceed\n\n#### Advanced usage\n\nIf your profiles are at an unusual path, you can call the script with:\n\n```\npython firefox_decrypt.py /folder/containing/profiles.ini/\n```\n\nIf you don't want to display all passwords on the screen you can use:\n\n```\npython firefox_decrypt.py | grep -C2 keyword\n```\nwhere `keyword` is part of the expected output (URL, username, email, password …)\n\nYou can also choose from one of the supported formats with `--format`:\n\n* `human` - a format displaying one record for every 3 lines\n* `csv` - a spreadsheet-like format. See also `--csv-*` options for additional control.\n* `tabular` - similar to csv but producing a tab-delimited (`tsv`) file instead.\n* `json` - a machine compatible format - see [JSON](https://en.wikipedia.org/wiki/JSON)\n* `pass` - a special output format that directly calls to the [passwordstore.org](https://www.passwordstore.org) command to export passwords (*). See also `--pass-*` options.\n\n(*) `pass` can produce unintended consequences. Make sure to backup your password store before using this option.\n\n##### Specify NSS library location\n\nIn order to decode your passwords, Firefox Decrypt uses a series of heuristics to try to locate a compatible [NSS library](https://developer.mozilla.org/docs/Mozilla/Projects/NSS) on your system.\nAs this approach can sometimes fail, starting with version 1.1.1 of Firefox Decrypt you can now define the `NSS_LIB_PATH` environment variable to manually specify the location of the library.\nThis location will be prioritized and if no compatible library is found, the script will continue with the built-in heuristics.\n\n```\n# On Linux it will look for libnss3.so in /opt/nss/lib/\n# On Mac it will look for libnss3.dylib\nNSS_LIB_PATH=/opt/nss/lib/ python firefox_decrypt.py\n\n# On Windows it will look for nss3.dll\nset NSS_LIB_PATH=D:\\NSS\\lib\\ \u0026\u0026 python firefox_decrypt.py\n```\n\nYou can confirm if this was successful by running the script in high-verbosity mode (`-vv`) and look for the `Loaded NSS` message after `Loading NSS`:\n\n```\n(...) DEBUG - Loading NSS library from /opt/nss/lib/libnss3.so\n(...) DEBUG - Loaded NSS library from /opt/nss/lib/libnss3.so\n```\n\n##### Non-interactive mode\n\nA non-interactive mode which bypasses all prompts, including profile choice and master password, can be enabled with `-n/--no-interactive`.\nIf you have multiple Mozilla profiles, make sure to also indicate your profile choice by passing `-c/--choice N` where N is the number of the profile you wish to decrypt (starting from **1**).\n\nYou can list all available profiles with `-l/--list` (to stdout).\n\nYour master password is read from stdin.\n\n    $ python firefox_decrypt.py --list\n    1 -\u003e l1u1xh65.default\n    2 -\u003e vuhdnx5b.YouTube\n    3 -\u003e 1d8vcool.newdefault\n    4 -\u003e ekof2ces.SEdu\n    5 -\u003e 8a52xmtt.Fresh\n\n    $ read -sp \"Master Password: \" PASSWORD\n    Master Password:\n\n    $ echo $PASSWORD | python firefox_decrypt.py --no-interactive --choice 4\n    Website:   https://login.example.com\n    Username: 'john.doe'\n    Password: '1n53cur3'\n\n    Website:   https://example.org\n    Username: 'max.mustermann'\n    Password: 'Passwort1234'\n\n    Website:   https://github.com\n    Username: 'octocat'\n    Password: 'qJZo6FduRcHw'\n\n    [...snip...]\n\n    $ echo $PASSWORD | python firefox_decrypt.py -nc 1\n    Website:   https://git-scm.com\n    Username: 'foo'\n    Password: 'bar'\n\n    Website:   https://gitlab.com\n    Username: 'whatdoesthefoxsay'\n    Password: 'w00fw00f'\n\n    [...snip...]\n\n    $ # Unset Password\n    $ PASSWORD=\n\n##### Format CSV\n\nPasswords may be exported in CSV format using the `--format` flag.\n\n```\npython firefox_decrypt.py --format csv\n```\n\nAdditionally, `--csv-delimiter` and `--csv-quotechar` flags can specify which characters to use as delimiters and quote characters in the CSV output.\n\n##### Format Pass - Passwordstore\n\nStored passwords can be exported to [`pass`](http://passwordstore.org) (from passwordstore.org) using:\n\n```\npython firefox_decrypt.py --format pass\n```\n\n**All** existing passwords will be exported after the pattern `web/\u003caddress\u003e[:\u003cport\u003e]`.\nIf multiple credentials exist for the same website `/\u003clogin\u003e` is appended.\nBy `pass` convention, the password will be on the first and the username on the second line.\n\nTo prefix the username with `login: ` for compatibility with the [browserpass](https://github.com/dannyvankooten/browserpass) extension, you can use:\n```\npython firefox_decrypt.py --format pass --pass-username-prefix 'login: '\n```\n\nThere is currently no way to selectively export passwords.\n\nExporting will overwrite existing passwords without warning. Ensure you have a backup or are using the `pass git` functionality.\n\n##### Non fatal password decryption\n\nBy default, encountering a corrupted username or password will abort decryption.\nSince version `1.1.0` there is now `--non-fatal-decryption` that tolerates individual failures.\n\n    $ python firefox_decrypt.py --non-fatal-decryption\n    (...)\n    Website:   https://github.com\n    Username: '*** decryption failed ***'\n    Password: '*** decryption failed ***'\n\nwhich can also be combined with any of the above `--format` options.\n\n#### Troubleshooting\n\nIf a problem occurs, please try `firefox_decrypt` in high verbosity mode by calling it with:\n\n```\npython firefox_decrypt.py -vvv\n```\n\nIf the output does not help you to identify the cause and a solution to the problem, file a bug report including the verbose output. **Beware**:  \n\n- your profile password, as well as other passwords, may be visible in the output – so **please remove any sensitive data** before sharing the output.\n\n##### Silencing error messages\n\nLogging messages above warning level are included in the standard error output by default as these can be useful to troubleshoot failures.\nIf you wish to omit this information append ` 2\u003e/dev/null` to your command on UNIX and ` 2\u003e nul` on Windows.\n\n##### Windows\n\nBoth Python and Firefox must be either 32-bit or 64-bit.  \n\nIf you mix architectures the code will fail. More information on issue [#8](https://github.com/unode/firefox_decrypt/issues/8).\n\n`cmd.exe` is not supported due to it's poor UTF-8 support.\nUse [Microsoft Terminal](https://github.com/microsoft/terminal) and install [UTF-8 compatible fonts](https://www.google.com/get/noto/).\nDepending on the Terminal settings, the Windows version and the language of your system,\nyou may also need to force Python to run in `UTF-8` mode with `PYTHONUTF8=1 python firefox_decrypt.py`.\n\n\n##### MacOS/Darwin\n\nIf you get the error described in [#14](https://github.com/unode/firefox_decrypt/issues/14) when loading `libnss3`, consider installing `nss` using [Homebrew](https://brew.sh/) or an alternative package manager.\n\nWhile not supported, you may find that `DYLD_LIBRARY_PATH=. python3 firefox_decrypt.py` will work in some configurations.\n\n\n#### Testing\n\nIf you wish to run the test suite locally, chdir into `tests/` and run `./run_all`\n\nIf any test fails on your system, please ensure `libnss` is installed.\n\nIf tests continue to fail, re-run with `./run_all -v` then please file a bug report including: \n\n- the output\n- information about your system (e.g. Linux distribution, version of libnss/firefox …). \n\nIt is much appreciated.\n\n### Contributors\n\n\u003c!-- ALL-CONTRIBUTORS-BADGE:START - Do not remove or modify this section --\u003e\n[![All Contributors](https://img.shields.io/github/all-contributors/unode/firefox_decrypt?color=ee8449\u0026style=flat-square)](CONTRIBUTORS.md#contributors)\n\u003c!-- ALL-CONTRIBUTORS-BADGE:END --\u003e\n\nSee [CONTRIBUTORS.md](CONTRIBUTORS.md) for a complete list of contributions\n\n### Spin-off, derived and related works\n\n* [firepwned](https://github.com/christophetd/firepwned#how-it-works) - check if your passwords have been involved in a known data leak\n* [FF Password Exporter](https://github.com/kspearrin/ff-password-exporter) - Firefox AddOn for exporting passwords. \n\n----\n\nFirefox is a trademark of the Mozilla Foundation in the U.S. and other countries.\n","funding_links":[],"categories":["Python","\u003ca id=\"c49aef477cf3397f97f8b72185c3d100\"\u003e\u003c/a\u003e密码\u0026\u0026凭证","firefox","\u003ca id=\"862af330f45f21fbb0d495837fc7e879\"\u003e\u003c/a\u003e工具","逆向破解"],"sub_categories":["\u003ca id=\"20bf2e2fefd6de7aadbf0774f4921824\"\u003e\u003c/a\u003e未分类-Password"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Funode%2Ffirefox_decrypt","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Funode%2Ffirefox_decrypt","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Funode%2Ffirefox_decrypt/lists"}