Sendmail 8.12.8h + Berkeley DB 4.1.25 ÄÄÆÄÀÏ ¸Þ´º¾ó (Ver 1.0)


Official distribution site : http://jkkang.net/
Technical Info : jkkang65@hanmail.net

Last Updated in July 7th, 2003
Written by Kang Jul Ki



   º» ¹®¼­´Â AIX 4.3.3 ȯ°æ¿¡¼­ Sendmail 8.12.8h ¹öÀüÀ» ÄÄÆÄÀÏÇؼ­ ¼³Ä¡ÇÏ´Â ¹æ¹ýÀ» ¼³¸íÇϱâ À§Çؼ­ ¸¸µé¾îÁ³´Ù. Sendmail 8.12.8hÀº ±âÁ¸ÀÇ sendmail 8.12.8 ¹öÀü¿¡¼­ ÇѱÛÁ¦¸ñ ½ºÆÔ¸ÞÀÏ ÇÊÅ͸µÀ» À§Çؼ­ ¼Ò½ºÄÚµåÀÇ ÀϺκÐÀ» ¼öÁ¤À» ÇϽŠ¼­»ó¿ë ¹Ú»ç´ÔÀÇ sendmail 8.12.hh ¹öÀüÀ» Åä´ë·Î ¾²¿©Á³´Ù. ÇѱÛÁ¦¸ñ ½ºÆÔ¸ÞÀÏ ÇÊÅ͸µÀ» À§Çؼ­ ¼Ò½ºÄڵ带 ¼öÁ¤ÇØÁֽŠ¼­»ó¿ë¹Ú»ç´Ô²² °¨»çµå¸³´Ï´Ù.

S/WVersionºñ°í
IBM AIX4.3.3ML #9 or higher
Sendmail8.12.8hDownload
GNU gcc2.95.3or higher
GNU make3.79.1or higher
GNU groff1.11.1
GNU m41.4¹Ýµå½Ã GNU m4¸¦ ÄÄÆÄÀÏ/¼³Ä¡Çؼ­ »ç¿ëÇϱ⠹ٶõ´Ù.
AIX¿¡ ±âº»ÀûÀ¸·Î ±ò·ÁÀÖ´Â m4¸¦ »ç¿ëÇÏ°Ô µÇ¸é Parsing ¿¡·¯°¡ ¹ß»ýÇÑ´Ù.


   À§ ÆÄÀÏÁß¿¡¼­ Sendmail 8.12.8hÀº ´ç¿¬È÷ ¼Ò½ºÄڵ带 ´Ù¿î·ÎµåÇؼ­ ÄÄÆÄÀÏÀ» ÇÒ °ÍÀÌ°í, GNU m4´Â www.bullfreeware.com¿¡¼­ binary ¹öÀüÀ» ±¸ÇÒ¼ö ¾øÀ¸¹Ç·Î, ¼Ò½ºÄڵ带 ´Ù¿î·Îµå ¹Þ¾Æ¼­ ÄÄÆÄÀÏÀ» Çؾ߸¸ ÇÑ´Ù. ±×¿Ü¿¡ gcc, make, groff´Â À§ À¥½ÎÀÌÆ®¿¡¼­ ¹ÙÀ̳ʸ® ÆÄÀÏÀ» ´Ù¿î·Îµå ¹Þ¾Æ¼­ ÄÄÆÄÀÏÀÌ¾Æ´Ñ ÀνºÅçÀ» ÇØÁÖ¸é µÈ´Ù. C ÄÄÆÄÀÏ·¯´Â ²À GNU gcc¸¦ »ç¿ëÇϵµ·Ï ÇÏÀÚ.


1. Sendmail ÇѱÛÆÐÄ¡ÃֽŹöÀü


  2003/03/14 8.12.8h ¹öÀü (¾à 1.8 MB)



2. ÄÄÆÄÀÏ ¹× ¼³Ä¡È¯°æ


OS´Â AIX 4.3.3 & ML #10,
C ÄÄÆÄÀÏ·¯´Â GNU gcc 2.95.3,
Make´Â GNU make 3.79.1,
GNU groff,
GNU m4 (AIX ¿¡¼­ Á¦°øÇØÁÖ´Â m4´Â sendmailÀÇ .mc ÆÄÀÏÀ» ÀνÄÇÒ¶§ ¹®Á¦°¡ ÀÖ¾ú´Ù. ±×·¡¼­ ÇÊÀÚ´Â GNU m4¸¦ ¼³Ä¡ÇÏ¿© ÀÌ ¹®Á¦¸¦ ÇØ°áÇÏ¿´´Ù. ÀÌ ¹®Á¦´Â sendmailÀÇ ¸Þ´º¾ó ÆÄÀÏ¿¡µµ ¾ð±ÞÀÌ µÇ¾î ÀÖ´Ù.)

À§ÀÇ ÅøµéÀº ²À ÇÊ¿äÇϹǷΠ¹Ì¸® ¼³Ä¡Åä·Ï ÇÏÀÚ. ±×¸®°í ´ÙÀ½°ú °°ÀÌ È¯°æº¯¼ö¸¦ ¼³Á¤Çؼ­ ÄÄÆÄÀÏÀ» Çϵµ·Ï ÇÏÀÚ. ¸¸¾à¿¡ kshÀ» »ç¿ëÇÑ´Ù¸é .profileÀÇ
PATH=/usr/local/bin:.............................
ÀÌ·±½ÄÀ¸·Î /usr/local/binÀ» °¡Àå ¾Õ¿¡ ÁÖ¸é µÉ°ÍÀÌ´Ù.

mail :/> which gcc
/usr/local/bin/gcc

mail :/> which make
/usr/local/bin/make

mail :/> which groff
/usr/local/bin/groff

mail :/> which m4
/usr/local/bin/m4

mail :/> id
uid=0(root) gid=0(system)



