File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Developer Certification (SCJD/OCMJD) and the fly likes security manager Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Java Interview Guide this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Certification » Developer Certification (SCJD/OCMJD)
Bookmark "security manager" Watch "security manager" New topic

security manager

serge rousseff

Joined: Apr 15, 2002
Posts: 5
When a security manager is added to a Swing program :
"System.setSecurityManager(new SecurityManager());"
and the program is run again a "status bar" appears at the bottom of the frame mentioning
"Java Applet Window".
Even when displaying dialogs, tooltips, ... that status bar is added.
This makes a mess of the GUI
Can this be suppressed (and how) ? (I am working in JDK 1.4)
Any tip greatly appreciated
Peter den Haan
Ranch Hand

Joined: Apr 20, 2000
Posts: 3252
Grant permission java.awt.AWTPermission "showWindowWithoutWarningBanner". I supplied the following policy for my client:The permissions are needed, respectively,
  • To suppress the applet window warning banner;
  • To allow the client to connect to the server;
  • To allow it to open a local database file;
  • To get Swing working reliably on Windows NT -- not sure why, I had to figure this out the hard way.
  • In my documentation I pointed out that the policy can be tightened up considerably when more is known about the production environment.
    Note that unless you download RMI stubs from the server, you don't strictly need a policy file for either client or server.
    - Peter
    I agree. Here's the link:
    subject: security manager
    It's not a secret anymore!