Metadata-Version: 2.4
Name: faraday-cli
Version: 2.4.0
Summary: Faraday cli package
Home-page: https://github.com/infobyte/faraday-cli
Author: Faradaysec
Author-email: devel@faradaysec.com
License: GNU General Public License v3
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: GNU General Public License v3 (GPLv3)
Classifier: Natural Language :: English
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: faraday-plugins>=1.32.0
Requires-Dist: click>=8.0.1
Requires-Dist: colorama>=0.4.4
Requires-Dist: jsonschema>=3.2.0
Requires-Dist: PyYAML>=5.4.1
Requires-Dist: simple-rest-client>=1.0.8
Requires-Dist: tabulate>=0.8.9
Requires-Dist: validators>=0.18.2
Requires-Dist: spinners>=0.0.24
Requires-Dist: termcolor>=1.1.0
Requires-Dist: cmd2<4.0.0,>=3.2.0
Requires-Dist: log-symbols>=0.0.14
Requires-Dist: arrow>=1.1.0
Requires-Dist: py-sneakers>=1.0.1
Requires-Dist: luddite>=1.0.2
Requires-Dist: packaging>=21.3
Requires-Dist: httpx>=0.24.0
Requires-Dist: requests>=2.25.0
Provides-Extra: dev
Requires-Dist: giteasychangelog; extra == "dev"
Requires-Dist: flake8; extra == "dev"
Requires-Dist: black; extra == "dev"
Requires-Dist: pre-commit; extra == "dev"
Provides-Extra: test
Requires-Dist: pytest; extra == "test"
Requires-Dist: pytest-cov; extra == "test"
Requires-Dist: faradaysec; extra == "test"
Requires-Dist: cmd2-ext-test; extra == "test"
Provides-Extra: docs
Requires-Dist: mkdocs; extra == "docs"
Requires-Dist: mkdocs-material; extra == "docs"
Dynamic: author
Dynamic: author-email
Dynamic: classifier
Dynamic: description
Dynamic: description-content-type
Dynamic: home-page
Dynamic: license
Dynamic: license-file
Dynamic: provides-extra
Dynamic: requires-dist
Dynamic: requires-python
Dynamic: summary

# Faraday on the terminal
Use faraday directly from your favorite terminal

![Example](./docs/docs/images/general.gif)

faraday-cli is the official client that makes automating your security workflows easier.

## Features

