File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

java.security.AccessControlException

 
Meet Gaurav
Ranch Hand
Posts: 492
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi ALL,

I have a query REG: java.policy File

I developed a java bean that will download a file from the application server to client machine. Some time back the code works fine and now am getting java.security.AccessControlException: access denied (java.net.SocketPermission 202.55555.0.44:7022 connect,resolve)

I started googling and I got some replys saying that some permissions were missing in java.policy File.
Could some one please assist me to resolve this issue.

Thanks in advance
 
Ulf Dittmer
Rancher
Pie
Posts: 42966
73
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What kind of environment does this code run in? There must be a SecurityManager involved that enforces a policy. The first step would be to find out which policy that is, and whether it's possible to change it.
 
Meet Gaurav
Ranch Hand
Posts: 492
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Ulf Dittmer,

Oracle forms were calling the Java bean using VBean Class. And the Java bean is downloading the files from application server
 
Ulf Dittmer
Rancher
Pie
Posts: 42966
73
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
OK, so there's an application server. You need to find out which security policy it uses; maybe the system administrator can help with that.
 
Meet Gaurav
Ranch Hand
Posts: 492
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
But the same file from the same client machine can be able to access through browser. But Java bean is failing(AccessControlException )

Also I just checked with DBA team and system Admin. They were helpless to me
 
Meet Gaurav
Ranch Hand
Posts: 492
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Any suggestions please
 
Ulf Dittmer
Rancher
Pie
Posts: 42966
73
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm unsure now if this is a client problem or a server problem?

Whatever JVM is the origin of this problem is running under a SecurityManager. Most likely that is set as a parameter at JVM startup. So you need to find out which command is used to start the JVM. If the sys admin can't do that, then nobody can, which I think is unlikely.

If it really is happening in the app server, check its documentation for references to security managers and security policies.
 
Rob Spoor
Sheriff
Pie
Posts: 20372
44
Chrome Eclipse IDE Java Windows
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Meet Gaurav wrote:Any suggestions please

I can remember saying to you that Patience Is A Virtue.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic