# XOR Brute Force

Enumerate all possible XOR solutions. Current maximum key length is 2 due to browser performance. Optionally enter a string that you expect to find in the plaintext to filter results (crib). XOR Brute Force lives in the **Arithmetic** category of the `fx` menu.

## Parameters

| Parameter                     | Type    | Required | Default    | Description                                                             |
| ----------------------------- | ------- | -------- | ---------- | ----------------------------------------------------------------------- |
| Input                         | string  | yes      | —          | Value to transform. Previous step output or a literal.                  |
| Key length                    | number  | no       | `1`        | Numeric value. Default `1`.                                             |
| Sample length                 | number  | no       | `100`      | Numeric value. Default `100`.                                           |
| Sample offset                 | number  | no       | `0`        | Numeric value. Default `0`.                                             |
| Scheme                        | string  | no       | `Standard` | Choose one of: `Standard`, `Input differential`, `Output differential`. |
| Null preserving               | boolean | no       | `false`    | Disabled by default.                                                    |
| Print key                     | boolean | no       | `true`     | Enabled by default.                                                     |
| Output as hex                 | boolean | no       | `false`    | Disabled by default.                                                    |
| Crib (known plaintext string) | string  | no       | —          | Argument value for this operation.                                      |

`Input` is the primary value (previous step output or a literal).

## Returned value

| Type     | Description                                   |
| -------- | --------------------------------------------- |
| `string` | Result of the XOR Brute Force transformation. |

## Limitations

- This operation treats Input as raw bytes (binary-capable). Non-text payloads may display differently after decoding.
- Output can be large because many candidates or algorithms are enumerated.

## Example

<details>
<summary>Run XOR Brute Force</summary>

Enumerate all possible XOR solutions. Adjust optional parameters when the defaults do not match your payload.

1. Set **Input** to the value to transform (previous step output or a literal).

2. Review **Key length**, **Sample length**, **Sample offset**, **Scheme**, **Null preserving**, and other options and keep defaults unless your format requires otherwise.

3. Confirm **Output value** shows the transformed result.

</details>