- **Two ways to use it** — an interactive shell or single commands for scripts and pipelines
- **Import tool output** — process reports from 100+ security tools ([Faraday Plugins](https://github.com/infobyte/faraday_plugins)), or run a supported tool and upload its results automatically
- **Workspaces, hosts, services and vulnerabilities** — list, create, update and delete them, with stats and a workspaces dashboard
- **AI pentests with FaradAI** — launch FaradAI scans and triage from the terminal, including self-registration on the FaradAI-scan SaaS
- **Agents and scanners** — run local Faraday Agents (runners) and server-side cloud agents (scanners)
- **Several servers** — saved connection sessions to switch between servers or users
- **Executive reports** — generate them from your templates (commercial versions of Faraday)

Before installing, we recommend creating and activating a Python virtual environment to avoid affecting your system Python packages. For example:

```shell
python3 -m venv .venv
source .venv/bin/activate
```

You can also use `virtualenv` if you prefer. Once the virtual environment is active, run the installation commands below.

## Install from pip

```
pip install faraday-cli
```

## Install from source
```shell script
git clone https://github.com/infobyte/faraday-cli.git
cd faraday-cli
pip install .
```

## Documentation

For more info you can check our [documentation][doc]. From the CLI itself,
`faraday-cli --help` shows the common commands and `faraday-cli <command> -h`
the options of any command.


## Use it like a command

### Login

Configure auth for faraday-cli

```shell script
$ faraday-cli auth
```
![Example](./docs/docs/images/auth.gif)

Each login is saved as a named session (`user@host`), so you can keep several
servers or users and switch between them:

```shell script
$ faraday-cli auth list
  ID  ACTIVE    NAME                       KIND    SERVER                        USER     WORKSPACE
----  --------  -------------------------  ------  ----------------------------  -------  -----------
   1  ✔         alice@faraday.example.com  server  https://faraday.example.com/  alice    some_name
   2            faraday@localhost          server  http://localhost:5985         faraday  -

$ faraday-cli auth use 2
$ faraday-cli status
```


### Create a workspace
When you create a workspace by default is selected as active, unless you use the "-d" flag
```shell script
$ faraday-cli workspace create some_name
✔ Created workspace: some_name
```

### Select active workspace

```shell script
$ faraday-cli workspace select some_name
✔ Selected workspace: some_name
```

### List workspaces

```shell script
$ faraday-cli workspace list
NAME         HOSTS    SERVICES    VULNS  ACTIVE    PUBLIC    READONLY
---------  -------  ----------  -------  --------  --------  ----------
some_name       14          13       39  True      False     False
```

### List hosts of a workspace

```shell script
$ faraday-cli host list
  ID  IP           OS       HOSTNAMES          SERVICES  VULNS
----  -----------  -------  ---------------  ----------  -------
 574  127.0.0.1    unknown                            1  3
 566  127.0.0.10   unknown                            1  3
 569  127.0.0.11   unknown                            1  3
 590  58.76.184.4  unknown  www.googlec.com           0  -
```

### Get host

```shell script
$ faraday-cli host get 574
Host:
  ID  IP         OS       HOSTNAMES    OWNER    OWNED      VULNS
----  ---------  -------  -----------  -------  -------  -------
 574  127.0.0.1  unknown               faraday  False          3

Services:
  ID  NAME    DESCRIPTION    PROTOCOL      PORT  VERSION    STATUS      VULNS
----  ------  -------------  ----------  ------  ---------  --------  -------
2638  ssh                    tcp             22  unknown    open            2

Vulnerabilities:
   ID  NAME                                      SEVERITY    STATUS    CONFIRMED    TOOL
-----  ----------------------------------------  ----------  --------  -----------  -------
13509  SSH Weak Encryption Algorithms Supported  MED         opened    False        Openvas
13510  SSH Weak MAC Algorithms Supported         LOW         opened    False        Openvas
13511  TCP timestamps                            LOW         opened    False        Openvas
```

### Create hosts

```shell script
$ faraday-cli host create -d '[{"ip": "stan.local", "description": "some server"}]'
```

Or pipe it
```shell script
$ echo '[{"ip": "1.1.1.5", "description": "some text"}]' | faraday-cli host create --stdin
```

Quote the arguments as you would for any other command. The escaped syntax used
in older versions of this README (`-d \''[...]'\'`) is still accepted.


### Import vulnerabilities from tool report

```shell script
$ faraday-cli tool report "/path/to/report.xml"
```
![Example](./docs/docs/images/process_report.gif)

### Import vulnerabilities from command

```shell script
$ faraday-cli tool run "ping -c 1 www.google.com"
```
![Example](./docs/docs/images/command.gif)

### List agents (runners)

Local Faraday Agents (dispatcher *runners*). Reachable as `agent`, `agents`,
`runner` or `runners` (all equivalent).

```shell script
$ faraday-cli agent list
  ID  NAME      ACTIVE    STATUS    EXECUTORS
----  --------  --------  --------  -----------
   8  internal  True      online    nmap
```

### Run executor

```shell script
$ faraday-cli agent run -a 8 -e nmap -p '{"target": "www.google.com"}'
Running executor: internal/nmap
Parameters: {"TARGET": "www.google.com"}
Generated Command: 13
```

### Run a FaradAI scan (cloud agents / scanners)

Cloud agents are server-side security *scanners* (the `v3/cloud_agents` API),
distinct from the local runners above. FaradAI is one such scanner, with its own
command and top-level shortcuts.

```shell script
# Quick FaradAI pentest (standard tier — 20 rounds)
$ faraday-cli pentest --target https://example.com

# Deeper audit (80 rounds), and watch it until it finishes
$ faraday-cli pentest --target https://example.com --advanced --watch

# Triage the existing findings of a workspace
$ faraday-cli triage -w my_workspace --severities critical,high --reproduce
```

List and run any cloud agent generically (`scanner` is an alias of `scanners`):

```shell script
$ faraday-cli scanners list
  ID  NAME                SLUG        CATEGORY    LAST_RUN
----  ------------------  ----------  ----------  ----------
   7  FaradAI             faradai     AI Pentest  -
   6  New CVEs Detection  top-10-cve  discovery   -

# see the parameters a scanner accepts
$ faraday-cli scanners get 7

# run it with parameters…
$ faraday-cli scanners run faradai -w my_workspace \
    --param TARGET=https://example.com --param ROUNDS=20

# …or let the CLI ask for them (and confirm before launching)
$ faraday-cli scanners run faradai -w my_workspace
```

> No Faraday server? The first `pentest` / `triage` (with nothing configured)
> walks you through creating a FaradAI-scan SaaS account, which is saved as the
> `faradai-scan` session. You can also do it step by step with
> `faradai register` / `faradai verify` / `faradai login`. See the
> [FaradAI docs][doc].

## Use it like a shell

Faraday-cli can be used as a shell and have all the same commands you have as a cli

![Example](./docs/docs/images/shell.gif)

## Use cases

### Continuous scan your assets with faraday

For example run nmap for all the hosts in a workspace and import the results back to faraday
```shell
$ faraday-cli host list -ip -w my_workspace | nmap -iL - -oX /tmp/nmap.xml && faraday-cli tool report -w my_workspace /tmp/nmap.xml
```

### Scan your subdomains

Use a tool like assetfinder to do a domains lookup, scan them with nmap and send the results to faraday

```shell
$ assetfinder -subs-only example.com| sort | uniq |awk 'BEGIN { ORS = ""; print " {\"target\":\""}
{ printf "%s%s", separator, $1, $2
separator = ","}END { print "\"}" }' | faraday-cli  agent run  -a 1 -e nmap --stdin
```


## License

This project is licensed under the GNU General Public License v3.0 — see the [LICENSE](LICENSE) file for details.

[doc]: https://docs.faraday-cli.faradaysec.com


2.4.0 [Nov 25th, 2026]:
---
 * [MOD] Docs and README updated to the current commands: sessions, scanners, FaradAI, workspace enable/disable, core commands, settings and natural quoting. #117
 * [MOD] Update `validators` (no max version), `httpx` (no max version) and `cmd2` (3.x) requirements. Python >=3.10 is now required. #118
 * [MOD] Update faraday-plugins minimum version to 1.32.0. #9999
 * [FIX] `faradai scan`/`pentest` refuses an out-of-scope target before launching (self-registered `ext_<domain>` workspaces only scan their own domain), and inline onboarding no longer offers "Register anyway" — a mismatched email stops before the code is sent. Adds `--skip-scope-check` for operator-authorized workspaces. #119
 * [FIX] faraday-cli no longer fails to start with `No module named six` on clean installs: the undeclared `six` import was removed. #121

2.3.0 [Oct 19th, 2026]:
---
 * [ADD] FaradAI cloud agents support: `scanners` (list/get/run), `faradai scan|triage` with `pentest`/`triage` shortcuts, and named connection sessions (`auth list|use|rm`). #112
 * [ADD] FaradAI-scan SaaS onboarding from the CLI: `faradai register`/`verify`/`login` to sign up and scan without a Faraday server. #113
 * [FIX] The CLI no longer crashes on startup when the Faraday server returns a 5xx; it warns and keeps running. #114
 * [FIX] Command mode accepts again the escaped quoting from the docs (`\"nmap host\"`, `\''{...}'\'`) alongside the natural shell quoting. #115

2.2.2 [May 14th, 2026]:
---
 * [FIX] Fixed `ignore_ssl` setting not being persisted when configured through the interactive prompt. #98
 * [MOD] Installation guide virtualenv recomendation. #107

2.2.1 [Jan 26th, 2026]:
---
 * [MOD] Pinned cmd2 to <3 to avoid breaking changes introduced in v3. #102

2.2.0 [Sep 2nd, 2025]:
---
 * [ADD] Added `min-severity` and `max-severity` parameters for importing vulnerabilities. #97
 * [MOD] Updated `vuln list` command documentation. #93
 * [MOD] Modified `validators` package version requirement. #100

2.1.12 [Jan 6th, 2025]:
---
 * [MOD] Updated report generation to support multiple workspaces. #89

2.1.11 [Feb 26th, 2024]:
---
 * [FIX] Fixed workspace activation. #87

2.1.10 [Apr 5th, 2023]:
---
 * [MOD] Change resolve_hostname to false for default, add the --resolve-hostname flag for host create and add --force flag to tool run to process the output of the command regardless of the return code. #79

2.1.9 [Dec 15th, 2022]:
---
 * [ADD] Add vuln delete vuln-id.


2.1.8 [OCt 27th, 2022]:
---
 * [ADD] New method to update existing vuln.

2.1.7 [Sep 13th, 2022]:
---
 * Add personal status.
 * Replace the apply_tag function with plugins parameters.
 * Update agents docs.

2.1.6 [Jul 26th, 2022]:
---
 * Remove workspace from get/list agent and add it to run agent.

2.1.5 [Jun 10th, 2022]:
---
 * Now shell mode doesn't exit if it has faraday's url and token but the server is down.
 * Support multiple tags on import and run.
 * Update gifs of readme.

2.1.4 [May 23th, 2022]:
---
 * Check if token is valid on start in shell mode.

2.1.3 [May 20th, 2022]:
---
 * Now is possible to doesn't resolve hostname by changing resolve_hostname parameter.
 * Fix the colors in Severity Stats.

2.1.2 [Jan 11th, 2022]:
---
 * Update Documentation.

2.1.1 [Dec 13th, 2021]:
---
 * ADD setting to enable/disable auto command detection.
 * Fix error message when a command dont generate valid output.
 * FIX tables visualization when host has to many hostnames.
 * Show if update is available.

2.1.0 [Nov 19th, 2021]:
---
 * Add fields to executive reports generation command.
 * Add KAKER_MODE easter egg.
 * Update plugins requirements to 1.5.6

2.0.2 [Aug 9th, 2021]:
---
 * add --create-workspace parameter for tool command
 * Ask for executive report template if not provided
 * Add for executor parameters if not provided
 * [FIX] Bug using an invalid executor name
 * Update readme to fix some examples

2.0.1 [Jun 29th, 2021]:
---
 * [FIX] Show help if no subcommand is provided

2.0.0 [Jun 29th, 2021]:
---
 * [MOD] Change commands to verbs
 * Enable and disable Workspaces
 * Fix to use cmd2 2.0 and update requirements
 * Show message if license is expired
 * [MOD] Change to V3 api of faraday
 * Add command to upload evidence to vuln

1.1.1 [Jun 9th, 2021]:
---
 * Fix to use cmd2 2.0 and update requirements
 * Show message if license is expired
 * [MOD] Change to V3 api of faraday

1.1.0 [Apr 16th, 2021]:
---
 * Add new command to process a tool execution
 * Add command to list vulnerabilities
 * Add versions to dependencies
 * Add setting to ignore INFO vulns
 * Show only active workspaces by default unless you use the --show-inactive parameter
 * [MOD] Add support for tags
 * Update faraday_plugins version dependency
 * Fix create_hosts docs typo
 * Show user in status
 * [MOD] Update faraday-plugins

1.0.2 [Feb 17th, 2021]:
---
 * ADD documentation (made with mkdocs)
 * MOD Convert some command and help to plural
 * FIX Exit shell in case of invalid authorization result
 * FIX faraday 3.14.1 updated security lib, and make login bugged

1.0.1 [Jan 4th, 2021]:
---
 * Fix error in list_host command

1.0.0 [Dec 28th, 2020]:
---
 * Add List Services command
 * Change the import command/report message
 * Add support for executive reports
 * Show in status if token is valid

0.1.0 [Aug 28th, 2020]:
---
 * First version released, use with caution as it is still beta phase.
 * Access a faraday server from your CLI, your CI o any other bash interpreter.
