LOGFILE=/var/log/procmail
VERBOSE=no
PATH=/usr/bin:/usr/local/bin:/bin
SHELL=/bin/sh  #   shell ϴ    .

:0 B
*^.\$\)C
{
  :0 fbw
    |hmconv -u

  :0 fhw
  * ^Content-Type: text/plain
  |formail -c -I "Content-Type: text/plain; charset=EUC-KR" -I \
   "Content-Transfer-Encoding: 8bit"

  :0 Efhw
  * ^Content-Type: text/html
  |formail -c -I "Content-Type: text/html; charset=EUC-KR" -I \
   "Content-Transfer-Encoding: 8bit"

  :0 Efhw
  * !^Content-Type:
  |formail  -c -I "Content-Type: text/plain; charset=EUC-KR" -I \
   "Content-Transfer-Encoding: 8bit"

# Note that '-c' flag has been added to formail invocation.
# It concatenates a  header of multiple lines into a single line
# so that a bug in 'hcode -dk -m' dealing with RFC 2047 encoded header
# has less 'harmful' effect.

  :0 fhw
    | formail -A  \
      "X-Automatic-Korean-Mail-Conversion: iso-2022-kr to euc-kr" 

}

# Perhaps, it's better to leave RFC 2047 encoded header intact by 
# commenting OUT  the following lines if you want 
# to preserve charset information in the header in an multilinguial 
# environment.
# It's also more in accord with the spirit of MIME and RFC 2130.
# Please, be aware that there's NO gurantee that 'hcode -dk -m'
# works flawlessly for all possible variations produced by
# multitudeo of  MUAs(e.g. Eudora) non-conformant to Korean
# mail exchange standard.

#Ʒ ISO-2022-KR  Ǿ    RFC 2047
#ڵ 츦  Դϴ. 
#׻ ѱ( ) ϸ ް Ϻ,߱,Ÿ ٸ  
#  ʱ    ʿ ų, 
#RFC 2047 ڵ    ص Ұ  α׷ 
#( MIME   ϰ ϵ elm̳ Solaris/SunOS mail,mailx
#  hypermail̳ mhonrc  mailing list archive ϰų
#  mailing list digest  )
#ڰ  쿡 Ͻʽÿ.
#̰ ٱ ȯ ƴ϶  Ͽ  ̹Ƿ
# ѱ ƴԿ ߸Ͽ ڵ ɼ 
#Ͻʽÿ. 
#ٱ ȯ濡   ڼ  ؾ Ѵٸ
#Ʒ   ʽÿ.  ڵ ̹ 
#߰ȣ  κб ؼ  ̷ Դϴ.

#:0 fhw
#  *Content-Type:.+; charset="?EUC-KR
#  | formail -c | hcode -dk -m 

#:0 Efhw
#    *^(Subject|From|Cc):.*=\?EUC-KR\?(B|Q)\?
#    |formail -c | hcode -dk -m

#EUC-KR  ƴ϶  ٸ ڼ ̸  쵵
# EUC-KR  ϴµ    
#ٸ   ִٰ Ѵٸ - ׸ 
#δ EUC-KR̶ Ѵٸ- Ʒ   comment
#ϰ   ٿ comment ̽ʽÿ

#:0 Efhw
#     *^(Subject|From):.*=\?[a-zA-Z]+[0-9a-zA-Z\-]+\?(B|Q)\?
#     | formail -c | hcode -dk -m