3. Berkeley DB 4.1.25 ÄÄÆÄÀÏ ¹× ¼³Ä¡ (root·Î ¼³Ä¡)


  sendmail ÇÁ·Î±×·¥Àº DB °ü¸®¸¦ Berkeley DB¸¦ »ç¿ëÇÏ¿© °ü¸®ÇÒ ¼ö°¡ ÀÖ´Ù. µû¶ó¼­, Berkeley DB»ç¿ëÇÏ°íÀÚ ÇÑ´Ù¸é, sendmailÀÇ ÀνºÅç ÀÌÀü¿¡ ÄÄÆÄÀÏÇؼ­ ¼³Ä¡¸¦ ÇØÁà¾ß ÇÑ´Ù. Berkeley DB¸¦ °ø½ÄÀûÀ¸·Î ¹èÆ÷ÇÏ´Â À¥½ÎÀÌÆ®´Â http://www.sleepycat.com/ ÀÌ°í, ÀÌ´Â Open Source·Î¼­ ´©±¸³ª ÀÚÀ¯·Ó°Ô »ç¿ëÀÌ °¡´ÉÇÏ´Ù. 2003³â 3¿ù 9ÀÏ ÇöÀç ÃֽŹöÀüÀº 4.1.25 ¹öÀüÀÌ´Ù. ÇÊÀÚ´Â AIX 4.3.3¿¡¼­ 4.1.24 ¹öÀüÀ» »ç¿ëÇؼ­ sendmailÀÇ ÄÄÆÄÀÏÀ» ½ÃµµÇÏ¿´À¸³ª, db->open() ÇÔ¼öÀÇ ÀÎÀÚÀÇ °¹¼ö°¡ ÀÏÄ¡ÇÏÁö ¾Ê´Â ¹®Á¦·Î ÀÎÇؼ­ ½ÇÆÐÇÏ¿´´Ù. ÀÌ ¹®Á¦´Â news group ¿¡¼­µµ ±× »ç·Ê°¡ ¿©·¯¹ø ¾ð±ÞÀÌ µÇ¾î ÀÖ¾ú´Ù. ±×·¡¼­ AIX 4.3.3¿¡¼­ ÄÄÆÄÀÏÇÒ¶§´Â Berkeley DB 3.3.11 ¹öÀüÀ» »ç¿ëÇßÁö¸¸, 4.1.25 ¹öÀü¿¡¼­´Â ÀÌ ºÎºÐÀÌ ´ÙÇེ·´°Ôµµ Àß ÇØ°áÀÌ µÈµíÇؼ­ 4.1.25 ¹öÀüÀ» »ç¿ëÇؼ­ ÄÄÆÄÀÏÀ» ÇÏ¿´´Ù.

Download Site: http://www.sleepycat.com/download/patchlogs.shtml

mail:/down/Sendmail-8.12.8H> ls -l
total 8840
-rw-r--r--   1 root     sys      3056570 Mar 13 13:16 db-4.1.25.NC.tar.gz

mail:/down/Sendmail-8.12.8H> gzip -dc db-4.1.25.NC.tar.gz | tar xvf -
mail:/down/Sendmail-8.12.8H/db-4.1.25.NC>
mail:/down/Sendmail-8.12.8H/db-4.1.25.NC> more README
²¿¿À¿Á ¸Þ´º¾óÀº Àд½À°üÀ» °®ÀÚ.

mail:/down/Sendmail-8.12.8H/db-4.1.25.NC> cd dist
mail:/down/Sendmail-8.12.8H/db-4.1.25.NC/dist> ./configure CC=gcc

mail:/down/Sendmail-8.12.8H/db-4.1.25.NC/dist> make
mail:/down/Sendmail-8.12.8H/db-4.1.25.NC/dist> make install
mail:/down/Sendmail-8.12.8H/db-4.1.25.NC/dist> cd /usr/local
mail:/usr/local> ls -l
...
drwxr-xr-x   6 root     system       512 Mar 14 17:19 BerkeleyDB.4.1

...




4. sendmail µð·ºÅ丮ÀÇ º¸¾È°ü·Ã ÆÛ¹Ì¼Ç È®ÀÎ


mail:/> chmod go-w / /etc /etc/mail /usr /var /var/spool /var/spool/mqueue
chmod: /etc/mail: No such file or directory

mail:/> mkdir /etc/mail
mail:/> chmod go-w /etc/mail

mail :/> chown root / /etc /etc/mail /usr /var /var/spool /var/spool/mqueue

ÄÄÆÄÀÏÀ» ÇÏ°í, ÀνºÅçÀ» ¿Ï·áÇÑ ÈÄ¿¡ µð·ºÅ丮 ¼³Á¤ÀÌ Á¦´ë·Î µÇ¾î ÀÖ´ÂÁö È®ÀÎÇϱâ À§ÇÏ¿© ´ÙÀ½ÀÇ ¸í·É¾î¸¦ ½ÇÇà½ÃŲ´Ù.

# sendmail -v -bi

WARNING: writable directory /etc
WARNING: writable directory /var/spool/mqueue

¿Í °°Àº ¸Þ½ÃÁö¸¦ »Ñ·ÁÁÙ °ÍÀÌ´Ù. ±×·¯¸é, ´Ù½Ã Æ۹̼ÇÀ» È®ÀÎÇؼ­ ¿Ã¹Ù¸£°Ô ¼³Á¤À» Çϱ⸦ ¹Ù¶õ´Ù.




5. Sendmail 8.12.8h ¾ÐÃàÇ®±â


  Unix ¿¡¼­ ÇÁ·Î±×·¥À» ÄÄÆÄÀÏÇÒ¶§ °¡Àå Áß¿äÇÑ °ÍÀº ÄÄÆÄÀÏÀ» ÇϱâÀü¿¡ ²À README ÆÄÀÏÀ» ÀÐ¾î º¸´Â°ÍÀÌ´Ù. ´ëºÎºÐÀÇ »ç¿ëÀÚµéÀÌ ÀÌ°ÍÀÌ ±ÍÂú¾Æ¼­ °Ç³Ê¶Û·Á°í ÇÏÁö¸¸, ÀÌ°Ç Á¤¸» À߸øµÈ °ÍÀÌ´Ù. ²À Àо±â ¹Ù¶õ´Ù.

mail:/down/Sendmail-8.12.8H> ls -l
total 3880
-rw-r-----   1 root     sys        11365 Mar 18 12:51 README.sdp.m4
-rw-r-----   1 root     sys         8847 Mar 18 12:51 ckrelay
drwxr-xr-x  54 guest    usr         1024 Dec 19 11:06 db-4.1.25.NC
-rw-r-----   1 root     sys         9381 Mar 18 12:51 sdp.m4-1.12
-rw-r-----   1 root     sys         9911 Mar 18 12:51 sdp.m4-1.14
-rw-r-----   1 root     sys         9860 Mar 18 12:51 sdp.m4-1.25
-rw-r-----   1 root     sys         9055 Mar 18 12:51 sdp.m4-1.28
-rw-r-----   1 root     sys        17011 Mar 18 12:51 sendmail-8.12.8-H.patch
-rw-r-----   1 root     sys      1886792 Mar 18 12:52 sendmail-8.12.8-H.tar.gz

mail:/down/Sendmail-8.12.8H> gzip -dc sendmail-8.12.8-H.tar.gz | tar xvf -

mail:/down/Sendmail-8.12.8H> cd sendmail-8.12.8-H/sendmail
rskj:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/sendmail> more SECURITY (°­·ÂÈ÷ Àо°ÍÀ» ±Ç°í, Àбâ½ÈÀ¸¸é ÄÄÆÄÀÏ ±×¸¸ µÑ°Í...)

sendmail : a set-group-ID (default group: smmsp, recommended gid: 25) ·Î ¼³Á¤ÇÑ´Ù. ±×¸®°í ´ÙÀ½°ú °°ÀÌ chmod, chown À» °®°ÔµÈ´Ù.

