Bug report: From Base64 in Strict mode with URL safe alphabet doesn't work
- Dominant language
- JavaScript
- Stars
- 35.8k
- Forks
- 4.1k
- Avg merge
- 2d 26m
- Merged PRs (30d)
- 33
Description
**Describe the bug**
`From Base64` with `URL safe` alphabet doesn't work in `Strict mode`. It shows `Error: Base64 input contains non-alphabet char(s)`
**To Reproduce**
_Input:_ "test"
_Recipe:_
- To Base64 (URL safe alphabet)
- From Base64 (URL safe alphabet, Strcit mode)
_Output:_ "Error: Base64 input contains non-alphabet char(s)"
https://gchq.github.io/CyberChef/#recipe=To_Base64('A-Za-z0-9-_')From_Base64('A-Za-z0-9-_',false,true)&input=dGVzdA
**Expected behaviour**
Expected output: "test"
**Screenshots**

CyberChef version: 10.5.2
Contributor guide
Research direction
Start by reproducing the linked CyberChef recipe using the To Base64 and From Base64 operations with the URL-safe alphabet and Strict mode enabled. Trace how the encoded value is validated, then confirm that the recipe returns "test" without the non-alphabet-character error and add or update coverage for this case.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100