9front - general discussion about 9front
 help / color / mirror / Atom feed
* fqa8: sending email with gmail
@ 2019-12-18 17:03 telephil9
  2019-12-18 17:29 ` [9front] " Ori Bernstein
  0 siblings, 1 reply; 4+ messages in thread
From: telephil9 @ 2019-12-18 17:03 UTC (permalink / raw)
  To: 9front

[-- Attachment #1: Type: text/plain, Size: 155 bytes --]

Hi,

Attached is a patch to fqa8 that documents sending mail with gmail.
Thanks to Ori_B and kvik for helping me with the issues I had.

Regards,
Philippe

[-- Attachment #2.1: Type: text/plain, Size: 337 bytes --]

from postmaster@hades:
The following attachment had content that we can't
prove to be harmless.  To avoid possible automatic
execution, we changed the content headers.
The original header was:

	Content-Disposition: attachment; filename=fqa8-send-gmail.patch
	Content-Type: text/plain; charset="US-ASCII"
	Content-Transfer-Encoding: 7bit

[-- Attachment #2.2: fqa8-send-gmail.patch.suspect --]
[-- Type: application/octet-stream, Size: 1611 bytes --]

diff -r c259787f7f92 fqa8.ms
--- a/fqa8.ms	Wed Dec 04 21:18:36 2019 -0500
+++ b/fqa8.ms	Wed Dec 18 12:47:41 2019 +0100
@@ -891,6 +891,67 @@
 .B Note:
 Opening large mailboxes over a slow 9p link will be very slow.
 
+.html - <a name="8.4.1.1.2" />
+.ihtml h5 <h5>
+.SH
+8.4.1.1.2 - Sending mail with gmail
+.R
+.ihtml h5
+
+Add your gmail password to the factotum:
+.P1
+echo 'key proto=pass server=smtp.gmail.com service=smtp \e
+	user=your.username@gmail.com !password=yourpassword' >/mnt/factotum/ctl
+.P2
+
+Configure upas to use gmail as a gateway for outgoing email:
+.P1
+cat /mail/lib/rewrite.gateway >> /mail/lib/rewrite
+.P2
+
+Modify /mail/lib/remotemail to use your gmail account:
+.P1
+#!/bin/rc
+shift
+sender=your.username@gmail.com
+shift
+addr=tcp!smtp.gmail.com!587
+shift
+fd=`{/bin/upas/aliasmail -f $sender}
+switch($fd){
+case *.*
+	;
+case *
+	fd=gmail.com
+}
+exec /bin/upas/smtp -u your.username@gmail.com -a -h $fd $addr $sender $*
+.P2
+
+Now you can try sending an email:
+.P1
+echo hello | mail -s test your.username@gmail.com
+.P2
+
+This will not work the first time as we also need to add a certificate.
+Look into /sys/log/smtp for the following error:
+.P1
+cert for smtp.gmail.com not recognized:
+	sha256=wnu7Uuzq4MlyJHP90+8f2smoh6x3cj0dG5z02jJlX42
+.P2
+
+Add the certificate to your system:
+.P1
+echo 'x509 sha256=wnu7Uuzq4MlyJHP90+8f2smoh6x3cj0dG5z02jJlX42' \e
+	>> /sys/lib/tls/smtp
+.P2
+
+You should now be able to send emails from 9front!
+
+.B Note:
+This configuration does not work for local email delivery.
+
+
+
 .html - <a name="8.4.1.2" />
 .ihtml h4 <h4>
 .SH

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2019-12-19  3:17 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-12-18 17:03 fqa8: sending email with gmail telephil9
2019-12-18 17:29 ` [9front] " Ori Bernstein
2019-12-18 19:28   ` telephil9
2019-12-19  3:17     ` sl

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).