File does not validate as base64
- Dominant language
- JavaScript
- Stars
- 19
- Forks
- 8
- PR merge metrics
- No merged PRs in 30d
Description
[This](
http://www.oxerfarm.com/images/smalltest.pdf) PDF-file does not validate as a valid base64. Any idea why?
```js
const fs = require('fs')
const base64Regex = require('base64-regex')
const b64 = fs.readFileSync('./smalltest.pdf' ,'base64')
console.log(b64) // missing == at end
console.log(base64Regex().test(b64)) // false
```
Contributor guide
No contributing guide indexed for this repository
Research direction
Reproduce the report using the provided Node.js snippet and the linked PDF input. Then inspect the package's base64 validation entry point to compare its behavior with the string produced by fs.readFileSync; done means establishing whether the validator or the reported expectation is incorrect.
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
- Needs clarification
- Newbie friendliness
- 25/100