Class: Fortifier::NotifierMailer

Inherits:
ActionMailer::Base
  • Object
show all
Defined in:
app/mailers/fortifier/notifier_mailer.rb

Instance Method Summary collapse

Instance Method Details

#account_ip_blocked(auth_user, remote_addr, account) ⇒ Object



40
41
42
43
44
45
46
47
# File 'app/mailers/fortifier/notifier_mailer.rb', line 40

def (auth_user, remote_addr, )
  @auth_user = auth_user
  @remote_addr = remote_addr
  @account =  #hash
  mail(
    :to => Rails.env.development? ? $system_mail_recipients : [:email],
    :subject => "IP block")
end

#account_ip_blocked_providigm(auth_user, remote_addr, account) ⇒ Object



49
50
51
52
53
54
55
56
57
# File 'app/mailers/fortifier/notifier_mailer.rb', line 49

def (auth_user, remote_addr, )
  @auth_user = auth_user
  @remote_addr = remote_addr
  @account =  #hash
  recipients = $system_mail_recipients + %w([email protected])
  mail(
    :to =>  Rails.env.development? ? $system_mail_recipients : recipients,
    :subject => "IP block - #{[:organization] || [:name]} - #{remote_addr}")
end

#exception_notification(controller, request, exception) ⇒ Object



22
23
24
25
26
27
28
29
30
# File 'app/mailers/fortifier/notifier_mailer.rb', line 22

def exception_notification(controller,request,exception)
  @request = request
  @controller = controller
  @exception = exception
  mail(
    :to => "[email protected]",
    :from => "[email protected]",
    :subject => "Error discovered in: #{@request.env["HTTP_HOST"]}")
end

#foreign_access(auth_user, auth_log) ⇒ Object



7
8
9
10
11
12
13
# File 'app/mailers/fortifier/notifier_mailer.rb', line 7

def foreign_access(auth_user, auth_log)
  @auth_user = auth_user
  @auth_log = auth_log
  mail(
    :to => "[email protected]",
    :subject => "Foreign IP access attempt on: #{host_uri}")
end

#password_expiration(password_model, email) ⇒ Object



15
16
17
18
19
20
# File 'app/mailers/fortifier/notifier_mailer.rb', line 15

def password_expiration(password_model, email)
  @pw_expiration_date = password_model.expiration_date
  mail(
    :to => Rails.env.development? ? $system_mail_recipients : email,
    :subject => "Password Expiration")
end

#task_exception(exception) ⇒ Object



32
33
34
35
36
37
38
# File 'app/mailers/fortifier/notifier_mailer.rb', line 32

def task_exception(exception)
  @exception = exception
  mail(
    :to => "[email protected]",
    :from => "[email protected]",
    :subject => "Error discovered in: #{host_uri}")
end