Kam1n0-Community icon indicating copy to clipboard operation
Kam1n0-Community copied to clipboard

Fail to open the result file

Open whj0401 opened this issue 3 years ago • 2 comments

Hello. I am trying to use asm2vec-clone to do some tests. After installing everything, I created an App and used 'index' and binary composition analysis to do function matching. Then I got the result file. When I was trying to open the result file, the webpage showed an alarm with unacceptable request info, and displayed nothing on the page. The download button on the upper-right did not work either. In the logging file, it shows a NullPointerException when I click the button to open a result file. I tried to remove and reinstall the kam1n0-server, but nothing changed. My PC is a laptop with win10, the JRE is jre-8u301-windows-x64.exe. I also tried different versions of Kam1n0 server, from 2.0 to 2.2, nothing changed. Could you give me any help? Thanks in advance.

java.lang.NullPointerException: null
	at ca.mcgill.sis.dmas.kam1n0.problem.clone.detector.rep.Asm2VecCloneDetectorIntegration.detectClonesForFuncToBeImpleByChildren(Asm2VecCloneDetectorIntegration.java:102) ~[kam1n0-server.jar:2.0.0]
	at ca.mcgill.sis.dmas.kam1n0.problem.clone.FunctionCloneDetector.detectClonesForFunc(FunctionCloneDetector.java:112) ~[kam1n0-server.jar:2.0.0]
	at ca.mcgill.sis.dmas.kam1n0.app.clone.FunctionCloneDetectorForWeb.detectClones(FunctionCloneDetectorForWeb.java:123) ~[kam1n0-server.jar:2.0.0]
	at ca.mcgill.sis.dmas.kam1n0.app.clone.FunctionCloneDetectorForWeb.lambda$detectClones$0(FunctionCloneDetectorForWeb.java:92) ~[kam1n0-server.jar:2.0.0]
	at java.util.stream.IntPipeline$4$1.accept(Unknown Source) ~[na:1.8.0_301]
	at java.util.stream.Streams$RangeIntSpliterator.forEachRemaining(Unknown Source) ~[na:1.8.0_301]
	at java.util.Spliterator$OfInt.forEachRemaining(Unknown Source) ~[na:1.8.0_301]
	at java.util.stream.AbstractPipeline.copyInto(Unknown Source) ~[na:1.8.0_301]
	at java.util.stream.AbstractPipeline.wrapAndCopyInto(Unknown Source) ~[na:1.8.0_301]
	at java.util.stream.ReduceOps$ReduceTask.doLeaf(Unknown Source) ~[na:1.8.0_301]
	at java.util.stream.ReduceOps$ReduceTask.doLeaf(Unknown Source) ~[na:1.8.0_301]
	at java.util.stream.AbstractTask.compute(Unknown Source) ~[na:1.8.0_301]
	at java.util.concurrent.CountedCompleter.exec(Unknown Source) ~[na:1.8.0_301]
	at java.util.concurrent.ForkJoinTask.doExec(Unknown Source) ~[na:1.8.0_301]
	at java.util.concurrent.ForkJoinPool.helpComplete(Unknown Source) ~[na:1.8.0_301]
	at java.util.concurrent.ForkJoinPool.externalHelpComplete(Unknown Source) ~[na:1.8.0_301]
	at java.util.concurrent.ForkJoinTask.externalAwaitDone(Unknown Source) ~[na:1.8.0_301]
	at java.util.concurrent.ForkJoinTask.doInvoke(Unknown Source) ~[na:1.8.0_301]
	at java.util.concurrent.ForkJoinTask.invoke(Unknown Source) ~[na:1.8.0_301]
	at java.util.stream.ReduceOps$ReduceOp.evaluateParallel(Unknown Source) ~[na:1.8.0_301]
	at java.util.stream.AbstractPipeline.evaluate(Unknown Source) ~[na:1.8.0_301]
	at java.util.stream.ReferencePipeline.collect(Unknown Source) ~[na:1.8.0_301]
	at ca.mcgill.sis.dmas.kam1n0.app.clone.FunctionCloneDetectorForWeb.detectClones(FunctionCloneDetectorForWeb.java:97) ~[kam1n0-server.jar:2.0.0]
	at ca.mcgill.sis.dmas.kam1n0.app.clone.CloneSearchResources.detectFunctionClone(CloneSearchResources.java:81) ~[kam1n0-server.jar:2.0.0]
	at ca.mcgill.sis.dmas.kam1n0.app.clone.BinaryAnalysisProcedureCompositionAnalysis.runProcedure(BinaryAnalysisProcedureCompositionAnalysis.java:127) ~[kam1n0-server.jar:2.0.0]
	at ca.mcgill.sis.dmas.kam1n0.app.scheduling.LocalDmasJobProcedure.execute(LocalDmasJobProcedure.java:104) ~[kam1n0-server.jar:2.0.0]
	at org.quartz.core.JobRunShell.run(JobRunShell.java:202) ~[kam1n0-server.jar:2.0.0]
	at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:573) ~[kam1n0-server.jar:2.0.0]

whj0401 avatar Oct 17 '21 14:10 whj0401

@whj0401 Hi, I happen to test Asm2Vec these two days. I have the similar issue and solved. Think it is a jre version problem. you may look at #20.

Vulmatch avatar Oct 17 '21 23:10 Vulmatch

@LeoLiu-2020 Thanks for your reply. I tried jre8u172 but nothing changed. The link you provided does not work. I find it from https://www.oracle.com/java/technologies/javase/javase8-archive-downloads.html and search for jre-8u172-windows-x64.exe I make sure the java version by command line java -version, and it shows

java version "1.8.0_172"
Java(TM) SE Runtime Environment (build 1.8.0_172-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.172-b11, mixed mode)

Actually, I do not think the java version is a problem. I tested some naive cases at the very beginning and I could open and see the composition summary at that time. However, after trying several large cases, each binary with about 3000 functions, I cannot open the summary page again. Then restarting the server, reinstalling the server (in the same folder and in a different folder), and reinstalling the java change nothing. Thank you for the same, but I still need help.

whj0401 avatar Oct 18 '21 05:10 whj0401