-
Notifications
You must be signed in to change notification settings - Fork 13
/
config.go
52 lines (46 loc) · 2.13 KB
/
config.go
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
package snmp
import (
"github.com/circonus-labs/circonus-unified-agent/internal"
)
// type ClientConfig struct {
// // Timeout to wait for a response.
// Timeout internal.Duration `toml:"timeout"`
// Retries int `toml:"retries"`
// // Values: 1, 2, 3
// Version uint8 `toml:"version"`
// // Parameters for Version 1 & 2
// Community string `toml:"community"`
// // Parameters for Version 2 & 3
// MaxRepetitions uint32 `toml:"max_repetitions"`
// // Parameters for Version 3
// ContextName string `toml:"context_name"`
// // Values: "noAuthNoPriv", "authNoPriv", "authPriv"
// SecLevel string `toml:"sec_level"`
// SecName string `toml:"sec_name"`
// // Values: "MD5", "SHA", "". Default: ""
// AuthProtocol string `toml:"auth_protocol"`
// AuthPassword string `toml:"auth_password"`
// // Values: "DES", "AES", "". Default: ""
// PrivProtocol string `toml:"priv_protocol"`
// PrivPassword string `toml:"priv_password"`
// EngineID string `toml:"-"`
// EngineBoots uint32 `toml:"-"`
// EngineTime uint32 `toml:"-"`
// }
type ClientConfig struct {
AuthProtocol string `toml:"auth_protocol"` // Values: "MD5", "SHA", "". Default: ""
AuthPassword string `toml:"auth_password"`
PrivProtocol string `toml:"priv_protocol"` // Values: "DES", "AES", "". Default: ""
PrivPassword string `toml:"priv_password"`
EngineID string `toml:"-"`
Community string `toml:"community"` // Parameters for Version 1 & 2
ContextName string `toml:"context_name"` // Parameters for Version 3
SecLevel string `toml:"sec_level"` // Values: "noAuthNoPriv", "authNoPriv", "authPriv"
SecName string `toml:"sec_name"`
Timeout internal.Duration `toml:"timeout"` // Timeout to wait for a response.
Retries int `toml:"retries"`
MaxRepetitions uint32 `toml:"max_repetitions"` // Parameters for Version 2 & 3
EngineBoots uint32 `toml:"-"`
EngineTime uint32 `toml:"-"`
Version uint8 `toml:"version"` // Values: 1, 2, 3
}