MyNetTCPTable is a postfix tcp_table service to get mynetworks from LDAP.
As ldap_table does not allow matching network range, MyNetTCPTable responds to this by querying ipNetwork objects in LDAP and working with CIDR Format.
.gitignore | ||
go.mod | ||
go.sum | ||
LICENSE | ||
mynettcptable.conf.sample | ||
mynettcptable.go | ||
README.md |
MyNetTCPTable
MyNetTCPTable is a tcp_table service for postfix to allow matching networks from LDAP.
ldap_table does not allow to match network range, so you have to set all IPs in LDAP to use it.
MyNetTCPTable cover this use case, allowing you to put ipNetwork objects into LDAP in CIDR form and match unicast IP sent by postfix to these networks.
Usage
get 1.2.3.4
200 1.2.3.4
logging
MyNetTCPTable logs to stdout, with level info by default. Level can be changed with '-logLevel' switch. See usage for allowed values.
Logging to syslog can be enabled with '-logTo syslog' argument. Logs will be written to LOG_MAIL facility.
Note that enabling syslog won't disable stdout output.
Additionnal commands
Get current log level:
get loglevel
200 info
Set log level:
set loglevel debug
200 loglevel%20set
Refresh network cache:
set refresh
200 Refreshing%20cache