United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
JDK-5019401 : ServerSocket(Proxy) and Socket(Proxy) do not work with sun one proxy server

Details
Type:
Bug
Submit Date:
2004-03-24
Status:
Resolved
Updated Date:
2004-10-13
Project Name:
JDK
Resolved Date:
2004-04-06
Component:
core-libs
OS:
solaris_8,generic
Sub-Component:
java.net
CPU:
sparc,unknown,generic
Priority:
P2
Resolution:
Fixed
Affected Versions:
1.0,1.4.2_06,5.0
Fixed Versions:
1.4.2_07 (b01)

Related Reports
Backport:
Duplicate:
Duplicate:

Sub Tasks

Description
The new feature of creating ServerSockets and Sockets by specifying the proxy server does not work with the sun one proxy server. When trying to bind to a local port or during Socket.connect(), a SocketException is thrown. The feature works when tried against a reference socks5 proxy server downloaded from www.socks.nec.com.

STEPS TO REPRODUCE THE PROBLEM:
1. Copy the attached files into the same directory.
2. Compile the java file using source 1.5
3. Setup a sun one proxy server (version 3.6) on a machine. Currently, the server has been setup on xanadu.india.sun.com. Give full permissions to the socks proxy server (see attached socks5.conf file)
4. Edit the proxy.properties and replace xanadu.india.sun.com with the name of the proxy server. Currently the server on xanadu is running but may be brought down in the future.
5. Run the code. The code fails with an exception. The stack trace is present in the attached file output.txt.


CURRENT BEHAVIOUR:
Code throws an exception during ServerSocket.bind() and Socket.connect() calls


EXPECTED BEHAVIOUR:
The client and server communication takes place successfully and the tests pass.

                                    

Comments
PUBLIC COMMENTS

 
                                     
2004-10-02
CONVERTED DATA

BugTraq+ Release Management Values

COMMIT TO FIX:
1.4.2_07
tiger-beta2

FIXED IN:
1.4.2_07
tiger-beta2

INTEGRATED IN:
1.4.2_07
tiger-b46
tiger-beta2

VERIFIED IN:
tiger-beta2


                                     
2004-10-02
WORK AROUND

 
                                     
2004-10-02
SUGGESTED FIX

 
                                     
2004-10-02
EVALUATION

It seems that S1 proxy server can't deal with fragmented packets even though this is supposed to be on top of TCP.
We need to change the code to make sure that our SOCKS implementation sends the SOCKS commands (CONNECT, BIND, etc..) in an atomic way (i.e.: a single write per command).
Will try to fix for tiger-beta2 as this is a rather simple a low risk fix.

###@###.### 2004-03-24
                                     
2004-03-24



Hardware and Software, Engineered to Work Together