Giter Site home page Giter Site logo

Comments (5)

phosphore avatar phosphore commented on June 2, 2024

Hello @Cdivyam! Thanks for filing your issue. It looks your input app.asar is breaking the asar as you suspected. I tried to bump asar to the latest version. Would it be possible for you to use 27e772f and try again on the same archive or share the app.asar with us? Is the npx asar extract app.asar <destfolder> itself working?

from electronegativity.

phosphore avatar phosphore commented on June 2, 2024

PickleIterator is part of the chromium-pickle-js package, which is used to serialize and deserialize data in Chromium's pickle format. In your specific case, the getReadPayloadOffsetAndAdvance function is called to get the offset of the data and advance the iterator, but it fails to read the data of the specified length.

This could be due to:

  • A corrupted or invalid ASAR file: The file might contain an incorrect data length field, leading the extraction code to attempt to read an incorrect or too large payload size.
  • Running out of memory: If the payload size is too large, Node.js might run out of memory during the deserialization process. This can be addressed by increasing the memory limit for Node.js using the --max-old-space-size flag.
  • A bug or limitation in the chromium-pickle-js

from electronegativity.

Cdivyam avatar Cdivyam commented on June 2, 2024

Hello @Cdivyam! Thanks for filing your issue. It looks your input app.asar is breaking the asar as you suspected. I tried to bump asar to the latest version. Would it be possible for you to use 27e772f and try again on the same archive or share the app.asar with us? Is the npx asar extract app.asar <destfolder> itself working?

Hi @phosphore thanks for information.

I have tried running asar extract app.asar <destfolder>, even that gives the same issue as above.

My asar version is 3.2.0.

The asar file is just 47 MB so I don't think it should be a issue with memory.

ASAR FILE https://drive.google.com/file/d/1RXk1O-GES--rqEPtC5uNowOrMq6x_NoS/view?usp=share_link

from electronegativity.

phosphore avatar phosphore commented on June 2, 2024

An ASAR archive typically consists of two parts:

  • Header: The header is a JSON string that represents the file system structure and metadata of the ASAR archive. It includes information about files and directories, such as their names, sizes, and offsets within the archive. The header is stored at the beginning of the ASAR file.
  • Content: Following the header, the content of the files is stored in the ASAR archive. The content is concatenated without compression, and its position and size are determined by the metadata specified in the header.

It seems that the asar file you attached does not contain a properly formatted JSON string representing the file system structure, hence the ASAR library is not able to read or extract the archive correctly. Investigating it a bit more, you can see that in place of that you have an HEX string of characters. I'll leave this reversing part to you.

Cheers,

from electronegativity.

Cdivyam avatar Cdivyam commented on June 2, 2024

Thanks for the inputs @phosphore . It is good to know that the library is not at fault.

from electronegativity.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.