-r-xr-sr-x      root   smmsp    ... /PATH/TO/sendmail
drwxrwx---      smmsp  smmsp    ... /var/spool/clientmqueue
drwx------      root   wheel    ... /var/spool/mqueue
-r--r--r--      root   wheel    ... /etc/mail/sendmail.cf
-r--r--r--      root   wheel    ... /etc/mail/submit.cf

[ÁÖÀÇ»çÇ×: ¸î¸î OS¿¡¼­´Â 'wheel' ÀÌ ¾ø´Â´ë½Å, bin, root °¡ ´ë½Å ¾²¿©µµ µÈ´Ù. ÀÌÁ¡Àº Áß¿äÄ¡ ¾Ê´Ù. µû¶ó¼­, AIX¿¡¼­µµ wheel ´ë½Å bin À» »ç¿ëÇÏ¿© groupÀ» ÁöÁ¤Çϵµ·Ï ÇÏÀÚ.] ±×¸®°í, sendmail µ¥¸óÀº root ·Î ½ÇÇàÀÌ µÇ¾î¾ß¸¸ ÇÑ´Ù.
# /usr/lib/sendmail -L sm-mta -bd -q1h
or
# /usr/sbin/sendmail -L sm-mta -bd -q1h

[ÁÖÀÇ»çÇ×: inetd ¸ðµå(ÁÁÀº ¹æ¹ýÀº ¾Æ´Ô)·Î sendmail À» µ¹¸°´Ù¸é, -bs ¿É¼Ç¿Ü¿¡ -Am ¿É¼ÇÀ» Áà¾ß¸¸ ÇÑ´Ù.]
¸ÞÀÏÀÌ queue¿¡ ¸¹ÀÌ ½×ÀÌ´Â °æ¿ì, crontab¿¡¼­ ´ÙÀ½°ú °°ÀÌ clean ½ÃÄÑÁÖ´Â°Ô ÁÁ´Ù.

/usr/lib/sendmail -L sm-msp-queue -Ac -q30m

@ Summary

* sendmail.cf (MTA: Mail Transmission agent)
* submit.cf (MSP : Mail Submission Program)

# /usr/lib/sendmail -L sm-msp-queue -Ac -q30m

mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/sendmail> vi README (°­·ÂÈ÷ Àо°ÍÀ» ±Ç°í, Àбâ½ÈÀ¸¸é ÄÄÆÄÀÏ ±×¸¸ µÑ°Í...)




6. Sendmail 8.12.8h ÄÄÆÄÀÏÇϱâ


  Unix ¿¡¼­ ÇÁ·Î±×·¥À» ÄÄÆÄÀÏÇÒ¶§ °¡Àå Áß¿äÇÑ °ÍÀº ÄÄÆÄÀÏÀ» ÇϱâÀü¿¡ ²À README ÆÄÀÏÀ» ÀÐ¾î º¸´Â°ÍÀÌ´Ù. ´ëºÎºÐÀÇ »ç¿ëÀÚµéÀÌ ÀÌ°ÍÀÌ ±ÍÂú¾Æ¼­ °Ç³Ê¶Û·Á°í ÇÏÁö¸¸, ÀÌ°Ç Á¤¸» À߸øµÈ °ÍÀÌ´Ù. ²À Àо±â ¹Ù¶õ´Ù.

@ GNU gcc¸¦ »ç¿ëÇÏ°íÀÚ ÇÒ¶§,

