Hack Forums
[Java] Java Applet socket connection - Printable Version

+- Hack Forums (https://hackforums.net)
+-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444)
+--- Forum: Coding (https://hackforums.net/forumdisplay.php?fid=151)
+---- Forum: Software Development (https://hackforums.net/forumdisplay.php?fid=118)
+---- Thread: [Java] Java Applet socket connection (/showthread.php?tid=4653856)



Java Applet socket connection - mariusz79132 - Jan 25, 2015

Hey.
I have huge problem with java Applet.
I got small server based game and need to use sockets.
When i connect in debuger- it work fine.
But when i copy .class files and use :
Quote:<applet code="gra/logowanie.java" width="700" height="700">
asd
</applet>
it freeze in browser and in logs:
network: cache entry not found localhost:8205/crossdomain.xml

I searched all over the internet and tryed everything, still no answer.
If someone know how to fix it plx share.


* - MrOrang - Jan 25, 2015

Uh it's connecting to localhost, try changing localhost to the address of the server?


* - mariusz79132 - Jan 25, 2015

Its connecting.
Normally it connect and work, but with using browser it send get for crossdomain, and server side is getting this/
Server log:
Oczekiwanie na komende id:0
Code
Odebrana komenda:GET /crossdomain.xml HTTP/1.1
Koniec petli programu
Oczekiwanie na komende id:0
Odebrana komenda:User-Agent: Mozilla/4.0 (Windows Server 2012 6.2) Java/1.8.0_25
Koniec petli programu
Oczekiwanie na komende id:0
Odebrana komenda:Host: 127.0.0.1:8205
Koniec petli programu
Oczekiwanie na komende id:0
Odebrana komenda:Accept: text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2
Koniec petli programu
Oczekiwanie na komende id:0
Odebrana komenda:Connection: keep-alive
Koniec petli programu
Oczekiwanie na komende id:0
Odebrana komenda:
Koniec petli programu
Oczekiwanie na komende id:0
Reset polaczenia
Oczekiwanie na klienta na porcie 8205...
Połączony z /127.0.0.1:58657
Oczekiwanie na komende id:0
Odebrana komenda:GET /crossdomain.xml HTTP/1.1
Koniec petli programu
Oczekiwanie na komende id:0
Odebrana komenda:User-Agent: Mozilla/4.0 (Windows Server 2012 6.2) Java/1.8.0_25
Koniec petli programu
Oczekiwanie na komende id:0
Odebrana komenda:Host: 127.0.0.1:8205
Koniec petli programu
Oczekiwanie na komende id:0
Odebrana komenda:Accept: text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2
Koniec petli programu
Oczekiwanie na komende id:0
Odebrana komenda:Connection: keep-alive
Koniec petli programu
Oczekiwanie na komende id:0
Odebrana komenda:
Koniec petli programu
Oczekiwanie na komende id:0



* - mariusz79132 - Jan 26, 2015

Ref.
Exept socket connection i got "/crossdomain.xml HTTP/1.1" in applets in browser.


* - jimbell1954 - Jul 12, 2016

How do i get your product?