Thursday, May 6, 2010

012 Smile - Voice box after router

How to connect 012 voice box after your router and control it.

This is my device

Make: AudioCodes
Model: MP-202 (012 uses MP-202/012/CBL)
I got with M.Date 12/2008

user@wazup:~$ sudo nmap -sS -O 10.100.101.1

Starting Nmap 5.00 ( http://nmap.org ) at 2010-05-06 01:24 IDT
Interesting ports on 10.100.101.1:
Not shown: 995 closed ports
PORT     STATE    SERVICE
23/tcp   filtered telnet
443/tcp  open     https
992/tcp  open     telnets
8080/tcp open     http-proxy
8443/tcp open     https-alt
MAC Address: 00:90:8F:09:93:DC (Audio Codes)
Device type: general purpose
Running: Linux 2.4.X
OS details: Linux 2.4.18 - 2.4.35 (likely embedded)

Also another suspicious ports
2555 open uknown
8023 open unknown
2945/sctp filtered h248-binary
7626/sctp filtered simco

UDP scan took 20 minutes.
user@wazup:~$ sudo nmap -sU 10.100.101.1

Starting Nmap 5.00 ( http://nmap.org ) at 2010-05-06 01:26 IDT
Interesting ports on 10.100.101.1:
Not shown: 983 closed ports
PORT STATE SERVICE
53/udp open|filtered domain
67/udp open|filtered dhcps
68/udp open|filtered dhcpc
161/udp open|filtered snmp
789/udp open|filtered unknown
965/udp open|filtered unknown
1007/udp open|filtered unknown
1105/udp open|filtered unknown
1900/udp open|filtered upnp
16503/udp open|filtered unknown
20678/udp open|filtered unknown
21524/udp open|filtered unknown
21644/udp open|filtered unknown
21780/udp open|filtered unknown
21898/udp open|filtered unknown
49173/udp open|filtered unknown
55043/udp open|filtered unknown
MAC Address: 00:90:8F:09:93:DC (Audio Codes)

So, to place this box after your router and control it, you need to connect your PC via cable in LAN/PC port, wait for IP address from it, check a Gateway IP and use it in browser with 8080 port (https://GATEWAY-IP/ also works). Username is "user", password is "wel-012!" (all without quotes). Set Connection Type to "Automatic IP Address Ethernet Connection".

No you need to set QoS rules for SIP and RTP protocols - this will help prioritize voice traffic over other, so when you need to call, your torrent will not affect you, because voice will get high priority.
Ports are 5060, 5061, 5004, 5005.

If support guys can't reach it, setup port forwarding to black box, they should be happy.

Led indication
SIP registration status LED indication - a successful registration ('online' state) is indicated by a LED flashing slowly (a very short flash every 4 seconds). This indication is per phone line.
The LEDs labeled 'Phone 1' and 'Phone 2'reflect the status of the phones connected to the MP-202:
ON - During power-up and when the phone is off-hook.
OFF - Normal / the phone is on-hook
Flashing - Phone is ringing

See also about that in Hebrew

Wednesday, May 5, 2010

Learning Adobe Flex

Last week I learned some Adobe Flex.
They got great video course - Flex in a Week - recommended if you want a smooth start without too much reading.

In frame of this week, I did a small project - company car chooser. Most big companies (like mine Cisco) offer to their employees leased cars. Sometimes it profitable, sometimes not (out of this article scope).

So, people should choose a car and CarChooser will help them to make a first choice (or minimize options) by simple criteria filtering like budget, major car specs, tax rates (for Israel). It uses Google Image Search service for preview images, so it's very cool. Before that we have simple cars table with names and links to makes pages. You need to open 5-10 links until you find how much you will pay, how it looks like and can you use trunk for folding bikes with food at once.

Online demo
Source code on GitHub

See also
Flex developer center
Flex/AIR Application Scope Tips

Thursday, April 29, 2010

Hertz ads fail

Wednesday, March 24, 2010

Реклама месных израильских забегаловок такая аппетитная...



Аж блевать тянет... FML

Wednesday, February 24, 2010

PHP

I was unable to install today PECL extention PDO_MYSQL via

sudo pecl install PDO_MYSQL


The problem was that after configure, make can't find mysql header files.

...
In file included from /tmp/pear/temp/PDO_MYSQL/pdo_mysql.c:31:
/tmp/pear/temp/PDO_MYSQL/php_pdo_mysql_int.h:25:19: mysql.h: No such file or directory
In file included from /tmp/pear/temp/PDO_MYSQL/pdo_mysql.c:31:
/tmp/pear/temp/PDO_MYSQL/php_pdo_mysql_int.h:36: error: syntax error before "MYSQL"
...


So I learned how to make an extension manually.
I ran locate mysql.h, copyed all mysql headers from there to current folder and now you can make it

phpize --clean
phpize
./configure
make


make install won't worked for me.
pdo_mysql.so placed in modules dir, copy it to extentions dir (php -i | grep extension_dir) and enable in php.ini.

These steps will not add PDO_MYSQL under the PEAR, so you need to maintain it by yourself. But to update list of installed packages, you can do this trick

sudo pecl install -rB pdo_mysql

-r means do not install files, only register the package as installed
-B means don't build C extensions

Some other good to read links
Topic : pdo_mysql.so driver Installation