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

Does not run on Backtrack 4 RC1 #5

Closed
zapbot opened this issue Jun 4, 2015 · 17 comments
Closed

Does not run on Backtrack 4 RC1 #5

zapbot opened this issue Jun 4, 2015 · 17 comments

Comments

@zapbot
Copy link
Contributor

zapbot commented Jun 4, 2015

I can't seem to get it to run on Backtrack 4 RC1.

I get this output when running the .sh file provided:

root@bt:~/zap# ./zap.sh
: command not found
Exception in thread "main" java.lang.NoClassDefFoundError: org/zaproxy/zap/ZAP
Caused by: java.lang.ClassNotFoundException: org.zaproxy.zap.ZAP
        at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
        at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
        at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
.  Program will exit.in class: org.zaproxy.zap.ZAP

Original issue reported on code.google.com by ian.paine on 2010-09-28 21:29:59

@zapbot
Copy link
Contributor Author

zapbot commented Jun 4, 2015

Simply fixed by removing the string in the sh file.

java -classpath lib/commons-codec-1.2.jar:lib/commons-collections-3.1.jar:lib/commons-configuration-1.1.jar:lib/commons-httpclient-3.0.jar:lib/commons-lang-2.0.jar:lib/commons-logging-api.jar:lib/commons-logging.jar:lib/hsqldb.jar:lib/jh.jar:lib/js.jar:lib/log4j-1.2.8.jar:lib/zaphelp.jar:zap.jar
org.zaproxy.zap.ZAP

Original issue reported on code.google.com by ian.paine on 2010-09-28 21:56:05

@zapbot
Copy link
Contributor Author

zapbot commented Jun 4, 2015

Hi Ian,

Did you install ZAP on Backtrack 4 RC1 yourself?
As I'm sure you realize its a classpath problem.
The zap.jar and all of the jars in the lib directory need to be on the classpath for
it to run.
Can you now run ZAP on Backtrack?

Many thanks,

Psiinon 

Original issue reported on code.google.com by psiinon on 2010-09-29 06:10:37

@zapbot
Copy link
Contributor Author

zapbot commented Jun 4, 2015

Yes, the simple issue was down to the RC variable in the sh file, although makes the
sh file a little more readable it did not work on BT4 RC1(?!). I just moved the classpath
into the command and now it works. Bit of an odd one, but I guess that this should
be a more generic fix.

See attached.

Original issue reported on code.google.com by ian.paine on 2010-09-29 08:01:44


- _Attachment: [zap.sh](https://storage.googleapis.com/google-code-attachments/zaproxy/issue-5/comment-3/zap.sh)_

@zapbot
Copy link
Contributor Author

zapbot commented Jun 4, 2015

OK, I've just looked into this a little more, it was late last night when I looked at
it.

If you declare the var as lower case it'll work also.

Original issue reported on code.google.com by ian.paine on 2010-09-29 08:30:02


- _Attachment: [zap.sh](https://storage.googleapis.com/google-code-attachments/zaproxy/issue-5/comment-4/zap.sh)_

@zapbot
Copy link
Contributor Author

zapbot commented Jun 4, 2015

Thats weird!
But if it works, who am I to complain.
I'll change it to use lower case.

Thanks for your help!

Psiinon

Original issue reported on code.google.com by psiinon on 2010-09-29 18:52:58

@zapbot
Copy link
Contributor Author

zapbot commented Jun 4, 2015

just a shell-script issue (special characters in your shell script)

just do a:
dos2unix zap.sh
sh zap.sh

...windows text editors ;-)

/brtw2003



Original issue reported on code.google.com by brtw2003 on 2010-10-05 20:49:20

@zapbot
Copy link
Contributor Author

zapbot commented Jun 4, 2015

Running:

dos2unix zap.sh

worked for me.

Is anyone else have any problems that are not fixed by this?
I'll check the new file soon, but leave the issue open in case anyone has any similar
problems.

Good spot brtw2033 :)

Psiinon

Original issue reported on code.google.com by psiinon on 2010-10-06 11:21:56

@zapbot
Copy link
Contributor Author

zapbot commented Jun 4, 2015

dos2unix zap.sh

Fixed the problem for me too!

Original issue reported on code.google.com by rene.purcell on 2010-10-06 15:18:17

@zapbot
Copy link
Contributor Author

zapbot commented Jun 4, 2015

I've added a new file here: http://code.google.com/p/zaproxy/downloads/detail?name=zap_1.0.0b.sh

Does this now work for everyone?

Thanks

Original issue reported on code.google.com by psiinon on 2010-10-07 12:01:33

@zapbot
Copy link
Contributor Author

zapbot commented Jun 4, 2015

I've just downloaded
ZAP_1.0.0b_installation.tar.gz       ZAP 1.0.0 Cross Platform Installation (with fix
for issue 1)
which i believe includes above fix?

Having same problem, granted +x to zap.sh and tried var as lowercase.  Same thing

