Mercurial Hosting > luan
comparison src/goodjava/mail/Smtp.java @ 1765:1ffe1e06ea55
SSL for port 465
| author | Franklin Schmidt <fschmidt@gmail.com> |
|---|---|
| date | Fri, 26 May 2023 10:29:55 -0600 |
| parents | e34b73678a4f |
| children | 0eb615de1f80 |
comparison
equal
deleted
inserted
replaced
| 1764:527c53b91a50 | 1765:1ffe1e06ea55 |
|---|---|
| 22 this.reader = new InputStreamReader(socket.getInputStream()); | 22 this.reader = new InputStreamReader(socket.getInputStream()); |
| 23 this.writer = new OutputStreamWriter(socket.getOutputStream()); | 23 this.writer = new OutputStreamWriter(socket.getOutputStream()); |
| 24 String s = read(); | 24 String s = read(); |
| 25 if( !s.startsWith("220") ) | 25 if( !s.startsWith("220") ) |
| 26 throw new MailException(s); | 26 throw new MailException(s); |
| 27 write( "EHLO\r\n" ); | 27 write( "EHLO whatever\r\n" ); |
| 28 ehlo = read(); | 28 ehlo = read(); |
| 29 if( !ehlo.startsWith("250") ) | 29 if( !ehlo.startsWith("250") ) |
| 30 throw new MailException(ehlo); | 30 throw new MailException(ehlo); |
| 31 } | 31 } |
| 32 | 32 |