PATH¿¡ /usr/local/bin °æ·Î¸¦ ¹Ì¸® ¼³Á¤ÇصÎÀÚ.
rskj:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/sendmail> vi ../devtools/OS/AIX.4.3
...
gcc¸¦ ÄÄÆÄÀÏ·¯·Î »ç¿ëÇϵµ·Ï ÇϱâÀ§Çؼ­ ¾Æ·¡Ã³·³
define(`confCC', `/usr/bin/xlc') -> define(`confCC', `/usr/local/bin/gcc') ·Î °íÄ¡°í,

ÄÄÆÄÀϵµÁß ld: 0711-317 ERROR: Undefined symbol: .pthread_mutexattr_init °ü·Ã ¿¡·¯¸¦ ¾ø¾Ö±â À§Çؼ­
define(`confLIBS', `-ldbm') -> define(`confLIBS', `-ldbm -lpthread') ·Î °íÄ¡°í,

Berkeley DB.4.1¸¦ À§Çؼ­ ´ÙÀ½À» Ãß°¡ÇÏ°í, (¹°·Ð Berkeley DB 4.1´Â ´ÙÀ½ÀÇ µð·ºÅ丮¿¡ ¹Ì¸® ÀνºÅçÀÌ µÇ¾î ÀÖ¾î¾ß ÇÑ´Ù.)

APPENDDEF(`confINCDIRS', `-I/usr/local/BerkeleyDB.4.1/include')
APPENDDEF(`confLIBDIRS', `-L/usr/local/BerkeleyDB.4.1/lib')

-DPRT8BIT_OK ¿É¼ÇÀº # tail -f /var/adm/syslog ¿¡¼­ ÇÑ±Û ¸Þ½ÃÁö°¡ ±úÁö´Â°ÍÀ» Á¦´ë·Î º¸¿©ÁÖ´Â ¿ªÇÒÀ» ÇÑ´Ù. ÀÌ ±â´ÉÀº Sendmail-8.12.8h ¹öÀü¿¡¼­ Áö¿øÇÏ´Â ±â´ÉÀÌ´Ù. ´ÙÀ½ÁÙ ¾Æ·¡¿¡ ÀÖ´Â ¿É¼ÇÀº ÇѱÛÁ¦¸ñ¸ÞÀÏ ½ºÆÔÇÊÅ͸µÀ» À§ÇÑ ºÎºÐÀÌ´Ù.

APPENDDEF(`conf_sendmail_ENVDEF', `-DPRT8BIT_OK')
define(`confMAPDEF', `-DMAP_REGEX -DDNSMAP')

¸¦ Ãß°¡ÇÑ´Ù. ÀÌÁ¦´Â ´ÙÀ½°ú °°ÀÌ Build ÇÁ·Î±×·¥À» µ¹¸®±â ¹Ù¶õ´Ù.
mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/sendmail> sh Build -c -f ../devtools/OS/AIX.4.3

ÇÊÀÚ´Â GNU gcc¸¦ ¼±È£ÇÏ´Â ±î´ß¿¡ gcc ¿É¼ÇÀ» »ç¿ëÅä·Ï ¼±¾ðÀ» ÇØÁá´Ù. gcc¸¦ »ç¿ëÇϱâ À§Çؼ­´Â GNU makeµµ ¼³Ä¡µÇ¾î ÀÖ¾î¾ßÇÑ´Ù. ¿Ö³ÄÇϸé, GNU gcc´Â GNU makeÇÏ°í ±ÃÇÕÀÌ Àß ¸Â´Â´Ù.·áµÇ¾ú´Ù. ±× ¹Û¿¡ GNU groff, GNU m4 ÇÁ·Î±×·¥µµ ²À ¹Ì¸® ¼³Ä¡ÇØ µÖ¾ß¸¸ ÇÑ´Ù. ƯÈ÷ groff´Â ÇʼöÀûÀÌ´Ù. GNU m4µµ ifdef ÆĽÌÇÒ¶§ ¹®Á¦°¡ ¹ß°ßµÇ¾î ²À AIX m4°¡ ¾Æ´Ñ, GNU m4¸¦ /usr/local/bin ¿¡ ±ò¾Æ¼­ »ç¿ëÇϱ⠹ٶõ´Ù. ±×¸®°í, Ãʺ¸ÀÚµéÀÌ ½Ç¼öÇϱ⠽¬¿î °æ¿ì´Â ²À ȯ°æº¯¼ö PATHÀÇ °¡Àå óÀ½¿¡ /usr/local/bin ÀÌ ¿Àµµ·Ï ÇÏ¿©¼­ /usr/local/bin/m4, make°¡ ½ÇÇàµÇµµ·Ï ÇÏ¿©¾ß¸¸ÇÑ´Ù. ±×·¸Áö ¾ÊÀ¸¸é AIX ³»¿¡ ÀÖ´Â m4, make¸¦ È£ÃâÇÒ °ÍÀÌ´Ù.




7. Sendmail.cf »ý¼ºÇϱâ


mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/sendmail> cd ../cf/cf
mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/cf/cf> more README

  Sendmail ¹èÆ÷º»¿¡´Â ¾Ö¼®ÇÏ°Ôµµ cf/cf/aix433.mc ÆÄÀÏÀÌ ¾ø´Ù. ÀÌ ÆÄÀÏÀº AIX 4.3.3¿¡¼­ /usr/samples/tcpip/sendmai/cf/aix433.mcÀÇ ¿¹Á¦ÆÄÀÏÀ» º¹»çÇؼ­ ¾²¸é ÇØ°áÇÒ ¼ö ÀÖ´Ù. ±×¸®°í ´ÙÀ½°ú °°ÀÌ ÆíÁýÀ» Çؼ­ »ç¿ëÇϱ⠹ٶõ´Ù.

mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/cf/cf> cp /usr/samples/tcpip/sendmail/cf/aix433.mc ./aix433.mc
mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/cf/cf> vi aix433.mc
...
...
divert(0)dnl
OSTYPE(aix4)dnl
FEATURE(allmasquerade)dnl
FEATURE(`access_db', `hash -T /etc/mail/access')dnl
DOMAIN(generic)dnl
MAILER(local)dnl
MAILER(smtp)dnl
MAILER(uucp)
HACK(sdp)dnl

¿Í °°ÀÌ »¬°Ç »©°í, ¼öÁ¤À» ÇÑ ´ÙÀ½¿¡ ¸ðÁ¶¸® Áö¿î´Ù. Áö¿ìÁö ¾Ê°í # ·Î comment ó¸® Çؼ­´Â ¾ÈµÈ´Ù. ÇÊÀÚ°¡ Çغ» ¹Ù·Î´Â # 󸮸¦ Çصµ Àִ°ÍÀ¸·Î ÀνÄÀ»ÇÑ´Ù. OSTYPE(aix43)dnl Àº OSTYPE(aix4)dnl À¸·Î ¹Ù²Û´Ù. ±× ÀÌÀ¯´Â ÀÌ°÷¿¡¼­´Â ./ostype/aix4.m4ÀÇ ÆÄÀÏÀ» ÂüÁ¶ÇÏ°Ô µÇ´Âµ¥, ÆÄÀϸíÀ» Àß Ã£µµ·Ï Çϱâ À§ÇÔÀÌ´Ù. ƯÈ÷, FEATURE(promiscuous_relay)dnl ºÎºÐÀº relay-host ¸¦ enable Çϴ°ÍÀ¸·Î¼­ Àý´ë »ðÀÔ½ÃÄѼ­´Â ¾ÈµÈ´Ù. ÀÌ°ÍÀ» »ðÀÔÇϰԵǸé, ÄÄÆÄÀÏµÈ sendmail Àº relay-host¸¦ Çã¿ëÇÏ°Ô µÇ¾î ¼ö¸¹Àº ½ºÆÔ¸ÞÀÏÀÇ Áß°£ °æÀ¯Áö·Î °í½º¶õÈ÷ »ç¿ëµÇ°Ô µÇ°í, ¾î´À³¯ °©Àڱ⠱¹Á¤¿øÀ¸·ÎºÎÅÍ ÀüÈ­°¡ ¿Ã¼öµµ ÀÖ´Ù. ½ÇÁ¦, ÀÌ·± »ç·Ê°¡ ¸¹´Ù. FEATURE(`access_db', `hash -T /etc/mail/access')dnl ºÎºÐÀº Berkeley DB¸¦ »ç¿ëÇؼ­ /etc/mail/access ÆÄÀÏÀ» »ç¿ëÇϵµ·Ï Çϱâ À§ÇÔÀÌ´Ù. ÇÊÀÚ´Â, ÀÌ ºÎºÐÀ» »©¸Ô°í Çؼ­, access ¿¡ µî·ÏÇÑ RELAY °¡ Àß µÇÁú ¾Ê¾Æ¼­ ¸¹Àº °í»ýÀ» ÇÏ¿´´Ù.

HACK(sdp)dnl ºÎºÐÀ» ÁÖ¸ñÇÏÀÚ. ÀÌ ºÎºÐÀÌ sendmail-8.12.8h¿¡¼­ ÇѱÛÁ¦¸ñÀ» °¡Áø ½ºÆÔ¸ÞÀÏÀ» Â÷´ÜÇϱâ À§ÇÑ ·ê¼ÂÀ» ¼³Á¤ÇÏ´Â ºÎºÐÀÌ´Ù. Ãß°¡ÀûÀ¸·Î ´ÙÀ½°ú °°ÀÌ ÇØÁØ´Ù.

mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/cf/cf> cd ..
mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/cf> cd hack
mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/cf/hack> cp ../../../sdp.m4-1.28 ./sdp.m4

mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/cf/hack> cd ..
mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/cf> m4 ./m4/cf.m4 ./cf/aix433.mc > sendmail.cf

mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/cf> ls -l sendmail.cf
-rw-r--r--   1 root     system     60637 Mar 18 13:51 sendmail.cf

* ÁÖÀÇ»çÇ×
/usr/bin/m4:./m4/cf.m4:29 can't open file
include(../m4/cfhead.m4)

¿Í °°ÀÌ ¿¡·¯°¡ ¹ß»ýÇϸé, /bin/m4°¡ 'ifdef'¸¦ Á¦´ë·Î ó¸®Ä¡ ¸øÇÏ´Â AIX m4ÀÇ ¸ÞÄ¿´ÏÁò ¹®Á¦ÀÌ´Ù. ÀÌ ¹®Á¦¸¦ ÇØ°áÇϱâ À§Çؼ­´Â À§¿¡¼­µµ ÇÊÀÚ°¡ ¸¹ÀÌ ¾ð±ÞÇÏ¿´µíÀÌ ftp.gnu.org/pub/gnu¿¡¼­ GNU m4¸¦ ´Ù¿î·Îµå ¹Þ¾Æ¼­ ¼Ò½º ÄÄÆÄÀÏÀ» ÇÏ°í, ±× m4¸¦ ¾´´Ù. Ãʺ¸ÀÚµéÀº GNU m4¸¦ ÄÄÆÄÀÏÇÏ´Â°Ô ¾î·Á¿ï ¼öµµ ÀÖÀ»°ÍÀÌ´Ù. °£´ÜÇÏ´Ù. ´ÙÀ½°ú °°ÀÌ Çϱ⠹ٶõ´Ù.

# gzip -dc m4-1.4.tar.gz | tar xvf -
# cd m4-1.4
# ./configure CC=gcc
# make
# make install

³¡~~~. ÀÌ ¾ó¸¶³ª °£´ÜÇÑ°¡!!! GNU S/W µéÀº autoconf ·Î ÄÄÆÄÀÏÀ» ÇÏ°Ô²û µÇ¾î À־ ¹«Ã´ Æí¸®ÇÏ´Ù. ±×·¡¼­ ÇÊÀÚ°¡ CompileÀ» ÁÁ¾ÆÇÏ´Â µí ÇÏ´Ù.

GNU m4¸¦ ¼³Ä¡ÇÑÈÄ,

# which m4
/usr/local/bin/m4

ÀÌ·¸°Ô ³ª¿À°Ô ÇϱâÀ§Çؼ­´Â PATH=/usr/local/bin °ú°°ÀÌ ¸Ç ¾Õ¿¡ ȯ°æº¯¼ö¸¦ ³Ö¾îÁà¾ß ÇÑ´Ù...
ÀÚ, ÀÌÁ¦ºÎÅÍ´Â sendmail.cf¸¦ ¸¸µé¾îº¸ÀÚ.
mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/cf> cd cf
mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/cf/cf> cp ../sendmail.cf .
mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/cf/cf> sh Build install-cf
Using M4=/usr/local/bin/m4
../../devtools/bin/install.sh -c -o root -g bin -m 0444 sendmail.cf /etc/mail/sendmail.cf
rm -f submit.cf
/usr/local/bin/m4 ../m4/cf.m4 submit.mc > submit.cf || ( rm -f submit.cf && exit 1 )
chmod 444 submit.cf
../../devtools/bin/install.sh -c -o root -g bin -m 0444 submit.cf /etc/mail/submit.cf

mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/cf/cf> ls -l /etc/mail
-r--r--r--   1 root     bin        60637 Mar 18 13:52 sendmail.cf
-r--r--r--   1 root     bin        39081 Mar 18 13:52 submit.cf

ÀÌ·¸°Ô Çؼ­ sendmail.cf, submit.cf ÀÇ »ý¼ºÀÌ ³¡³µ´Ù.




8. Sendmail º¸¾È°ü·Ã µð·ºÅ丮 ¼³Á¤ ¹× À¯Àú, ±×·ì ¼³Á¤Çϱâ



User ID »ý¼º: smmsp, id # : 25
Group ID »ý¼º: smmsp, gid # : 25

mail:/> id smmsp
uid=25(smmsp) gid=25(smmsp)

¿Í °°ÀÌ »ý¼ºÀ» Çؼ­ ¾Æ·¡ÀÇ ±ÇÇÑÀ» ¼³Á¤ÇÑ´Ù. À§¿¡¼­ 25¹øÀÇ Àǹ̴ sendmail port¸¦ ÀÏÄ´´Ù. ±×³É ½±°Ô ÀÌÇØÇϱâ À§Çؼ­ ÀÌ ¹øÈ£¸¦ »ç¿ëÅä·Ï ÇÏ´Â °Í °°´Ù.

-r-xr-sr-x      root   smmsp    ... /usr/sbin/sendmail
drwxrwx---      smmsp  smmsp    ... /var/spool/clientmqueue
drwx------      root   bin    ... /var/spool/mqueue
-r--r--r--      root   bin    ... /etc/mail/sendmail.cf
-r--r--r--      root   bin    ... /etc/mail/submit.cf




9. Sendmail ÀνºÅçÇϱâ


  Unix ¿¡¼­ ÇÁ·Î±×·¥À» ÄÄÆÄÀÏÇÒ¶§ °¡Àå Áß¿äÇÑ °ÍÀº ÄÄÆÄÀÏÀ» ÇϱâÀü¿¡ ²À README ÆÄÀÏÀ» ÀÐ¾î º¸´Â°ÍÀÌ´Ù. ´ëºÎºÐÀÇ »ç¿ëÀÚµéÀÌ ÀÌ°ÍÀÌ ±ÍÂú¾Æ¼­ °Ç³Ê¶Û·Á°í ÇÏÁö¸¸, ÀÌ°Ç Á¤¸» À߸øµÈ °ÍÀÌ´Ù. ²À Àо±â ¹Ù¶õ´Ù.

mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/cf/cf> cd ../..
mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H> sh Build install




10. Sendmail utility(makemap, mailstats) ¼³Á¤


  makemapÀº ½ºÆÔ ¸ÞÀÏÀ» Â÷´ÜÇϰųª relay¸¦ Çã¿ëÇϴµ¥ »ç¿ëÇÏ´Â accessDB¸¦ »ý¼ºÇÏ´Â ÇÁ·Î±×·¥ÀÌ´Ù. ÇÊÀÚ°¡ À§¿¡¼­µµ ¸»ÇßµíÀÌ, sendmailÀº Berkeley DB¸¦ »ç¿ëÇؼ­ DB¸¦ °ü¸®ÇÑ´Ù.

mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H> cd makemap
mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/makemap> sh Build -c -f ../devtools/OS/AIX.4.3

mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/makemap> sh Build install
Configuration: pfx=, os=AIX, rel=4.3.3, rbase=4, rroot=4.3, arch=PPC, sfx=, variant=optimized
Making in /down/Sendmail-8.12.8H/sendmail-8.12.8-H/obj.AIX.4.3.3.PPC/makemap
/usr/ucb/install -c -o bin -g bin -m 555 makemap /usr/sbin
/usr/ucb/install -c -o bin -g bin -m 444 makemap.0 /usr/share/man/cat8/makemap.8

mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/makemap> cd ../mailstats
mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/mailstats> sh Build -c -f ../devtools/OS/AIX.4.3

mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/mailstats> sh Build install
Configuration: pfx=, os=AIX, rel=4.3.3, rbase=4, rroot=4.3, arch=PPC, sfx=, variant=optimized
Making in /down/Sendmail-8.12.8H/sendmail-8.12.8-H/obj.AIX.4.3.3.PPC/mailstats
/usr/ucb/install -c -o bin -g bin -m 555 mailstats /usr/sbin
/usr/ucb/install -c -o bin -g bin -m 444 mailstats.0 /usr/share/man/cat8/mailstats.8

ÀÌÁ¦´Â access, relay-domains ÆÄÀÏÀ» »ý¼ºÇÑ´Ù.
mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/mailstats> cd /etc/mail
mail:/etc/mail> touch access relay-domains

access : spam relay¸¦ ip, hostnameÀ¸·Î Á¦¾îÇϱâ À§ÇÑ°Í.
relay-domain : domain name º°·Î relay¸¦ Çã¿ëÇϱâ À§ÇÑ°Í.

mail :/etc/mail> vi local-host-names
mail
mail.jkkang.net

À§ÀÇ hostname ¶õ¿¡ ÀÚ½ÅÀÇ hostnameÀ» ±â·ÏÇÑ´Ù. local-host-names ÆÄÀÏÀº sendmail¿¡¼­ ¹Þ¾ÆµéÀÏ ¸ÞÀÏÀÇ µµ¸ÞÀΰú È£½ºÆ®À̸§À» ¸»ÇÑ´Ù. ÀÌ ÆÄÀÏÀº ¿©·¯ÁÖ¼Ò·Î ¿À´Â ¸ÞÀÏÀ» ÁöÁ¤ÇÑ ¼ö½ÅÀÚ°¡ ¹Þµµ·Ï ¼³Á¤ÇÏ´Â ±â´ÉÀÌ´Ù. ¹Ýµå½Ã sendmail µ¥¸óÀ» restart ½ÃÄÑÁà¾ß ÇÑ´Ù. sendmailÀº ÀÌ ÆÄÀÏ¿¡ ÀÖ´Â µµ¸ÞÀÎÀÇ ¸ÞÀÏÀº ÀڱⰡ ÃÖÁ¾¼ö½ÅÁö¶ó°í ÀνÄÇϰԵȴÙ. µû¶ó¼­ À¥È£½ºÆÃÀ» ÇÒ¶§¿¡´Â °í°´ÀÇ µµ¸ÞÀÎÀ» ¹Ýµå½Ã ÀÌ ÆÄÀÏ¿¡ µî·ÏÀ» ÇØÁà¾ß ÇÑ´Ù.
mail :/etc/mail> vi access
jkkang65@hanmail.net    OK
jkkang65@mail.com       REJECT
sendmail.domain         REJECT
210.117.132.23          RELAY
203.254.121             REJECT

À§ÀÇ ³»¿ëÀ» °£´ÜÈ÷ ¼³¸íÇÏÀÚ¸é, OK ¿ÞÂÊ¿¡ ÀÖ´Â ¸ÞÀÏ·Î ºÎÅÍ ¿À´Â ¸ÞÀÏÀ» Çã¿ëÇÏ°í, REJECT´Â ¿ÞÂÊ¿¡ ÀÖ´Â ¸ÞÀÏÁּҷκÎÅÍ ¿À´Â ¸ÞÀÏÀ» ºÒÇãÇÑ´Ù. ±×¸®°í, RELAY´Â ¿ÞÂÊ IP ZoneÀÇ sendmail relay¸¦ Çã¿ëÇÑ´Ù. ¸¸¾à¿¡ PC¿¡¼­ Outlook°°Àº°ÍÀ¸·Î pop3¸¦ »ç¿ëÇÒ·Á¸é ¸¶Âù°¡Áö·Î RELAY¸¦ Çã¿ëÇؾ߸¸ »ç¿ëÀÌ °¡´ÉÇÏ´Ù. pop3¸¦ »ç¿ëÇϴ°͵µ ÀÏÁ¾ÀÇ RELAY¸¦ Çϴ°Ͱú °°±â¶§¹®ÀÌ´Ù. À§ÀÇ ÆÄÀÏÀ» ÆíÁýÇÒ¶§´Â Tab Å°¸¦ »ç¿ëÇؾ߸¸ ÇÑ´Ù. ÀÚ, ´ÙÀ½Àº sendmailÀÌ ÀνÄÇÒ¼ö ÀÖµµ·Ï access ÆÄÀÏÀ» Berkeley DB·Î »ý¼ºÇÏ´Â ´Ü°èÀÌ´Ù. ²À hash¸¦ ¾²µµ·Ï ÇÑ´Ù.

mail:/etc/mail> makemap hash /etc/mail/access < /etc/mail/access

accessÆÄÀÏÀÌ ¼öÁ¤µÉ¶§¸¶´Ù À§ÀÇ ¸í·ÉÀ» ½ÇÇà½ÃÄÑ access DB¿¡ ¹Ý¿µ½ÃÄѾßÇÑ´Ù. ±×¸®°í, sendmail µ¥¸óÀ» ´Ù½Ã ½ÇÇà½ÃÄÑ ÁÙ ÇÊ¿ä´Â ¾ø´Ù. ´ÙÀ½Àº access contrlo option ºÎºÐÀ» »ìÆ캸ÀÚ.

OK ÁöÁ¤µÈ È£½ºÆ®³ª »ç¿ëÀÚ°¡ º¸³½¸ÞÀÏÀº ´Ù¸¥ ¼³Á¤ rule ÀÌ °ÅºÎÇÏ´Â °æ¿ì¿¡µµ ¹Þ¾ÆµéÀδÙ.
RELAY ÁöÁ¤µÈ È£½ºÆ®¿¡ ´ëÇØ SMTP ¸ÞÀÏ Áß°è ¿ªÇÒÀ» ÇÑ´Ù. Áï ÁöÁ¤µÈ µµ¸ÞÀο¡ ´Â »ç¿ëÀÚ¿¡°Ô ¿À´Â ¸ÞÀÏÀ» ¹Þ°í ±× µµ¸ÞÀο¡ÀÖ´Â »ç¿ëÀÚ°¡ ¼­¹ö¸¦ ÅëÇØ ¸ÞÀÏÀ» º¸³¾¼ö ÀÖµµ·Ï ÇÑ´Ù. ÁöÁ¤µÈ µµ¸ÞÀο¡¼­ ¿À´Â ¸ÞÀÏÀº ´Ù¸¥ ·êÀÌ °ÅºÎÇÏ´Â °æ¿ì¿¡µµ ¹Þ¾Æ µéÀδÙ.
REJECT ÁöÁ¤µÈ µµ¸ÞÀΰú °ü·ÃµÈ ¸ðµç ¸ÞÀÏ(¼ö½Å/¹ß½Å)À» °ÅºÎÇÑ´Ù.
DISCARD $#discard mailer¸¦ »ç¿ëÇØ ¸Þ¼¼Áö¸¦ ¿ÏÀüÈ÷ Æó±âÇÑ´Ù. ¸Þ¼¼Áö¸¦ ¹Þ±â´Â ÇÏÁö¸¸ ¹è´ÞÀº ÇÏÁö¾Ê°í ¹ß½ÅÀÚ¿¡°Ô Æó±â»ç½ÇÀ» ¾Ë¸®Áö ¾Ê±â ¶§¹®¿¡, ¹ß½ÅÀÚ´Â ¹è´ÞµÇ¾ú´Ù°í »ý°¢ÇÏ°Ô µÈ´Ù.
501 <message> ÁöÁ¤µÈ user@host ¿Í ¹ß½ÅÀÚÀÇ ÁÖ¼Ò°¡ Àüü ȤÀº ºÎºÐÀûÀ¸·Î ÀÏÄ¡ÇÒ°æ¿ì À̸ÞÀÏÀ» ¹ÞÁö ¾Ê´Â´Ù. µÚÀÇ ¿¹´Â return mail¿¡ Æ÷Ç﵃ ¿¡·¯ ¸Þ¼¼Áö ±¸¹®À» ÁöÁ¤ÇÏ¿© ³ÖÀ»¼ö ÀÖ´Ù.
553 <message> ¹ß½ÅÀÚÀÇ ÁÖ¼Ò¿¡ È£½ºÆ®¸íÀÌ ¾øÀ» °æ¿ì ¸ÞÀÏÀ» ¹ÞÁö ¾Ê´Â´Ù.
550 <message> ÁöÁ¤µÈ µµ¸ÞÀΰú °ü·ÃµÈ ¸ÞÀÏÀ» ¹ÞÁö ¾Ê´Â´Ù.

mail :/etc/mail> vi relay-domains
210.117.198.133
jkkang.net

¿Í °°ÀÌ Çؼ­ relay ¸¦ Çã¿ëÇÏ´Â µµ¸ÞÀÎÀ» ¼³Á¤ÇÒ ¼ö°¡ ÀÖ´Ù. ±×¸®°í sendmail µ¥¸óÀ» ´Ù½Ã ½ÇÇà½ÃÄÑ ÁÙ ÇÊ¿ä´Â ¾ø´Ù. relay ¿¡ °ü·ÃµÈ°ÍÀº /etc/mail/relay-domains ÆÄÀÏ¿¡ Çã¿ëÇÏ´Â ¹üÀ§¸¦ ÁöÁ¤ÇØ Áִ°ÍÀÌ °ü¸®Â÷¿ø¿¡¼­ ´õ ÆíÇÏ´Ù. ±×¸®°í Çã¿ëÀ» ºÒÇãÇÏ´Â ¸®½ºÆ®´Â access ÆÄÀÏÀ» È°¿ëÇϸé ÁÁ´Ù. ÇÊÀÚ´Â, À̹æ¹ýÀ» ÃßõÇÏ°í ½Í´Ù. ±×¸®°í ´ÙÀ½°ú °°Àº ¹æ¹ýÀ¸·Î sendmailÀÌ relay¸¦ Çã¿ëÇÏ´Â µµ¸ÞÀÎÀÇ ¸®½ºÆ®¸¦ º¼ ¼ö ÀÖ´Ù.

mail :/etc/mail> echo '$=R' | sendmail -bt
ADDRESS TEST MODE (ruleset 3 NOT automatically invoked)
Enter <ruleset> <address>
> jkkang.net

À§ ¿¡¼­ º¸¸é, ÇÊÀÚÀÇ È¨ÆäÀÌÁöÀÎ jkkang.net ÀÌ relay °¡ Çã¿ëµÇ°í ÀÖÀ½À» º¼¼ö ÀÖ´Ù.

mail:/etc/mail> makemap -l
dbm
hash
btree

À§ÀÇ ¸í·É¾î´Â Data type ÀÌ´Ù.

mail:/etc/mail> ls -l access*
-rw-r--r--   1 root     system        95 Mar 14 17:47 access
-rw-r-----   1 root     system     12288 Mar 14 17:47 access.db




11. Database Alias ÃʱâÈ­Çϱâ


mail:/etc/mail> touch aliases
mail:/etc/mail> sendmail -bi
/etc/mail/aliases: 0 aliases, longest 0 bytes, 0 bytes total
mail:/etc/mail> chmod 0640 aliases




12. Sendmail ½ÇÇà ¹× ¹öÀüº¸±â


mail:/etc/mail> /usr/lib/sendmail -bd -q25m
mail:/etc/mail> ps -ef|grep sendmail
    root 18610     1   0 13:56:58      -  0:00 sendmail: accepting connections

mail:/down/Sendmail-8.12.8H/sendmail-8.12.8-H/cf/cf> telnet localhost 25
Trying...
Connected to loopback.
Escape character is '^]'.
220 mail.kr.ibm.com ESMTP Sendmail 8.12.8-H/8.12.8; Tue, 18 Mar 2003 16:45:24 -0600




13. syslog Çѱ۸޽ÃÁö º¸ÀÓ È®ÀÎ


mail:/> tail -f /var/adm/syslog
Mar 18 16:47:06 mail sendmail[11064]: h2IMl6Ib011064: Accepted Subject=¾È³çÇϼ¼¿ä?
Mar 18 16:47:06 mail sendmail[11064]: h2IMl6Ib011064: from=root, size=50, class=0, nrcpts=1, msgid=<200303182247.h2IMl6I
b011064@mail.kr.ibm.com>, relay=root@localhost
Mar 18 16:47:06 mail sendmail[15014]: h2IMl6xH015014: Accepted Subject=¾È³çÇϼ¼¿ä?
Mar 18 16:47:06 mail sendmail[15014]: h2IMl6xH015014: from=, size=327, class=0, nrcpts=1, msgid=<2
00303182247.h2IMl6Ib011064@mail.kr.ibm.com>, proto=ESMTP, daemon=MTA, relay=localhost [127.0.0.1]
Mar 18 16:47:06 mail sendmail[11064]: h2IMl6Ib011064: to=root, ctladdr=root (0/0), delay=00:00:00, xdelay=00:00:00, mail
er=relay, pri=30031, relay=[127.0.0.1] [127.0.0.1], dsn=2.0.0, stat=Sent (h2IMl6xH015014 Message accepted for delivery)
Mar 18 16:47:07 mail sendmail[15748]: h2IMl6xH015014: to=, ctladdr= (0/0), d
elay=00:00:01, xdelay=00:00:00, mailer=local, pri=30582, dsn=2.0.0, stat=Sent




14. ÇÑ±Û Spam ¸ÞÀÏ deny È®ÀÎ


mail:/> tail -f /var/adm/syslog
Mar 18 16:58:08 mail sendmail[11074]: h2IMw8nr011074: Accepted Subject=[±¤°í] ÇϳªµÑ
Mar 18 16:58:08 mail sendmail[11074]: h2IMw8nr011074: from=root, size=37, class=0, nrcpts=1, msgid=<200303182258.h2IMw8n
r011074@mail.kr.ibm.com>, relay=root@localhost
Mar 18 16:58:09 mail sendmail[8530]: h2IMw9xH008530: ruleset=check_subject, arg1=[±¤°í] ÇϳªµÑ, relay=localhost [127.0.0
.1], reject=553 5.0.0 We don't accept spam.
Mar 18 16:58:09 mail sendmail[8530]: h2IMw9xH008530: Rejected Subject=[±¤°í] ÇϳªµÑ
Mar 18 16:58:09 mail sendmail[8530]: h2IMw9xH008530: from=, size=314, class=0, nrcpts=1, msgid=<20
0303182258.h2IMw8nr011074@mail.kr.ibm.com>, proto=ESMTP, daemon=MTA, relay=localhost [127.0.0.1]
Mar 18 16:58:09 mail sendmail[8530]: h2IMw9xH008530: to=, delay=00:00:00, pri=30310, stat=We don't
 accept spam.
Mar 18 16:58:09 mail sendmail[11074]: h2IMw8nr011074: to=root, ctladdr=root (0/0), delay=00:00:01, xdelay=00:00:01, mail
er=relay, pri=30033, relay=[127.0.0.1] [127.0.0.1], dsn=5.0.0, stat=Service unavailable
Mar 18 16:58:09 mail sendmail[11074]: h2IMw8nr011074: h2IMw8ns011074: DSN: Service unavailable
Mar 18 16:58:09 mail sendmail[8530]: h2IMw9xJ008530: Accepted Subject=Returned mail: see transcript for details
Mar 18 16:58:09 mail sendmail[8530]: h2IMw9xJ008530: from=<>, size=1879, class=0, nrcpts=1, msgid=<200303182258.h2IMw8ns
011074@mail.kr.ibm.com>, bodytype=8BITMIME, proto=ESMTP, daemon=MTA, relay=localhost [127.0.0.1]
Mar 18 16:58:09 mail sendmail[11074]: h2IMw8ns011074: to=root, delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=31061,
 relay=[127.0.0.1] [127.0.0.1], dsn=2.0.0, stat=Sent (h2IMw9xJ008530 Message accepted for delivery)
Mar 18 16:58:10 mail sendmail[15042]: h2IMw9xJ008530: to=, delay=00:00:01, xdelay=00:00:01, mailer
=local, pri=32130, dsn=2.0.0, stat=Sent
À§ È­¸é¿¡¼­ º¸¸é [±¤°í] ºÎºÐÀÌ Reject µÇ´Â ºÎºÐÀ» È®ÀÎÇÒ¼ö ÀÖ´Ù. Ãß°¡ÀûÀ¸·Î ½ºÆÔ¸ÞÀÏ¿¡ ´ëÇؼ­ ÇÊÅ͸µÀ» ÇÏ°íÀÚ ÇÑ´Ù¸é, sendmail.cf¸¦ ¼öÁ¤À» ÇØÁà¾ß ÇÑ´Ù.

15. SendmailÀÇ relay-host ±â´É Å×½ºÆ®


  sendmailÀ» ½ÇÇà½ÃŲ »óÅ¿¡¼­ ´ÙÀ½°ú °°ÀÌ Á¢¼ÓÇÑ´Ù. ¶Ç´Â http://www.abuse.net/relay.html ½ÎÀÌÆ®¿¡¼­ ½±°Ô Å×½ºÆ®¸¦ ÇÒ¼ö ÀÖ´Ù. °¢ÀÚ ÃëÇâ¿¡ ¸Â°Ô Å×½ºÆ®¸¦ Çغ¸±â ¹Ù¶õ´Ù.

mail:/> telnet relay-test.mail-abuse.org
...
Tested host banner: 220 a.b.c.d ESMTP Sendmail 8.12.8-H/8.12.6; Mon, 30 Sep 2002 17:05:38 +0900
System appeared to reject relay attempts
Connection closed.
...

ÀÌ·¸°Ô ³ª¿À¸é relay-host ±â´ÉÀ» disable ÇÏ°Ô²û ¼³Á¤µÈ °ÍÀÌ´Ù. Áö±Ý±îÁö Sendmail 8.12.8h¸¦ ÄÄÆÄÀÏÇؼ­ ÀνºÅç ÇÏ´Â °úÁ¤À» ¼³¸íÀ» ÇغôÙ. ÇÊÀÚ´Â Spam Mail Relay¿¡ ´ëÇؼ­ ºñ±³Àû °£´ÜÈ÷ ¼³¸íÀ» ÇÏ¿´´Ù. ±×¿Ü¿¡µµ SendmailÀº ½ºÆÔ¸ÞÀÏÀ» Á¦¸ñº°·Î °É·¯³»´Â ±â´Éµµ ÀÖÀ¸´Ï, ÀÌ·¯ÇÑ ÁÁÀº ±â´ÉÀº ÀÎÅͳÝÀ» µÚÁö´ø°¡, ¾Æ´Ï¸é °¡Àå ÁÁÀº ¸Þ´º¾óÀÎ README ÆÄÀÏÀ» õõÈ÷ Àо±â ¹Ù¶õ´Ù. ±× À§¿¡ À¯Áî³ÝÀÇ sendmail °ü·Ã ´º½º±×·ìÀ» È°¿ëÇÏ¸é ¸¹Àº Á¤º¸¸¦ ¾òÀ»¼ö ÀÖÀ»°ÍÀÌ´Ù. Spam ¸ÞÀÏÀ» °É·¯³»´Â ¹æ¹ý¿¡ ´ëÇÑ ¼³¸íÀº °ð ½Ã°£À» ÂÉ°³¼­ ¸Þ´º¾óÀ» ¸¸µéµµ·Ï ÇÏ°Ú´Ù. ¾Æ¹«ÂÉ·Ï, sendmailÀ» AIX ¿¡¼­µµ ½±°Ô ÀνºÅçÀ» ÇÒ¼ö ÀÖµµ·Ï ÀÛÀº º¸ÅÆÀÌ µÇ¾úÀ¸¸é ÇÑ´Ù.

²À, README ÆÄÀÏÀ» Àд°ÍÀ» ½À°üÈ­ ÇÏÀÚ...

¾Æ~~~ Àá¿Â´Ù...
ÇÊÀÚÀÇ ÄÄÆÄÀÏ ¹®¼­°¡ sendmailÀ» ¼³Ä¡ÇÏ´Â ºÐµé²² ¸¹Àº µµ¿òÀÌ µÇ¾úÀ¸¸é ÇÕ´Ï´Ù. ±×¸®°í, ¹®¼­¿¡ ¿À·ù°¡ ÀÖÀ¸¸é Àú¿¡°Ô ¸á·Î ¾Ë·ÁÁÖ½Ã¸é °í¸¿°Ú½À´Ï´Ù.



Copyleft (c) 1996 - 2003, Kang Jul Ki. All rights were not reserved.
Powered by http://jkkang.net since 1996