i.e.

cp="lib/commons-codec-1.2.jar:lib/commons-collections-3.1.jar:lib/commons-configuration-1.1.jar:lib/commons-httpclient-3.0.jar:lib/commons-lang-2.0.jar:lib/commons-logging-api.jar:lib/commons-logging.jar:lib/hsqldb.jar:lib/jh.jar:lib/js.jar:lib/log4j-1.2.8.jar:lib/zaphelp.jar:zap.jar"



java -classpath $cp org.zaproxy.zap.ZAP

Original issue reported on code.google.com by yeleek on 2010-10-07 12:40:16

@zapbot
Copy link
Contributor Author

zapbot commented Jun 4, 2015

For what its worth - writing own script from scratch and its fine.

Original issue reported on code.google.com by yeleek on 2010-10-07 12:45:19

@zapbot
Copy link
Contributor Author

zapbot commented Jun 4, 2015

No, I'm afraid it doesnt contain this fix.
You can either download the fix  http://code.google.com/p/zaproxy/downloads/detail?name=zap_1.0.0b.sh
or run dos2unix on zap.sh

Thanks

Original issue reported on code.google.com by psiinon on 2010-10-07 13:19:00

@zapbot
Copy link
Contributor Author

zapbot commented Jun 4, 2015

I'm running Gentoo. I've tried each of the following with no success in starting up
zap using either the downloaded 1.0.0b or source from SVN.  I have checked that my
zap.sh file is in UNIX format, so that is not the issue.

$ eselect java-vm list
Available Java Virtual Machines:
  [1]   icedtea6-bin  system-vm user-vm
  [2]   sun-jdk-1.6 
  [3]   sun-jre-bin-1.6 

My actual error is mildly different, so perhaps something else is afoot:

Exception in thread "main" java.lang.NoClassDefFoundError: org/zaproxy/zap/ZAP
Caused by: java.lang.ClassNotFoundException: org.zaproxy.zap.ZAP
        at java.net.URLClassLoader$1.run(URLClassLoader.java:217)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(URLClassLoader.java:205)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:321)
        at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:266)
Could not find the main class: org.zaproxy.zap.ZAP. Program will exit.

Original issue reported on code.google.com by bill.e.ghote on 2010-11-08 11:10:39

@zapbot
Copy link
Contributor Author

zapbot commented Jun 4, 2015

Please disregard my comment 13.  Issue was resolved, mostly by ensuring sufficient coffee.

Original issue reported on code.google.com by bill.e.ghote on 2010-11-08 11:35:29

@zapbot
Copy link
Contributor Author

zapbot commented Jun 4, 2015

Hey, I 'll have to try that myself more often :)

Original issue reported on code.google.com by psiinon on 2010-11-08 11:36:34

@zapbot
Copy link
Contributor Author

zapbot commented Jun 4, 2015

Fixed in 1.1.0

Original issue reported on code.google.com by psiinon on 2010-12-04 11:01:01

@zapbot zapbot closed this as completed Jun 4, 2015
thc202 pushed a commit that referenced this issue Jun 4, 2015
…and resources. I implemented the #5 proposal for the SplashScreen (which is the lead now in the poll) but only since the final poll will be closed.
kingthorin added a commit to kingthorin/zaproxy that referenced this issue Aug 15, 2016
Very minor JDoc item.
kingthorin added a commit to kingthorin/zaproxy that referenced this issue Aug 21, 2016
Very minor JDoc item.
kingthorin added a commit to kingthorin/zaproxy that referenced this issue Aug 21, 2016
Very minor JDoc item.
kingthorin added a commit to kingthorin/zaproxy that referenced this issue Sep 2, 2016
Very minor JDoc item.
kingthorin added a commit to kingthorin/zaproxy that referenced this issue Sep 18, 2016
Very minor JDoc item.
kingthorin added a commit to kingthorin/zaproxy that referenced this issue Sep 23, 2016
Very minor JDoc item.
kingthorin added a commit to kingthorin/zaproxy that referenced this issue Oct 27, 2016
Very minor JDoc item.
kingthorin added a commit to kingthorin/zaproxy that referenced this issue Oct 27, 2016
Very minor JDoc item.
kingthorin added a commit to kingthorin/zaproxy that referenced this issue Nov 13, 2016
Very minor JDoc item.
kingthorin added a commit to kingthorin/zaproxy that referenced this issue Nov 17, 2016
Very minor JDoc item.
kingthorin added a commit to kingthorin/zaproxy that referenced this issue Jan 20, 2017
Very minor JDoc item.
kingthorin added a commit to kingthorin/zaproxy that referenced this issue Jan 27, 2017
Very minor JDoc item.
kingthorin added a commit to kingthorin/zaproxy that referenced this issue Apr 9, 2017
Very minor JDoc item.
@lock
Copy link

lock bot commented Nov 2, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked and limited conversation to collaborators Nov 2, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Development

No branches or pull requests

1 participant