1 /* 2 * Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * This code is free software; you can redistribute it and/or modify it 6 * under the terms of the GNU General Public License version 2 only, as 7 * published by the Free Software Foundation. Oracle designates this 8 * particular file as subject to the "Classpath" exception as provided 9 * by Oracle in the LICENSE file that accompanied this code. 10 * 11 * This code is distributed in the hope that it will be useful, but WITHOUT 12 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 13 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 14 * version 2 for more details (a copy is included in the LICENSE file that 15 * accompanied this code). 16 * 17 * You should have received a copy of the GNU General Public License version 18 * 2 along with this work; if not, write to the Free Software Foundation, 19 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 20 * 21 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 22 * or visit www.oracle.com if you need additional information or have any 23 * questions. 24 */ 25 26 package java.net; 27 28 import android.compat.annotation.UnsupportedAppUsage; 29 30 @SuppressWarnings({"unchecked", "deprecation", "all"}) 31 class SocksSocketImpl extends java.net.PlainSocketImpl implements java.net.SocksConsts { 32 33 @UnsupportedAppUsage SocksSocketImpl()34 SocksSocketImpl() { 35 throw new RuntimeException("Stub!"); 36 } 37 SocksSocketImpl(java.lang.String server, int port)38 SocksSocketImpl(java.lang.String server, int port) { 39 throw new RuntimeException("Stub!"); 40 } 41 SocksSocketImpl(java.net.Proxy proxy)42 SocksSocketImpl(java.net.Proxy proxy) { 43 throw new RuntimeException("Stub!"); 44 } 45 setV4()46 void setV4() { 47 throw new RuntimeException("Stub!"); 48 } 49 privilegedConnect(java.lang.String host, int port, int timeout)50 private synchronized void privilegedConnect(java.lang.String host, int port, int timeout) 51 throws java.io.IOException { 52 throw new RuntimeException("Stub!"); 53 } 54 superConnectServer(java.lang.String host, int port, int timeout)55 private void superConnectServer(java.lang.String host, int port, int timeout) 56 throws java.io.IOException { 57 throw new RuntimeException("Stub!"); 58 } 59 remainingMillis(long deadlineMillis)60 private static int remainingMillis(long deadlineMillis) throws java.io.IOException { 61 throw new RuntimeException("Stub!"); 62 } 63 readSocksReply(java.io.InputStream in, byte[] data)64 private int readSocksReply(java.io.InputStream in, byte[] data) throws java.io.IOException { 65 throw new RuntimeException("Stub!"); 66 } 67 readSocksReply(java.io.InputStream in, byte[] data, long deadlineMillis)68 private int readSocksReply(java.io.InputStream in, byte[] data, long deadlineMillis) 69 throws java.io.IOException { 70 throw new RuntimeException("Stub!"); 71 } 72 authenticate( byte method, java.io.InputStream in, java.io.BufferedOutputStream out)73 private boolean authenticate( 74 byte method, java.io.InputStream in, java.io.BufferedOutputStream out) 75 throws java.io.IOException { 76 throw new RuntimeException("Stub!"); 77 } 78 authenticate( byte method, java.io.InputStream in, java.io.BufferedOutputStream out, long deadlineMillis)79 private boolean authenticate( 80 byte method, 81 java.io.InputStream in, 82 java.io.BufferedOutputStream out, 83 long deadlineMillis) 84 throws java.io.IOException { 85 throw new RuntimeException("Stub!"); 86 } 87 connectV4( java.io.InputStream in, java.io.OutputStream out, java.net.InetSocketAddress endpoint, long deadlineMillis)88 private void connectV4( 89 java.io.InputStream in, 90 java.io.OutputStream out, 91 java.net.InetSocketAddress endpoint, 92 long deadlineMillis) 93 throws java.io.IOException { 94 throw new RuntimeException("Stub!"); 95 } 96 connect(java.net.SocketAddress endpoint, int timeout)97 protected void connect(java.net.SocketAddress endpoint, int timeout) 98 throws java.io.IOException { 99 throw new RuntimeException("Stub!"); 100 } 101 getInetAddress()102 protected java.net.InetAddress getInetAddress() { 103 throw new RuntimeException("Stub!"); 104 } 105 getPort()106 protected int getPort() { 107 throw new RuntimeException("Stub!"); 108 } 109 getLocalPort()110 protected int getLocalPort() { 111 throw new RuntimeException("Stub!"); 112 } 113 close()114 protected void close() throws java.io.IOException { 115 throw new RuntimeException("Stub!"); 116 } 117 getUserName()118 private java.lang.String getUserName() { 119 throw new RuntimeException("Stub!"); 120 } 121 122 private boolean applicationSetProxy; 123 124 private java.io.InputStream cmdIn; 125 126 private java.io.OutputStream cmdOut; 127 128 private java.net.Socket cmdsock; 129 130 private java.net.InetSocketAddress external_address; 131 132 private java.lang.String server; 133 134 private int serverPort = 1080; // 0x438 135 136 private boolean useV4 = false; 137 } 138