• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Frits Walraven
Bartenders:
  • Piet Souris
  • Himai Minh

servletException - securityUtil

 
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi!

I migrated my jforum (2.1.4) on a new server (tomcat5, mysql 4.1.15) and now get following exception when trying access anything ...

javax.servlet.ServletException
org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:290)
org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:161)
org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:114)

(...)

root cause

java.lang.NoClassDefFoundError
net.jforum.JForumBaseServlet.init(JForumBaseServlet.java:97)
net.jforum.JForum.init(JForum.java:87)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

(...)

--> everything else works fine (including other pages using servlets) ... any idea what could cause this?

Thanks in advance,
Alex
[originally posted on jforum.net by urbus]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Was my first guess too, but i double checked and everything looks fine ...

Is it possible that using tomcat5 i have to set some security-related entries in the policy files?

Greets,
Alex
[originally posted on jforum.net by urbus]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Looks like you missed some classes when migrating.

Rafael
[originally posted on jforum.net by Rafael Steil]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
None that I'm aware of. Have you tried copying the files again? it could some some corrupted class, for example.

Rafael
[originally posted on jforum.net by Rafael Steil]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yes, I have done two completly independent tar-copy-untar runs ... on my old server everything works fine, on the new it keeps throwing this exception ...

Hmm ... strange ... ok, i guess i will try to delete all files (except for the config files) and reinstall the forum with a freshly downloaded version sometime this weekend, but somehow i doubt this will help ...

I'll keep you posted if i find out what the reason is/was ...

Greets,
Alex
[originally posted on jforum.net by Anonymous]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi!

Tried to install a completly fresh version (2.1.5), but even when trying to access the first page (/install/install.page?module=install&action=welcome) again the same error occurs:

javax.servlet.ServletException
org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:290)
org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:161)
org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:114)
(...)

Root cause:

java.lang.NoClassDefFoundError
net.jforum.JForumBaseServlet.init(JForumBaseServlet.java:107)
net.jforum.InstallServlet.init(InstallServlet.java:73)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
java.lang.reflect.Method.invoke(Method.java:324)
org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:243)
java.security.AccessController.doPrivileged(Native Method)
javax.security.auth.Subject.doAsPrivileged(Subject.java:500)
org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:272)
(...)

--> I still dont get it ...

A.
[originally posted on jforum.net by urbus]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Daaamn.. is it your local machine, or a hosted server?

Rafael
[originally posted on jforum.net by Rafael Steil]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Its a remote server, but im hosting it (so im root).

But i think i got it, give me a few minutes :idea: ...

Looks like its really a security problem with tomcat.

A.

/edit: ok, it was. Migrating from tomcat4 to tomcat5 got us (apparently) some more restrictive policy-defaults, I had to add



to the tomcat-policy file.

Strange that I was the first one to have this problem, as we are using the default tomcat5-installation using securitymanager.

So you know at least the solution if someone else has this problem

Thanks anyway for your effort (and the forum ;)),
Greets,
Alex

[originally posted on jforum.net by urbus]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Great Alex!!

Rafael
[originally posted on jforum.net by Rafael Steil]
 
They worship nothing. They say it's because nothing lasts forever. Like this tiny ad:
Free, earth friendly heat - from the CodeRanch trailboss
https://www.kickstarter.com/projects/paulwheaton/free-heat
reply
    Bookmark Topic Watch Topic
  • New Topic