Class: Net::SMTP::AuthXoauth2

Inherits:
Authenticator show all
Defined in:
lib/net/smtp/auth_xoauth2.rb

Instance Attribute Summary

Attributes inherited from Authenticator

#smtp

Instance Method Summary collapse

Methods inherited from Authenticator

auth_class, auth_classes, auth_type, #base64_encode, check_args, #continue, #finish, #initialize

Constructor Details

This class inherits a constructor from Net::SMTP::Authenticator

Instance Method Details

#auth(user, secret) ⇒ Object



5
6
7
8
9
# File 'lib/net/smtp/auth_xoauth2.rb', line 5

def auth(user, secret)
  token = xoauth2_string(user, secret)

  finish("AUTH XOAUTH2 #{base64_encode(token)}")
end