});
SSLSocketFactory sslComunicationSocketFactory = (SSLSocketFactory) SSLSocketFactory.getDefault();
SSLSocket sslComunicationSocket = (SSLSocket) sslComunicationSocketFactory.createSocket(Constants.MASTER_SERVER_ADDRESS, 9998);
Communicate communicate = new Communicate(sslComunicationSocket);
communicate.receiveAndSend("200, Thank you bastard");
communicate.receiveAndSend("205");
updateComposite.getDisplay().syncExec(new Runnable() {
public void run() {
primeriMessageLabel.setText("Verificando validade da sua licen�a...");
}
});
String receive = communicate.receive();
if (receive.equals("403")) {
GDSystem system = GDSystem.getInstance();
GD gd = GD.getInstance();
communicate.sendObject(new Autentication((String) gd.get("username"), (String) gd.get("password"), (String) gd.get("serialnumber") ));
if(communicate.receive().equals("404")) {
Vader vader = (Vader) communicate.receiveObject();
system.execute(new AddDarkSide(vader));
updateComposite.getDisplay().syncExec(new Runnable() {
public void run() {
primeriMessageLabel.setText("Licen�a valida, reiniciando...");