Puppet Class: sendmail::mc::privacy_flags

Defined in:
manifests/mc/privacy_flags.pp

Summary

Manage privacy flags for the Sendmail MTA

Overview

Each option is enabled by setting the associated boolean parameter to ‘true`. See the Sendmail documentation for the meaning of the flags.

Examples:

Enable two specific privacy flags

class { 'sendmail::mc::privacy_flags':
  goaway => true,
  noetrn => true,
}

Parameters:

  • authwarnings (Boolean) (defaults to: false)

    Whether the privacy option of the same name should be enabled. Valid options: ‘true` or `false`.

  • goaway (Boolean) (defaults to: false)

    Whether the privacy option of the same name should be enabled. Valid options: ‘true` or `false`.

  • needexpnhelo (Boolean) (defaults to: false)

    Whether the privacy option of the same name should be enabled. Valid options: ‘true` or `false`.

  • needmailhelo (Boolean) (defaults to: false)

    Whether the privacy option of the same name should be enabled. Valid options: ‘true` or `false`.

  • needvrfyhelo (Boolean) (defaults to: false)

    Whether the privacy option of the same name should be enabled. Valid options: ‘true` or `false`.

  • noactualrecipient (Boolean) (defaults to: false)

    Whether the privacy option of the same name should be enabled. Valid options: ‘true` or `false`.

  • nobodyreturn (Boolean) (defaults to: false)

    Whether the privacy option of the same name should be enabled. Valid options: ‘true` or `false`.

  • noetrn (Boolean) (defaults to: false)

    Whether the privacy option of the same name should be enabled. Valid options: ‘true` or `false`.

  • noexpn (Boolean) (defaults to: false)

    Whether the privacy option of the same name should be enabled. Valid options: ‘true` or `false`.

  • noreceipts (Boolean) (defaults to: false)

    Whether the privacy option of the same name should be enabled. Valid options: ‘true` or `false`.

  • noverb (Boolean) (defaults to: false)

    Whether the privacy option of the same name should be enabled. Valid options: ‘true` or `false`.

  • novrfy (Boolean) (defaults to: false)

    Whether the privacy option of the same name should be enabled. Valid options: ‘true` or `false`.

  • public (Boolean) (defaults to: false)

    Whether the privacy option of the same name should be enabled. Valid options: ‘true` or `false`.

  • restrictexpand (Boolean) (defaults to: false)

    Whether the privacy option of the same name should be enabled. Valid options: ‘true` or `false`.

  • restrictmailq (Boolean) (defaults to: false)

    Whether the privacy option of the same name should be enabled. Valid options: ‘true` or `false`.

  • restrictqrun (Boolean) (defaults to: false)

    Whether the privacy option of the same name should be enabled. Valid options: ‘true` or `false`.



61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
# File 'manifests/mc/privacy_flags.pp', line 61

class sendmail::mc::privacy_flags (
  Boolean $authwarnings      = false,
  Boolean $goaway            = false,
  Boolean $needexpnhelo      = false,
  Boolean $needmailhelo      = false,
  Boolean $needvrfyhelo      = false,
  Boolean $noactualrecipient = false,
  Boolean $nobodyreturn      = false,
  Boolean $noetrn            = false,
  Boolean $noexpn            = false,
  Boolean $noreceipts        = false,
  Boolean $noverb            = false,
  Boolean $novrfy            = false,
  Boolean $public            = false,
  Boolean $restrictexpand    = false,
  Boolean $restrictmailq     = false,
  Boolean $restrictqrun      = false,
) {
  $flags = [
    bool2str($authwarnings,      'authwarnings',      ''),
    bool2str($goaway,            'goaway',            ''),
    bool2str($needexpnhelo,      'needexpnhelo',      ''),
    bool2str($needmailhelo,      'needmailhelo',      ''),
    bool2str($needvrfyhelo,      'needvrfyhelo',      ''),
    bool2str($noactualrecipient, 'noactualrecipient', ''),
    bool2str($nobodyreturn,      'nobodyreturn',      ''),
    bool2str($noetrn,            'noetrn',            ''),
    bool2str($noexpn,            'noexpn',            ''),
    bool2str($noreceipts,        'noreceipts',        ''),
    bool2str($noverb,            'noverb',            ''),
    bool2str($novrfy,            'novrfy',            ''),
    bool2str($public,            'public',            ''),
    bool2str($restrictexpand,    'restrictexpand',    ''),
    bool2str($restrictmailq,     'restrictmailq',     ''),
    bool2str($restrictqrun,      'restrictqrun',      ''),
  ]

  # Remove empty flags
  $real_flags = filter($flags) |$f| { !empty($f) }

  sendmail::mc::define { 'confPRIVACY_FLAGS':
    expansion => join($real_flags, ','),
  }
}