From: www-data Date: Thu, 11 Dec 2014 18:26:08 +0000 (+0100) Subject: Now uses localhost to send e-mail. X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=commitdiff_plain;h=f112367aa0e512029a31da94828d6c9a3bc0b99e;p=logicplayer.git Now uses localhost to send e-mail. --- diff --git a/server/com/company/DirectoryWatcher.class b/server/com/company/DirectoryWatcher.class deleted file mode 100644 index a1666c7..0000000 Binary files a/server/com/company/DirectoryWatcher.class and /dev/null differ diff --git a/server/com/company/EmailSender.class b/server/com/company/EmailSender.class deleted file mode 100644 index 8c301a8..0000000 Binary files a/server/com/company/EmailSender.class and /dev/null differ diff --git a/server/com/company/EmailSender.java b/server/com/company/EmailSender.java index 1abf701..d21d437 100644 --- a/server/com/company/EmailSender.java +++ b/server/com/company/EmailSender.java @@ -42,20 +42,20 @@ public class EmailSender { // Metodo che si occupa dell'invio effettivo della mail public void inviaEmail() { - int port = 465; //porta 25 per non usare SSL + int port = 25; //porta 465 per usare SSL Properties props = new Properties(); - props.put("mail.smtp.auth", "true"); + props.put("mail.smtp.auth", "false"); /* true to autenticate */ props.put("mail.smtp.user", mittente); props.put("mail.smtp.host", host); props.put("mail.smtp.port", port); // commentare la riga seguente per non usare SSL - props.put("mail.smtp.starttls.enable","true"); + //props.put("mail.smtp.starttls.enable","true"); props.put("mail.smtp.socketFactory.port", port); // commentare la riga seguente per non usare SSL - props.put("mail.smtp.socketFactory.class", "javax.net.ssl.SSLSocketFactory"); + //props.put("mail.smtp.socketFactory.class", "javax.net.ssl.SSLSocketFactory"); props.put("mail.smtp.socketFactory.fallback", "false"); Session session = Session.getInstance(props, null); @@ -91,10 +91,12 @@ public class EmailSender { // inserimento delle parti nel messaggio msg.setContent(multipart); - Transport transport = session.getTransport("smtps"); //("smtp") per non usare SSL + /*CSC: this code was for handling SMTP authentication + Transport transport = session.getTransport("smtp"); //("smtps") per usare SSL transport.connect(host, user, password); transport.sendMessage(msg, msg.getAllRecipients()); - transport.close(); + transport.close();*/ + Transport.send(msg, msg.getAllRecipients()); System.out.println("Invio dell'email Terminato"); diff --git a/server/com/company/EsNameParser.class b/server/com/company/EsNameParser.class deleted file mode 100644 index 1820ff1..0000000 Binary files a/server/com/company/EsNameParser.class and /dev/null differ diff --git a/server/com/company/MD5.class b/server/com/company/MD5.class deleted file mode 100644 index 75dca3a..0000000 Binary files a/server/com/company/MD5.class and /dev/null differ diff --git a/server/com/company/dbConnect.class b/server/com/company/dbConnect.class deleted file mode 100644 index fcf7b0e..0000000 Binary files a/server/com/company/dbConnect.class and /dev/null differ diff --git a/server/com/company/dbConnect.java b/server/com/company/dbConnect.java index c89c18e..309a979 100644 --- a/server/com/company/dbConnect.java +++ b/server/com/company/dbConnect.java @@ -93,7 +93,7 @@ public class dbConnect { EmailSender email = new EmailSender(global.emailConstant.email, global.emailConstant.emailPass, - "smtp.gmail.com", + global.emailConstant.smtpName, global.emailConstant.email, user, "OGGETTO: recupero password LogicPlayer", diff --git a/server/com/company/global$dbConstant.class b/server/com/company/global$dbConstant.class deleted file mode 100644 index 6581574..0000000 Binary files a/server/com/company/global$dbConstant.class and /dev/null differ diff --git a/server/com/company/global$emailConstant.class b/server/com/company/global$emailConstant.class deleted file mode 100644 index 7bc2a14..0000000 Binary files a/server/com/company/global$emailConstant.class and /dev/null differ diff --git a/server/com/company/global.class b/server/com/company/global.class deleted file mode 100644 index d4b2ef3..0000000 Binary files a/server/com/company/global.class and /dev/null differ diff --git a/server/com/company/global.java b/server/com/company/global.java index 7c82d27..134ab62 100644 --- a/server/com/company/global.java +++ b/server/com/company/global.java @@ -17,9 +17,11 @@ public class global { public static class emailConstant { - public static String email = "confermaiscrizioneserver@gmail.com"; + //public static String email = "confermaiscrizioneserver@gmail.com"; + public static String email = "registration@logicplayer.helm.cs.unibo.it"; public static String emailPass = "tes6phev8n"; - public static String smtpName= "smtp.gmail.com"; + //public static String smtpName= "smtp.gmail.com"; + public static String smtpName= "localhost"; } public static class dbConstant{ diff --git a/server/com/company/guestServer.class b/server/com/company/guestServer.class deleted file mode 100644 index be83056..0000000 Binary files a/server/com/company/guestServer.class and /dev/null differ diff --git a/server/com/company/httpget$MyHandler.class b/server/com/company/httpget$MyHandler.class deleted file mode 100644 index f0f55e0..0000000 Binary files a/server/com/company/httpget$MyHandler.class and /dev/null differ diff --git a/server/com/company/httpget.class b/server/com/company/httpget.class deleted file mode 100644 index 2a7e0fb..0000000 Binary files a/server/com/company/httpget.class and /dev/null differ diff --git a/server/com/company/personalServer.class b/server/com/company/personalServer.class deleted file mode 100644 index baf83c9..0000000 Binary files a/server/com/company/personalServer.class and /dev/null differ diff --git a/server/com/company/suString.class b/server/com/company/suString.class deleted file mode 100644 index 6d094cb..0000000 Binary files a/server/com/company/suString.class and /dev/null differ diff --git a/server/com/company/superServer.class b/server/com/company/superServer.class deleted file mode 100644 index cb978cc..0000000 Binary files a/server/com/company/superServer.class and /dev/null differ diff --git a/server/com/company/xmlOperation.class b/server/com/company/xmlOperation.class deleted file mode 100644 index 15f4a2d..0000000 Binary files a/server/com/company/xmlOperation.class and /dev/null differ