2
I Use This!
Activity Not Available

News

Analyzed 4 months ago. based on code collected 11 months ago.
Posted over 14 years ago by [email protected] (Cprogrammer)
Quite a few of users who attempt to install IndiMail first time, face the biggest issue with MySQL installation and configuration. Most of the issues relate to the followingMySQL version less than 5.1: MySQL fails to startup under supervise MySQL ... [More] version less than 5.1: svctool fails to create a default database for IndiMail during rpm installation./etc/my.cnf uses socket=/var/lib/mysql/mysql.sock. IndiMail uses /tmp/mysql.sock. Connection to MySQL fails if you use mysql(1) (without -S opton).You get MySQL syntax error when running indimail programsThe solution to the first problem is to delete the lines --general-log-file and the line --slow-query-log from the file /service/mysql.3306/run. After deleting the lines you can issue the command/var/indimail/bin/svc -u /service/mysql.3306to start up MySQL.The solution to the second problem is to create a blank MySQL database by running the following command/var/indimail/bin/svc -d /service/mysql.3306/bin/rm -r /var/indimail/mysqldb/data/usr/bin/mysql_install_db --user=mysql --datadir=/var/indimail/mysqldb/datachown -R mysql:mysql /var/indimail/mysqldb/data/var/indimail/bin/svc -u /service/mysql.3306mysql -u root -pmysql> use mysql;mysql> update user set password=PASSWORD('some_pass') where user='root';mysql> CREATE USER indimail identified by 'ssh-1.5-';mysql> CREATE USER mysql identified by '4-57343-';mysql> CREATE USER admin identified by 'benhur20';mysql> CREATE USER repl identified by 'slaveserver';mysql> GRANT SELECT,CREATE,ALTER,INDEX,INSERT,UPDATE,DELETE, \mysql> CREATE TEMPORARY TABLES, \mysql> LOCK TABLES ON indimail.* to 'indimail';mysql> GRANT RELOAD,SHUTDOWN,PROCESS,SUPER on *.* to admin;mysql> GRANT REPLICATION SLAVE on *.* to repl;The third problem can be solved by replacing socket=/var/lib/mysql/mysql.sock with socket=/tmp/mysql.sock in /etc/my.cnf or equivalent file. You can also copy /var/indimail/etc/indimail.cnf as .indimail.cnf in your home directory. i.e.cp /var/indimail/etc/indimail.cnf $HOME/.indimail.cnfTo avoid the above problems, it is recommended to use one of the below MySQL versionsmysql-6.0.3-alphamysql-6.0.9-alphamysql-5.0.26mysql-5.0.77mysql-5.1.40mysql-5.4.3-betamysql-5.5.0-m2MariaDB 5.1.42Let me know if you are using any version of MySQL other than the above. Run the following command to get the MySQL version% mysql_config --versionThe fourth problem relates to a workaround made in IndiMail to prevent MySQL injection. What is needed is to set NO_BACKSLASH_ESCAPES in the MySQL server. You can use either of the two methods belowThis SQL mode also can be enabled automatically when the server starts by using the command-line option`--sql-mode=NO_BACKSLASH_ESCAPES' or by settingSet `sql-mode=NO_BACKSLASH_ESCAPES' in the server option file (forexample, `my.cnf' or `my.ini', depending on your system). [Less]
Posted over 14 years ago by [email protected] (Cprogrammer)
IndiMail is Free Software / Open Source SoftwareWhat would it have costed to code IndiMail if it wasn't free and if there wasn't any FS/OSS ?Using David A. Wheeler's 'SLOCCount' gives the following result. The cost has been arrived by using ... [More] $12000/year as the average salary of an Indian programmer. Sloccount uses COCOMO Software Cost Estimation Model.Total Estimated Cost to Develop = $ 3,011,907SLOC Directory SLOC-by-Language (Sorted)106466 clamav-0.95.2 ansic=94967,sh=11300,perl=19973173 qmail-1.03 ansic=68645,perl=2361,sh=216758207 indimail-1.6.2 ansic=51563,sh=664445914 indium-1.0 tcl=39628,sh=5604,ansic=68241943 bogofilter-1.2.1 ansic=34807,sh=4629,perl=1842,lex=475,lisp=17914670 flash-0.9.4 ansic=8346,sh=63249762 ucspi-tcp-0.88 ansic=9581,sh=1819362 altermime-0.3.10 ansic=5963,sh=33999317 mpack-1.6 ansic=9292,perl=258131 ripmime-1.4.0.9 ansic=8116,sh=154256 pam-multi-1.0 ansic=3053,sh=12033318 libdkim-1.3 cpp=2316,ansic=924,sh=781833 nssd-1.0 ansic=18331772 fortune-1.1 ansic=1698,sh=74Totals grouped by language (dominant language first):ansic: 299470 (77.16%)sh: 41618 (10.72%)tcl: 39628 (10.21%)perl: 4427 (1.14%)cpp: 2316 (0.60%)lex: 475 (0.12%)lisp: 179 (0.05%)Total Physical Source Lines of Code (SLOC) = 388,124Development Effort Estimate, Person-Years (Person-Months) = 104.58 (1,254.96)(Basic COCOMO model, Person-Months = 2.4 * (KSLOC**1.05))Schedule Estimate, Years (Months) = 3.14 (37.62)(Basic COCOMO model, Months = 2.5 * (person-months**0.38))Estimated Average Number of Developers (Effort/Schedule) = 33.36Total Estimated Cost to Develop = $ 3,011,907(average salary = $12,000/year, overhead = 2.40)."generated using David A. Wheeler's 'SLOCCount'." [Less]
Posted over 14 years ago by [email protected] (Cprogrammer)
Greylisting is a method of defending email users against spam, by temporarily rejecting any email from a IP/Sender which it does not recognize. As per SMTP, the originating server should after a delay retry. A server implementing greylisting should ... [More] accept the mail if sufficient time has elapsed. If the mail is from a spammer it will probably not be retried since a spammer goes through thousands of email addresses and typically cannot afford the time delay to retry.IndiMail 1.6 onwards implements greylisting using qmail-greyd daemon. You additionally need to have the environment variable GREYIP defined for the qmail-smtpd process. The environment variable GREYIP specifies on which IP and port, qmail-greyd is accepting greylisting requests. qmail-smtpd uses UDP to send a triplet (IP+RETURN_PATH+RECIPIENT) to the greylisting server and waits for an answer which tells qmail-smtpd to proceed ahead or to temporarily reject the mail. qmail-greyd also accepts a list of whitelisted IP addresses for which greylisting should not be done.1. Enabling qmail-greyd greylisting server % su # svctool --greylist=1999 --servicedir=/service --min-resend-min=2 \ --resend-win-hr=24 --timeout-days=30 --context-file=greylist.context \ --save-interval=5 --whitelist=greylist.whitelist --use-greydaemon2. Enabling greylisting in SMTPAssuming you've setup your qmail-smtpd service with tcpserver and the -x option (as in LWQ), you just need to update the cdb file referenced by this -x option. The source for this file is typically /var/indimail/etc/tcp.smtp. For example,127.:allow,RELAYCLIENT=""192.168.:allow,RELAYCLIENT="":allowcould become,127.:allow,RELAYCLIENT=""192.168.:allow,RELAYCLIENT="":allow,GREYIP=":"If you've setup qmail-greyd on a non-default address (perhaps you're running qmail-greyd on a separate machine), you'll also need to specify the address it's listening on - adjust the above to include GREYIP="192.168.5.5:", for example.Finally, don't forget to update the cdb file corresponding to the source file you've just edited. If you have a LWQ setup that's,# qmailctl cdb otherwise (assuming /var/indimail/etc/tcp.smtp, /var/indimail/etc/tcp.smtp.cdb),# tcprules /var/indimail/etc/tcp.smtp.cdb /var/indimail/etc/tcp.smtp.tmp < /var/indimail/etc/tcp.smtpAlternatively (and particularly if you're not using the -x option to tcpserver) you can enable greylisting for all SMTP connections by setting GREYIP in the environment in which qmail-smtpd is started - for example your variables directory for qmail-smtpd can contain a file with the name GREYIP# echo GREYIP=\":\" > /service/qmail-smtpd.25/variables/GREYIP [Less]