1

I'm trying to setup a dokuwiki in Vagrant for demonstration purposes, and I'd like the people testing it out to be able to register and receive a verification email.

I've installed the dokuwiki-plugin-smtp and I'd like to be able to use an SMTP server with it.

I've found several places that state that gmail is good for this purpose, but I don't have a domain to send mail from as such.

Here's what I have done so far:

  1. Went into my Admin settings for doku
  2. Clicked Configuration Settings
  3. Clicked smtp
  4. In the Smtp section...and filled in the following values:
    1. Your outgoing SMTP server: smtp.gmail.com
    2. The port your SMTP server listens on. Usually 25. 465 for SSL: 465
    3. What kind of encryption is used when communicating with your SMTP Server? SSL
    4. If authentication is required, put your username here. <my-gmail-email-address>
    5. Password for the above user. <my-gmail-email-address-password>
    6. The name to be used during HELO phase of SMTP. Should be the FQDN of the webserver DokuWiki is running on. Leave empty for autodetection. Not sure what to put here.
    7. Print a full error log when sending fails? Disable when everything works! Checked.
    8. Clicked Save.
  5. Went into <doku-home>/conf/dokuwiki.php and edited $conf['mailfrom'] so that it points to <my-gmail-email-address>.
  6. Went back to the Admin screen in my browser..
    1. Clicked Check SMTP configuration
    2. In the testmail dialog tried to send an email to another email address using the To: field.
    3. Clicked Send Mail

The following was the output:

Set: the server
Set: the auth
Set: a message will be sent
Connecting to smtp.gmail.com at 465
Got: 220 smtp.gmail.com ESMTP p206sm2da861897ywb.29 - gsmtp
Sent: EHLO [192.168.33.10]
Got: 250-smtp.gmail.com at your service, [207.255.6.224]
Got: 250-SIZE 35882577
Got: 250-8BITMIME
Got: 250-AUTH LOGIN PLAIN XOAUTH2 PLAIN-CLIENTTOKEN OAUTHBEARER XOAUTH
Got: 250-ENHANCEDSTATUSCODES
Got: 250-PIPELINING
Got: 250-CHUNKING
Got: 250 SMTPUTF8
Sent: AUTH LOGIN
Got: 334 VXNlcm5shbWU6
Sent: bGVlYW5kMDBdAZ21haWwuY29t
Got: 334 UGFzc3dvdcmQ6
Sent: dmlzaipMNzMhJkNWNVk=
Got: 534-5.7.14 <https://accounts.google.com/ContinueSignIn?sarp=1&scc=1&plt=AKgnsdbvEf
Got: 534-5.7.14 xM8arKaU-YecG1GrUg1rUPPs6tdYNskmkjoyqwKryYWkCxW9PNKXHd6vt0yKIoauYjo1FLW
Got: 534-5.7.14 8aoPuega-taL5QSUdj03t5HpLNJ2vFEd_GIbBAvQo39Wi6Hpd3irkM3xV9sbVyyB7rCYMbs
Got: 534-5.7.14 OL8zl-onlXEiLP6f8J6FJFlF13Y1qmiNMiX7iJixQZJ_K8bs9docaAABH78hRSSGyiAGqZr
Got: 534-5.7.14 LX6UABKLBKdOddNqiyOHE16U3CVk> Please log in via your web browser and
Got: 534-5.7.14 then try again.
Got: 534-5.7.14  Learn more at
Got: 534 5.7.14  https://support.google.com/mail/answer/78754 p206sm2861897ywb.29 - gsmtp

The visiting the URL mentioned at the end https://support.google.com/mail/answer/78754 p206sm2861897ywb.29 yields no results.

I've also tried this configuration using a port setting in The port your SMTP server listens on. Usually 25. 465 for SSL of 587 and a setting for What kind of encryption is used when communicating with your SMTP Server? of 587 and I still can't send the email.

I got my settings for this here.

I keep thinking the issue might be where it asks for the The name to be used during HELO phase of SMTP. Should be the FQDN of the webserver DokuWiki is running on. Leave empty for autodetection but I'm not entirely certain of that.

Is there anything else that might allow the email to be sent? I'd even settle for a different plugin or a different mailserver. I'm setting this up for testing and demonstration purposes only.

3

First of all you should not have posted the full log above. It contains your gmail username and password! So the very first thing to do is to change your gmail password.

Now to work on your problem:

  1. If you are using 2factor auth, you will need to create an application password and use that to authenticate.
  2. You will need to enable "insecure" apps as described at https://support.google.com/a/answer/6260879?hl=en (otherwise gmail will only allow access via their API but not via SMTP
  • I messed up the log before posting it. – leeand00 Feb 10 '16 at 17:35
  • Oh and thank you for authoring the plugin as well as answering my question! – leeand00 Feb 10 '16 at 17:42
  • Cheers mate! Have a beer on me! – leeand00 Feb 10 '16 at 18:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.