Skip to content
New issue

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

NW 0.32.2 - CRASH On accessing properties of elements created with createElement #6768

Closed
Jivec opened this issue Aug 15, 2018 · 13 comments
Closed

Comments

@Jivec
Copy link

Jivec commented Aug 15, 2018

ac64e008-4454-4660-b279-18e92c33d2f3.zip
Hello,

The problem is happening when im trying to run the exe with the binary files , im using webpack and combining some modules classes to a bundle , no problems if i run it normally. If i compile it to binary with both settings nw-module or not i get a crash, i managed to narrowed it down to a single line.

`
let imx = document.createElement('div');

    document.body.appendChild(imx);
    imx.id = "test";
    console.log(imx);`

When trying to access the id of the element it crashes if i remove that line everything works and the element is inserted correctly!

Thanks in advanced !!!!

@rogerwang
Copy link
Member

Could you please provide a full example to reproduce?

@Jivec
Copy link
Author

Jivec commented Aug 16, 2018

Ok please try this.

//core.js
 import t from './test.js';
 let tinst = new  t(db);

 //test,js
 class T{


     constructor(db){
          let imx = document.createElement('div');
          document.body.appendChild(imx);
          imx.id = "test"; //problem with pointer i guess
          console.log(imx);
     }
 }
export default T;


// If you build with 0.32.2 you can reproduce the problem the only difference in my example is that i have them as bundle combined 

@Jivec
Copy link
Author

Jivec commented Aug 17, 2018

Please tell me if with this example you can reproduce the crash when using binary.

Thanks in Advance!!

@rogerwang
Copy link
Member

Please upload a full sample (not code snippet) so we can reproduce it.

@Jivec
Copy link
Author

Jivec commented Aug 17, 2018

The problem persists in 0.32.3 , i reproduced it with a simpler example since the original project consists of many files.
Attached the package.nw you can try it with both 0.32.2 and 0.32.3, found that it happens in both of these versions.

Thanks in Advance once again.

package.nw.zip
If you replace the line that test.js is accessing the id property of the newly created element it works (i mean in binary) because if i include the bundle.js without compiling down it just works.

I also found that in prior version of nw.js is working and thats what im using now , but i would love to have the chromium 68 features :)

Thank you for your amazing job!!

@Ziiven
Copy link

Ziiven commented Aug 18, 2018

Maybe it is the same issue that I encountered #6742

@rogerwang
Copy link
Member

I can reproduce the crash with 0.32 and it seems fixed in 0.33.0-beta1. Please have a try.

@cTn-dev
Copy link

cTn-dev commented Aug 18, 2018

@rogerwang correct, the 0.33.0-beta1 worked fine.
Would it be too much to ask for an updated beta/new nightly of the beta with node 10.9.0?
I am after the CVE fixes, since my NW.js project also acts as a https server so i am vulnerable to all 3 CVEs that got recently fixed.

@rogerwang
Copy link
Member

Thanks for verifying. Will update the beta with Node 10.9 soon.

@Jivec
Copy link
Author

Jivec commented Aug 18, 2018

Still not fixed for me in the complex scenario i described before

d4354d0d-4bc2-4c2e-bdc1-66119c341dbe.zip

@rogerwang
Copy link
Member

@rogerwang
Copy link
Member

@Jivec please try to provide a sample. Thanks

@rogerwang
Copy link
Member

close until more information is available.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants