summaryrefslogtreecommitdiff
path: root/app/views/admin/application_settings/_spam.html.haml
blob: 58543a0359a67dd402f0bcd297fefb6917f9c21e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
= form_for @application_setting, url: admin_application_settings_path, html: { class: 'fieldset-form' } do |f|
  = form_errors(@application_setting)

  %fieldset
    .form-group.row
      .offset-sm-2.col-sm-10
        .form-check
          = f.label :recaptcha_enabled do
            = f.check_box :recaptcha_enabled
            Enable reCAPTCHA
          %span.form-text.text-muted#recaptcha_help_block Helps prevent bots from creating accounts

    .form-group.row
      = f.label :recaptcha_site_key, 'reCAPTCHA Site Key', class: 'col-form-label col-sm-2'
      .col-sm-10
        = f.text_field :recaptcha_site_key, class: 'form-control'
        .form-text.text-muted
          Generate site and private keys at
          %a{ href: 'http://www.google.com/recaptcha', target: 'blank' } http://www.google.com/recaptcha

    .form-group.row
      = f.label :recaptcha_private_key, 'reCAPTCHA Private Key', class: 'col-form-label col-sm-2'
      .col-sm-10
        = f.text_field :recaptcha_private_key, class: 'form-control'

    .form-group.row
      .offset-sm-2.col-sm-10
        .form-check
          = f.label :akismet_enabled do
            = f.check_box :akismet_enabled
            Enable Akismet
          %span.form-text.text-muted#akismet_help_block Helps prevent bots from creating issues

    .form-group.row
      = f.label :akismet_api_key, 'Akismet API Key', class: 'col-form-label col-sm-2'
      .col-sm-10
        = f.text_field :akismet_api_key, class: 'form-control'
        .form-text.text-muted
          Generate API key at
          %a{ href: 'http://www.akismet.com', target: 'blank' } http://www.akismet.com

    .form-group.row
      .offset-sm-2.col-sm-10
        .form-check
          = f.label :unique_ips_limit_enabled do
            = f.check_box :unique_ips_limit_enabled
            Limit sign in from multiple ips
          %span.form-text.text-muted#unique_ip_help_block
            Helps prevent malicious users hide their activity

    .form-group.row
      = f.label :unique_ips_limit_per_user, 'IPs per user', class: 'col-form-label col-sm-2'
      .col-sm-10
        = f.number_field :unique_ips_limit_per_user, class: 'form-control'
        .form-text.text-muted
          Maximum number of unique IPs per user

    .form-group.row
      = f.label :unique_ips_limit_time_window, 'IP expiration time', class: 'col-form-label col-sm-2'
      .col-sm-10
        = f.number_field :unique_ips_limit_time_window, class: 'form-control'
        .form-text.text-muted
          How many seconds an IP will be counted towards the limit

  = f.submit 'Save changes', class: "btn btn-success"