{"id":20064154,"url":"https://github.com/nyxnor/onionwash","last_synced_at":"2025-09-03T10:40:09.722Z","repository":{"id":135524902,"uuid":"450662029","full_name":"nyxnor/onionwash","owner":"nyxnor","description":"Parse tor configuration files and edit the torrc in a safe manner","archived":false,"fork":false,"pushed_at":"2022-06-16T09:42:04.000Z","size":68,"stargazers_count":4,"open_issues_count":2,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-05-05T17:33:31.464Z","etag":null,"topics":["configuration","open-source","security","tor","torrc"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nyxnor.png","metadata":{"files":{"readme":"README.md","changelog":"changelog.upstream","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":"2022-01-21T22:50:42.000Z","updated_at":"2022-05-31T22:11:54.000Z","dependencies_parsed_at":null,"dependency_job_id":"54e79591-1e7e-4652-95d9-a110de112250","html_url":"https://github.com/nyxnor/onionwash","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/nyxnor/onionwash","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nyxnor%2Fonionwash","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nyxnor%2Fonionwash/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nyxnor%2Fonionwash/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nyxnor%2Fonionwash/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nyxnor","download_url":"https://codeload.github.com/nyxnor/onionwash/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nyxnor%2Fonionwash/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":273431344,"owners_count":25104491,"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-09-03T02:00:09.631Z","response_time":76,"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":["configuration","open-source","security","tor","torrc"],"created_at":"2024-11-13T13:45:04.530Z","updated_at":"2025-09-03T10:40:09.656Z","avatar_url":"https://github.com/nyxnor.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# OnionWash - sanitize tor configuration files\n\nIf you don't clean your onions, you might only see half of a worm after a bite.\n\n## onion-parser - parse tor configuration files elegantly\n\nWrapper aroung tor option `--verify config` to parse configuration files and verify if they are valid.\n\nAlso shows the order the files were parsed and their options if being verbose.\n\n## vitor - safely edit tor configuration files\n\nVitor is a Vi for tor configuration files to be edited in a save manner. It creates a copy of the file you wish to edit, lock the file from being edited in another instance.\n\nThen it selects the editor by looking the environment variables *SUDO_EDITOR*, *DOAS_EDITOR*, *VISUAL*, *EDITOR*. If all are empty, will try commonly used terminal editors that can be found as a command on your system.\n\nAfter the file is edited and the user exits the editor, tor verify its configuration file but only from the modified file, if invalid, give option to edit again, exit without saving or save with danger flag.\n\n[![asciicast](https://asciinema.org/a/470389.svg)](https://asciinema.org/a/470389)\n\n## Installation\n\n### Requirements\n\nAll scripts requires the `tor` program, but vitor also requires an program to run as another user, specifically `sudo` or `doas`.\n\n### How to install on any unix system\n\nInstall the script and the manual:\n```sh\nsudo ./configure.sh install\n```\n\n### How to build deb package from source sode\n\n#### Build the package\n\nInstall developer scripts:\n```sh\nsudo apt install -y devscripts equivs\n```\n\nInstall build dependencies.\n```sh\nsudo mk-build-deps --remove --install\n```\nIf that did not work, have a look in `debian/control` file and manually install all packages listed under Build-Depends and Depends.\n\nBuild the package without signing it (not required for personal use) and install it.\n```sh\ndpkg-buildpackage -b --no-sign\n```\n\n#### Install the package\n\nThe package can be found in the parent folder.\nInstall the package:\n```sh\nsudo dpkg -i ../onionwash_*.deb\n```\n\n#### Clean up\n\nDelete temporary debhelper files in package source folder as well as debhelper artifacts:\n```sh\nsudo rm -rf *-build-deps_*.buildinfo *-build-deps_*.changes \\\ndebian/*.debhelper.log debian/*.substvars \\\ndebian/.debhelper debian/files \\\ndebian/debhelper-build-stamp debian/onionwash\n```\n\nDelete debhelper artifacts from the parent folder (including the .deb file):\n```sh\nsudo rm -f ../onionwash_*.deb ../onionwash_*.buildinfo ../onionwash_*.changes\n```\n\n## Usage\n\n### vitor\n\nvitor must not be run as root, in the case of a GUI editor, it would be catastrophic. Instead, the script will only do the necessary tasks as root using `sudo` or `doas`, edit the file as the normal user.\n\nIf no file is provided on the command line, it autodetects your tor configuration file if using [OnionJuggler](https://github.com/nyxnor/onionjuggler) or [Whonix](https://whonix.org).\n\nEdit the user tor configuration file /etc/tor/torrc (On Whonix: /usr/local/etc/tor/torrc.d/50_user.conf)\n```sh\nvitor\n```\n\nEdit any tor configuration file:\n```sh\nvitor -f /usr/share/tor/tor-services-defaults/torrc\n```\n\nSet your editor with the variable `VISUAL`:\n```sh\nexport VISUAL=\"mousepad\"\nvitor\n```\n\n#When using `doas`, set environment variables persist root or debian-tor login by using option `keepenv` for your user on doas.conf.\n### onion-parser\n\nonion-parser must be run as root and the tor configuration files included must have the *User* option set.\n\nRun onion-parser:\n```sh\nsudo onion-parser\n```\n\nSee how the files are parsed:\n```sh\nsudo onion-parser -v\n```\n\nInclude comments when parsing files:\n```sh\nsudo onion-parser -vv\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnyxnor%2Fonionwash","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnyxnor%2Fonionwash","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnyxnor%2Fonionwash/lists"}