man gsgsmtpd (Administration système) - Alamin GSM SMS Gateway SMTP interface

NAME

gsgsmtpd - Alamin GSM SMS Gateway SMTP interface

SYNOPSIS

gsgsmtpd [--version|--help]

gsgsmtpd [--configfile config_file_name] [--debug|--nodebug] [--verbose|--noverbose] [--copyright|--nocopyright] [--pidfile pid_file] [--accounting accounting_file_name] [--syslog facility|--nosyslog] [--spool spool_directory] [--smtpport port_number] [--smtptosmsformat field_list] [--alias alias_file_name] [--maxaliasnestinglevel number] [--defallowserv default_allowed_services_list] [--usersfile users_file_name]

DESCRIPTION

gsgsmtpd is the gateway smtp interface. It receives connections from the ip network using the simple mail transfer protocol (smtp) and saves messages in their queue.

OPTIONS

--configfile <file_name>
(default: /etc/alamin/gsgc.conf) Sets the config file to be used. The configfile option is not valid inside a config file (to redirect into another config file). You can put any number of times an option inside the config file, but only the latest is used. Use only lowercase letters. Options specified in the command line have preference over options listed inside a config file.
--debug
--nodebug
(default: --debug) You can turn debugging on or off. Just use debug to see all messages in the log.
--verbose
--noverbose
(default: --verbose) Set this option if you want to see messages about usual events in the log.
--copyright
--nocopyright
(default: --nocopyright) If you set this option, copyright messages will be show every time Alamin starts.
--pidfile <pid_file>
(default: /var/run/alamin/gsgsmtpd.pid) File to save the pid of the proccess. This option can only be used as a command line option, not inside the config file.
--accounting <accounting_file_with_complete_path>
(default: /var/log/alamin/gsgd-accounting.log) Accounting file, where every attempt to send or receive a message is logged. You can use it to generate usage reports per user, computer, phone...
--syslog <facility_name>
--nosyslog
(default: local4) Syslog facility to log messages, or nosyslog to avoid using syslog.
--spool <spool_directory>
(default: /var/spool/alamin) Directory structure path where messages are waiting to be sent.
--smtpport <tcp_port_number|tcp_service_name>
(default: smtp, or 25 if smtp does not exist in /etc/services) Port where the gateway server is listening for connections using smtp. If this port is less or equal to 1024, you need to run this script as a privileged user. This is not recommended. Use a tcp redirector like redir if you need really the smtp port (25), or use a port greater than 1024 and redirects your smtp connections to that port from the computers you send messages to the gateway using smtp.
--smtptosmsformat <field_list>
(default: __FROM__#__SUBJECT__#__BODY__) This is the format of the sms that will be sent from a smtp mail message. The only message fields used are From, Subject and the body of the message. You must use the strings __FROM__, __SUBJECT__ and __BODY__ to decide where to put each one.
--allowip <list_of_ips_from_where_we_accept_connections>
(default: all) You can set here a list of ip addresses from where you accept connections. The special word all allows all ips. If the special word all is used, then you can deny some ips with the --denyip option. Remote ip is matched from the beginning, so, 192.168. represents the range from 192.168.0.0 to 192.168.255.255. The list is space separated.
--denyip <list_of_ips_from_where_we_not_accept_connec.>
(default: none) You can set here a list of ip addresses from where you do not accept connections. The special word none denies all ips. This option is used only if the --allowip option has the value all. Remote ip is matched from the beginning, so, 192.168. represents the range from 192.168.0.0 to 192.168.255.255. The list is space separated.
--alias <alias_file>
(default: /etc/alamin/alias.conf) This is the name of the file that has a list of alias to be used for phone numbers. You can send messages to myphonenumber if an entry exists in the alias file associating myphonenumber with your real phone number. The alias file is a list of lines with words, where the first word is changed by the rest of the words at the time gsgcmd queues the message, so a message can be sent to a lot of phones at a time, if more than one word follows the first word of a line. You can use one or more alias inside other alias. The level of nested alias allowed is defined in the maxaliasnestinglevel option. See example alias.conf file for examples. Alias can be used as groups of phones.
--maxaliasnestinglevel <level>
(default: 4) Max number of times an alias can be inside other alias thas is inside other alias that is inside other alias that ... You know. Increasing this level you increment the time is needed to decide what numbers are inside an alias if you use nesting of aliases (groups of groups). I think 4 is a good start. Change it to 1 if you do not use alias inside other alias (groups of groups).
--defallowserv <default_allowed_service_list>
(default: send_all) List of comma separated services from the following list: all_services, none, send_all, send_qx (x between 1 and 9), system_down, query_queue, retry_all, retry_qx (x between 1 and 9). Currently, query and retry options are not implemented. This list applies to anonymous connections. When a user is authenticated, he has its own allowed services list from the users file.
--usersfile <users_file_name>
(default: /etc/alamin/user.conf) This is the users file where Alamin keeps information about users names, passwords, email addresses, allowed services and so on. Its fields are separated by (:). The list of fileds is user:password:email:allowed_services_list:allowed_numbers_list. Email field can be blank. allowed_services_list is a comma separated list of the services valid to --defallowserv option. Allowed_numbers_list is a comma separated list of phone numbers that the user is allowed to send message to. The special words all and none can be used. A filename (fullpath is needed) can be used to search allowed phone numbers inside a file. YOU MUST KEEP THIS FILE WITH READ PRIVILEGE ONLY FOR alamin USER, as it contains passwords. See example file for examples. Default users and passwords are in the example file (root, operator and user). Users are authenticated from the client using a schema similar to CHAP. Passwords are not send in clear text over the network.

RETURN VALUE

0
successful.
1
syntax error, incorrect command line.
2
parameter lost.

FILES

/etc/alamin/gsgd.conf, gateway config file. /var/run/alamin/gsgsmtpd.pid, default pid file. /var/log/alamin/gsgd-accounting.log, def. accounting file. /var/spool/alamin, default spool directory. /etc/alamin/user.conf, default users file.

SEE ALSO

See also alamin(8), gsgc(1), gsgmdd(8) and gsgcmd(8)

BUGS

Send bugs to the author, please. I would like to keep the program without bugs.

LICENSE

Alamin GSM SMS Gateway Copyright (C) Andres Seco Hernandez and others.

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

AUTHOR

Andres Seco Hernandez <AndresSH@alamin.org>.