NetPermission


NetPermission java.net

Java 1.2 serializable permission

This class is a java.security.Permission that represents various permissions required for Java's URL-based networking system. See also SocketPermission , which represents permissions to perform lower-level networking operations. A NetPermission is defined solely by its name ; no actions list is required or supported. As of Java 1.2, there are three NetPermission targets defined: "setDefaultAuthenticator" is required to call Authenticator.setDefault( ) ; "requestPasswordAuthentication" to call Authenticator.requestPasswordAuthentication( ) ; and "specifyStreamHandler" to explicitly pass a URLStreamHandler object to the URL( ) constructor. The target "*" is a wildcard that represents all defined NetPermission targets.

System administrators configuring security policies must be familiar with this class and the permissions it represents. System programmers may use this class, but application programmers never need to use it explicitly.

Figure 12-13. java.net.NetPermission

 public final class  NetPermission  extends java.security.BasicPermission {  // Public Constructors  public  NetPermission  (String  name  );        public  NetPermission  (String  name  , String  actions  );   } 



Java In A Nutshell
Java In A Nutshell, 5th Edition
ISBN: 0596007736
EAN: 2147483647
Year: 2004
Pages: 1220

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net