I have a test Unsigned Midlet that simply does Socket Connections(SecureConnection) to a site, like that
sc = (SecureConnection)Connector.open(sslwww.myserver.com443);
Using this from my handset, i am getting the following exception
java.lang.SecurityException Untrusted MIDlet attempted to connect to a restricted port
When i am connecting using HttpsConnection instead of SecureConnection like
httpsConn = (HttpsConnection)Connector.open( httpswww.myserver.com443path);
i have no problems. From this i have some questions.
(1)why is this happening???
(2)Can i be sure that to all handsets i am going to install my application the HttpsConnection
method is going to work in all cases???
(3)When i will try to make httpsConn = (HttpsConnection)Connector.open( httpswww.myserver.com555path);
aka ssl connection in port 555, i won't face any problems? (the server of course is configured to 555 port)
Does the handset Network layer(and kvm) will initiate the connection from the handset to server port 555 correctly
or there will be a mistake and my handset will try to connect to server's port 443 instead of 555???
Thanks in Advance