Postfix Change Header From: outgoing mail using altermime

Biasanya From: header akan di isi oleh nilai dari settingan client masing2 user.

contoh: di thunderbird From: header akan di isi settingan dari Your Name:.

untuk email2 official From header bisa di paksakan supaya menggunakan nama user yg ada di database postfix user.
dengan bantuan altermime dan sedikit coding(c dan bash script).

altermime dapat di download disini:

www.pldaniels.com/altermime/

Coding c (access mysql db):

fungsinya untuk query field “name” (nama lengkap email user) di database postfix

paste code ini di console editor.(vi atau pico)

#include 
#include 
#include 
#include 

main(int argc,char *argv[]) {
   MYSQL *conn;
   MYSQL_RES *res;
   MYSQL_ROW row;

   char *server = "localhost";
   char *user = "user";
   char *password = "password";
   char *database = "db";
   char strsql[512];

   if(argc != 2)
   {
       printf("Usage: %s ’string query’\n", argv[0]);
       exit(EXIT_FAILURE);
   }

   snprintf(strsql, 512, "SELECT REPLACE(TRIM(name),’\n’,”) FROM mailbox WHERE username=TRIM(’%s’)", argv[1]);

   conn = mysql_init(NULL);

   /* Connect to database */
   if (!mysql_real_connect(conn, server,
         user, password, database, 0, NULL, 0)) {
      fprintf(stderr, "%s\n", mysql_error(conn));
      exit(EXIT_FAILURE);
   }

   /* send SQL query */
   if (mysql_query(conn, strsql)) {
      fprintf(stderr, "%s\n", mysql_error(conn));
      exit(EXIT_FAILURE);
   }

   res = mysql_use_result(conn);

     while ( (row = mysql_fetch_row(res))  !=  NULL )
      printf("%s\n", row[0]);
   return(0);

   /* Release memory used to store results and close connection */
   mysql_free_result(res);
   mysql_close(conn);
}

backup gmail account ke format maildir

pertama enable pop di account gmail : settings Forwarding and POP/IMAP Enable POP for all mail (even mail that’s already been downloaded) kemudian, konfigur ftechmail dan procmail: kita butuh procmail supaya bisa menyimpan emails ke dalam format maildir(1 file untuk satu email, mbox 1file besar yg berisi seluruh email) /home/USER/.fetchmailrc…

centos 5 point to point tunneling PPTP VPN

Pernah terpikir buat ngeremote pc di kantor(dengan private ip) dari rumah dengan koneksi isp yg kita pakai?   salah satunya dengapn cara tunneling/vpn. kali yg jadi korban kita distro centos 5 dengan kernel 2.6.18-92.1.13.el5. gimana cara installnya?

pertama install yum repository nya

# rpm -Uvh http://pptpclient.sourceforge.net/yum/stable/fc6/pptp-release-current.noarch.rpm

lanjut dengan install pptpnya

# yum --enablerepo=pptp-stable install pptp

The Large Hadron Collider: End of the world, or God’s own particle?

Large

Is an understatement. A giant circular tunnel, with several loops, stretches for 27km under the land between France and Switzerland. One of its experimental chambers is bigger than the nave of Westminster Abbey.

Hadron

The name for one of the types of particle that make up an atom. These tiny bits of energy will be propelled by giant magnets around the tunnel circuit at almost the speed of light.

Collide

Is what they will do when they meet other hadrons being beamed in the opposite direction, at the same great speed. The resulting explosion will create 100,000 times more heat than the sun, apparently. Thankfully, it will only happen for a moment, in an area a billion times smaller than a speck of dust.

speedy + abbatec adsl modem (bridge mode) + linksys WRT54GL (dialer PPPoE)

Linksys released the WRT54GL in 2005 to support third-party firmware based on Linux, after the original WRT54G line was switched from Linux to VxWorks, starting with version 5. The WRT54GL is technically a reissue of the version 4 WRT54G. Cisco was sued by the FSF for copyright infringement, but the case was settled

Pertama kali pakai speedy, nerima apa adanya setingan yg di buatin sama teknisinya(maklum bini yg jadi waspang waktu teknisinya nyeting hehehe).  yg di utak atik paling cuma password modem sama password speedy nya. kebetulan punya wireless router merk linksys (WRT54GL) yg bisa PPPoE di port wan nya, jadi kepikiran buat utak  atik ngubah settingan.

setingan aslinya di modem adsl nya seperti ini:

 

speedy quota 1G + winxp(laptop) + squid + bind9 + cache youtube (lanjutan)

YouTube is a video-sharing website on which users can upload, share, and view videos, created by three former PayPal employees in February 2005. The company is based in San Bruno, California, and uses Adobe Flash Video and HTML5[4] technology to display a wide variety of user-generated video content, including movie clips, TV clips, and music videos, as well as amateur content such as video blogging and short original videos. Most of the content on YouTube has been uploaded by individuals, although media corporations including CBS, BBC, Vevo, Hulu and other organizations offer some of their material via the site, as part of the YouTube partnership program

Nerusin topik sebelumnya , setelah berhasil bikin proxy pakai squid di winxp, akan di coba nambahin local resolver dns pakai bind9(windows precompile binary).

step pertama, nginstall bind9 di winxp
download precompile bind9 untuk windows di sini:

http://ftp.isc.org/isc/bind9/9.5.0-P2-W2/BIND9.5.0-P2-W2.zip

  • extrak di satu folder.
  • didalam folder klik 2 kali BINDInstall
  • muncul popup windows installer kecil, biarkan semua nya default, kecuali service account password,klik install

tunggu sampai selesai.

hasil instalasi nya nanti akan berada di sini C:\WINDOWS\system32\dns

  • klik start -> run -> ketik cmd, cd ke C:\WINDOWS\system32\dns\etc\

– buat file dengan nama named.conf,isinya seperti ini:

speedy quota 1G + winxp(laptop) + squid

Baru langganan speedy ceritanya nih hehehe….

cuma yg based on quota sih, 1G saja

pertama kali speedy  up / konek ke internet, sih gak kepikir  quota 1 G cukup atau nggak.

setelah browsing kesana kemari,dan liat argo quota di portal nya speedy dan traffic monitor di laptop kok nyedotnya kenceng juga hahahaha. 

yg terlintas di kepala pertama pakai proxy punya speedy, cuma setelah mikir2 kalo cache proxy nya ada di telkom juga pastinya traffic nya tetep counting juga alias argo tetep jalan.

akhirnya mutusin bikin proxy di laptop aja