< prev index next >

test/java/net/SocketPermission/SocketPermissionTest.java

Print this page
rev 17324 : 8181761: add explicit @build actions for jdk.test.lib classes in all :tier2 tests
Reviewed-by: duke
rev 17325 : imported patch 8181761-1


   9  * This code is distributed in the hope that it will be useful, but WITHOUT
  10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12  * version 2 for more details (a copy is included in the LICENSE file that
  13  * accompanied this code).
  14  *
  15  * You should have received a copy of the GNU General Public License version
  16  * 2 along with this work; if not, write to the Free Software Foundation,
  17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18  *
  19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  */
  23 
  24 /*
  25  * @test
  26  * @bug 8047031
  27  * @summary SocketPermission tests for legacy socket types
  28  * @library /test/lib


  29  * @run testng/othervm SocketPermissionTest
  30  */
  31 
  32 import java.io.IOException;
  33 import java.net.DatagramPacket;
  34 import java.net.DatagramSocket;
  35 import java.net.InetAddress;
  36 import java.net.MulticastSocket;
  37 import java.net.NetworkInterface;
  38 import java.net.ServerSocket;
  39 import java.net.Socket;
  40 import java.net.SocketPermission;
  41 import java.security.AccessControlContext;
  42 import java.security.AccessController;
  43 import java.security.CodeSource;
  44 import java.security.Permission;
  45 import java.security.PermissionCollection;
  46 import java.security.Permissions;
  47 import java.security.Policy;
  48 import java.security.PrivilegedExceptionAction;




   9  * This code is distributed in the hope that it will be useful, but WITHOUT
  10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12  * version 2 for more details (a copy is included in the LICENSE file that
  13  * accompanied this code).
  14  *
  15  * You should have received a copy of the GNU General Public License version
  16  * 2 along with this work; if not, write to the Free Software Foundation,
  17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18  *
  19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  */
  23 
  24 /*
  25  * @test
  26  * @bug 8047031
  27  * @summary SocketPermission tests for legacy socket types
  28  * @library /test/lib
  29  * @build jdk.test.lib.NetworkConfiguration
  30  *        jdk.test.lib.Platform
  31  * @run testng/othervm SocketPermissionTest
  32  */
  33 
  34 import java.io.IOException;
  35 import java.net.DatagramPacket;
  36 import java.net.DatagramSocket;
  37 import java.net.InetAddress;
  38 import java.net.MulticastSocket;
  39 import java.net.NetworkInterface;
  40 import java.net.ServerSocket;
  41 import java.net.Socket;
  42 import java.net.SocketPermission;
  43 import java.security.AccessControlContext;
  44 import java.security.AccessController;
  45 import java.security.CodeSource;
  46 import java.security.Permission;
  47 import java.security.PermissionCollection;
  48 import java.security.Permissions;
  49 import java.security.Policy;
  50 import java.security.PrivilegedExceptionAction;


< prev index next >