We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The support for asar works only on asar archives where JSON header size is less than 240 bytes.
I'm not sure why this limitation was added in the original PR #378. It looks like the exact logic came from this PR https://github.com/dyoshikawa/file-type/pull/1/files.
@Borewit do you remember if there was a reason why did you limit it to 240? if (jsonSize > 12 && jsonSize < 240 && buffer.length >= jsonSize + 16) {
if (jsonSize > 12 && jsonSize < 240 && buffer.length >= jsonSize + 16) {
You can easily break this by creating an asar archive that contains just a few more files and makes the JSON longer than 240 bytes.
The text was updated successfully, but these errors were encountered:
@Borewit do you remember if there was a reason why did you limit it to 240?
Sorry, I don't remember.
Sorry, something went wrong.
I could not find any reason for the 240 header length limit, therefor I will remove it. Thanks for bringing this to our attention @timojaask.
#406 Remove 240 json length limitation.
d9eaf33
Successfully merging a pull request may close this issue.
The support for asar works only on asar archives where JSON header size is less than 240 bytes.
I'm not sure why this limitation was added in the original PR #378. It looks like the exact logic came from this PR https://github.com/dyoshikawa/file-type/pull/1/files.
@Borewit do you remember if there was a reason why did you limit it to 240?
if (jsonSize > 12 && jsonSize < 240 && buffer.length >= jsonSize + 16) {
You can easily break this by creating an asar archive that contains just a few more files and makes the JSON longer than 240 bytes.
The text was updated successfully, but these errors were encountered: