I2I: IMAP to IMAP Data Transfer

Mevcut e-posta sunucunuzu tamamen farklı bir e-posta sunucuya taşırken kullanıcılarınızın e-postalarını da aktarmak isterseniz bunu en kolay IMAP dizinlerini iki sunucuda eşleyerek yapabilirsiniz.

Müşterimizin altyapısında böyle bir değişiklik yapmak için imapsync programını kullandık. Fakat mevcut e-posta sunucusunun imap sunucu özelliklerindeki bazı kısıtlamalardan dolayı(komutların büyük-küçük harf duyarlılığı vs)  müşterimizden usta MS Windows yazılımcısı Atakan Eser I2I programını yazdı. Bu program sayesinde müşterimizin eski mail sistemini surgate  gateway + surgate mail sunucu modülüne kullanıcıların tüm e-postalar  ile birlikte sorunsuz bir şekilde taşıdık.

I2I MS Windows masaüstü programı olup, http://code.google.com/p/i2i/ adresinden GPL olarak dağıtılmaktadır.  Ekran görüntüleri:

icap(tm) packet capture engine reaches zero packet loss at satured 1 Gbps

The new release of our next generation packet capturing engine, used in our products voitap(tm) and itap(tm), has made 6 packet loss per 10.000 packets, reaching nearly zero packet loss at a satured 1 Gbps ethernet link.

These recent numbers have confirmed our plans and projections for the ongoing 10 Gigabit version, that the design and methodology is correct, and that we are on the right way.

Solaris 10 ve SMC ile Servis Yönetimi

Solaris’in önceki sürümlerinde bir servisi açıp/kapamak için  diğer çoğu UNIX dağıtımlarında olduğu gibi /etc/init.d altındaki scriptler kullanılırdı. Solaris 10 ile birlikte buna ek olarak Service Management Facility (SMF) adı verilen bir yöntem geldi.

Açık servisleri listelemek için svcs komutu verilir. –a parametresi verilirse aktif/pasif tüm servisler listenir.

# svcs

STATE          STIME    FMRI
legacy_run     16:40:13 lrc:/etc/rcS_d/S50sk98sol
legacy_run     16:41:47 lrc:/etc/rc2_d/S10
lulegacy_run     16:41:55 lrc:/etc/rc2_d/S20sysetup
legacy_run     16:41:56 lrc:/etc/rc2_d/S40llc2
legacy_run     16:41:57 lrc:/etc/rc2_d/S42ncakmod
legacy_run     16:41:58 lrc:/etc/rc2_d/S47pppd
legacy_run     16:41:58 lrc:/etc/rc2_d/S70uucp
legacy_run     16:41:59 lrc:/etc/rc2_d/S72autoinstall
legacy_run     16:42:00 lrc:/etc/rc2_d/S73cachefs_daemon
legacy_run     16:42:01 lrc:/etc/rc2_d/S81dodatadm_udaplt
legacy_run     16:42:01 lrc:/etc/rc2_d/S89PRESERVE
legacy_run     16:42:01 lrc:/etc/rc2_d/S94ncalogd
legacy_run     16:42:02 lrc:/etc/rc2_d/S98deallocate
online         16:37:38 svc:/system/svc/restarter:default
online         16:37:43 svc:/network/pfil:default
online         16:37:44 svc:/network/tnctl:default
online         16:37:45 svc:/network/loopback:default
online         16:37:45 svc:/system/filesystem/root:default
online         16:38:00 svc:/system/scheduler:default
online         16:38:07 svc:/system/boot-archive:default
online         16:38:07 svc:/system/installupdates:default

svcs –p parametresi ile ilgili servisin çalışan prosesleri hakkında bilgi alınabilir.

# svcs -p network/smtp:sendmail

STATE          STIME    FMRI
online         16:41:43 svc:/network/smtp:sendmail
16:41:43      550 sendmail
16:41:43      555 sendmail

# ps -fp 550,555

UID   PID  PPID   C    STIME TTY         TIME CMD
smmsp   550     1   0 16:41:43 ?           0:00 /usr/lib/sendmail -Ac -q15m
root   555     1   0 16:41:44 ?           0:01 /usr/lib/sendmail -bd -q15m

-d parametresi ile ilgili servisin bağımlı olduğu servisleri, -D ile de bu servise bağımlılığı olan servisleri görebilirsiniz.  –l parametresi ile ise belirtilen servisle ilgili detaylı bilgi alınabilir.

# svcs -d network/smtp:sendmail

STATE          STIME    FMRI
online         16:40:10 svc:/system/identity:domain
online         16:40:15 svc:/system/filesystem/local:default
online         16:40:18 svc:/network/service:default
online         16:40:19 svc:/milestone/name-services:default
online         16:41:30 svc:/system/filesystem/autofs:default
online         16:41:39 svc:/system/system-log:default

# svcs -D network/smtp:sendmail

STATE          STIME    FMRI
online         16:42:03 svc:/milestone/multi-user:default

# svcs ssh

STATE          STIME    FMRI
online         16:41:32 svc:/network/ssh:default

# svcs -l ssh

fmri         svc:/network/ssh:default
name         SSH server
enabled      true
state        online
next_state   none
state_time   January  2, 2010  4:41:32 PM EET
logfile      /var/svc/log/network-ssh:default.log
restarter    svc:/system/svc/restarter:default
contract_id  64
dependency   require_all/none svc:/system/filesystem/local (online)
dependency   optional_all/none svc:/system/filesystem/autofs (online)
dependency   require_all/none svc:/network/loopback (online)
dependency   require_all/none svc:/network/physical (online)
dependency   require_all/none svc:/system/cryptosvc (online)
dependency   require_all/none svc:/system/utmp (online)
dependency   require_all/restart file://localhost/etc/ssh/sshd_config (online)

1.1.1      SMF Çalışma mantığı

SMF ile çalıştırılan her bir servis için ayrı bir xml yapılandırma dosyası vardır.  Bu dosyalar /var/svc/manifest/ altında tutulmaktadır. Örneğin ssh servisinin FMRI(Fault Management Resource Identifier) yukarıda svc:/network/ssh olarak gözükmektedir. Bu servisin yapılandırma dosyası /var/svc/manifest/network/ altındaki ssh.xml dosyasıdır.

# more /var/svc/manifest/network/ssh.xml

<?xml version=”1.0″?>

<!DOCTYPE service_bundle SYSTEM “/usr/share/lib/xml/dtd/service_bundle.dtd.1″>

<!–

Copyright 2004 Sun Microsystems, Inc.  All rights reserved.         Use is subject to license terms.
ident   “@(#)ssh.xml    1.7     04/12/09 SMI”

NOTE:  This service manifest is not editable; its contents will
be overwritten by package or patch operations, including
operating system upgrade.  Make customizations in a different
file.
–>
<service_bundle type=’manifest’ name=’SUNWsshdr:ssh’>
<service
name=’network/ssh’
type=’service’
version=’1′>
<create_default_instance enabled=’false’ />
<single_instance />
<dependency name=’fs-local’
grouping=’require_all’
restart_on=’none’
type=’service’>
<service_fmri
value=’svc:/system/filesystem/local’ />
</dependency>

<exec_method
type=’method’
name=’start’
exec=’/lib/svc/method/sshd start’
timeout_seconds=’60′/>

1 Gbps trafikte sıfır paket kaybı

i-tap ve voitap projelerinin alt yapısında kullandığımız paket yakalama motorunun yeni sürümünde, 1 Gbps trafikte 10.000 pakette 18 adet paket kaybı ile neredeyse sıfıra yakın performansa ulaştık.

Bu gelişme, devam eden 10 Gigabit ve üstü paket yakalama performansı beklediğimiz yeni jenerasyon ürününlerimiz konusunda Ar-Ge ekibimizin doğru plan ve projeksiyon içinde olduğunu teyit etti.

PostgreSQL’e Hot Standby desteği eklendi

PostgreSQL geliştiricilerinden Simon Riggs geçtiğimiz Cuma günü PostgreSQL’e Hot Standby desteğinin commit edildiğini duyurdu.

Hot Standy özelliği sayesinde Log shipping replikasyon yöntemi ile yapılan standby sunucularında read-only sorgu çalıştırılabiliyor.  Konuyla ilgili detayları aşağıdaki adreslerden alabilirsiniz.

http://database-explorer.blogspot.com/2009/12/hot-standby-todo.html

http://database-explorer.blogspot.com/2009/09/im-currently-working-on-hot-standby.html

qmail multilog localtime patch for daemontools-0.76

For performance issue multilog binary in daemontools logs in TAI format like following:

@400000004a9b768834d8118c status: local 0/500 remote 4/299

You have to pipe output to tai64nlocal binary to see date in human readable format.  This is being annoying while searching in log files.

We created a small patch to enable human readable logging in multilog via localtime function. The new log lines will look like following:

Sat Dec 19 03:02:51 2009  status: local 0/500 remote 0/299

I belive that some people will not like this idea.  We found it useful and wanted to share with open source community.

The patch is located at http://files.endersys.com/patches/daemontools-0.76-localtime.patch


diff -ruN daemontools-0.76.orig/src/multilog.c daemontools-0.76/src/multilog.c
--- daemontools-0.76.orig/src/multilog.c        2001-07-12 19:49:49.000000000 +0300
+++ daemontools-0.76/src/multilog.c     2009-12-19 02:52:09.000000000 +0200
@@ -514,7 +514,8 @@
 }
 if (!linelen)
 if (flagtimestamp) {
-          timestamp(line);
+          /* timestamp(line); */
+          timestamplocal(line);
 line[25] = ' ';
 linelen = 26;
 }
diff -ruN daemontools-0.76.orig/src/timestamp.c daemontools-0.76/src/timestamp.c
--- daemontools-0.76.orig/src/timestamp.c       2001-07-12 19:49:49.000000000 +0300
+++ daemontools-0.76/src/timestamp.c    2009-12-19 02:53:02.000000000 +0200
@@ -1,7 +1,13 @@
+#include <sys/types.h>
+#include <time.h>
+#include <sys/time.h>
+#include <unistd.h>
 #include "taia.h"
 #include "timestamp.h"

 static char hex[16] = "0123456789abcdef";
+time_t lt;
+struct tm *t;

 void timestamp(char s[TIMESTAMP])
 {
@@ -18,3 +24,11 @@
 s[i * 2 + 2] = hex[nowpack[i] & 15];
 }
 }
+
+void timestamplocal(char s[TIMESTAMP])
+{
+      lt = time(NULL);
+      t = localtime(&lt);
+      asctime_r(t, s);
+      s[24] = ' ';
+}
diff -ruN daemontools-0.76.orig/src/timestamp.h daemontools-0.76/src/timestamp.h
--- daemontools-0.76.orig/src/timestamp.h       2001-07-12 19:49:49.000000000 +0300
+++ daemontools-0.76/src/timestamp.h    2009-12-19 02:52:17.000000000 +0200
@@ -4,5 +4,6 @@
 #define TIMESTAMP 25

 extern void timestamp(char *);
+extern void timestamplocal(char *);

 #endif

Endersys to attend ISS World in Dubai

Murat BALABAN, our Director of R&D Division,  will give a talk entitled “Network Level VoIP Interception with Voitap(tm)” at ISS World Middle East, on February 24, 2010 at 9:00-9:30 in Dubai.

The talk will be about voitap(tm), Endersys’ approach to VoIP LI at the network level, discussing the pros and cons of the network and service level interception as well as how voitap(tm) fits in the overall LI infrastructure of an institution to do the VoIP LI.

ISS World MEA is the world’s largest gathering of Middle East and African Law Enforcement, Intelligence and Homeland Security Analysts and Telecom Operators responsible for Lawful Interception, Electronic Investigations and Network Intelligence gathering. ISS World Programs present the methodologies and tools to bridge the chasms from lawful intercept data gathering to information creation to investigator knowledge to actionable intelligence.

issworld

qmail from address and SMTP-AUTH username check patch

qmail SMTP-AUTH control mechanism is very good way to stop spams and give flexibility user to send email from anywere in the world. But current SMTP-AUTH patches do not check whether from address and SMTP-AUTH username is same.

The following patch will simply reject the mail if the SMTP-AUTH username does not match with the from address.
To be enable use this patch SMTP-AUTH username must be in email address format (user@domain.com). This can be
possible only in qmail+vpopmail or qmail-ldap (if the uid is in email address format) installation.

This patch is based on netqmail-1.06 and Erwin Hoffmann’s qmail-authentication-0.68 patch. But I believe that you can simply integrate your qmail source.

PS:  qmail-remote-logging.patch and qmail-smtp-auth-fromcheck.patch are integrated into JMS1 combined patch and Shupp Toaster patch.

URLs:

http://files.endersys.com/patches/qmail-1.03-jms1.7.08_endersys.patch

http://files.endersys.com/patches/qmail-toaster-0.9.1_endersys.patch

INSTALLATION and CONFIGURATION

1.  Stop qmail
2. Apply this patch to your qmail toaster and compile it (don’t install!)
3. Take backup of your qmail-smtpd binary and override new qmail-smtpd binary
4. Create control/checksenderauth to enable this control
5. Start qmail

You can get the patch from here


--- qmail-smtpd.c.orig  2009-12-16 00:09:42.000000000 +0200
+++ qmail-smtpd.c       2009-12-16 00:20:34.000000000 +0200
@@ -1,3 +1,4 @@
+#include <sys/stat.h>
#include "sig.h"
#include "readwrite.h"
#include "stralloc.h"
@@ -346,6 +347,7 @@
out("250 ok\r\n");
}
void smtp_rcpt(arg) char *arg; {
+struct stat st;
if (!seenmail) { err_wantmail(); return; }
if (!addrparse(arg)) { err_syntax(); return; }
if (flagbarf) { err_bmf(); return; }
@@ -356,6 +358,22 @@
}
else
if (!addrallowed()) { err_nogateway(); return; }
+/* This small patch compare mail from value and smtp auth username.
+* if they are not identical,  the mail will not be relayed!
+* This control will be ignored, if the remote IP is defined in tcp.smtp.cdb
+* create/delete control/checksenderauth file to enable/disable this feature
+*  - Developed by Endersys Ltd R&D Team - http://www.endersys.com
+*/
+  if ((stat("control/checksenderauth",&st) == 0) && (remoteinfo)) {
+
+ /* remoteinfo:username issued during the smtp auth state
+ *   mailfrom.s: From value issued at mail from: state */
+        if (str_diff(remoteinfo, mailfrom.s))  {
+               out("535 Mail From address and SMTP-AUTH username does not match (#5.7.1)\r\n");
+                       return;
+       }
+ }
+

TÜBİTAK TEYDEB desteğinde birinci dönem başarıyla tamamlandı

Endersys, geliştirdiği yazılımlardan biri için aldığı TÜBİTAK TEYDEB (1507 KOBI Ar-GE) desteğinde birinci fazı başarıyla tamamladı. Yakın zamanda diğer iki yazılım projemiz içinde başvuruda bulunacağız.

Rapid7 firması, “Deloitte Technology Fast 500″ yazılım kategorisinde 15. sırada

Rapid7 firması son 5 yılda 2459% büyüme göstererek, “Deloitte Technology Fast 500” raporunda genelde 72. sırayı, yazılım kategorisinde 15. sırayı aldı.

Haberin detayını buradan adresinden okuyabilirsiniz.

Endersys, Rapid7 firmasının ürünü olan güvenlik zaafiyet yazılımı Nexpose‘ın Türkiye yetkili satıcısıdır.