How the BBM Android Application Get the Incoming Message

The routine to process incoming and outgoing message resides in This is after the library is loaded and proper authentication process is done successfully.

After is loaded and functional, periodically it will call a method in BbmCoreService class called prv_msgFromService. This is the incoming messages, which has many types, including advertising messages. This in turn will call the callback and other necessary routines, such as notifications, etc.

Likewise, the outgoing message is constructed to suitable format before sending it via the native method called prv_msgToService, also in

Hope this small burst of information can help 🙂

After more detailed examination, I can added that the routine to handle incoming message resides in native library. It is implemented using socket, connect, select and recv socket functions.

On the start up of this library (i.e. the, it tries to connect to one of the BBM server IP Addresses, which is from to, using SOCK_DGRAM connection type.

The received data is in encrypted form, and it is decrypted locally using SSL_read combined with BIO_write function, after properly set up the link between BIO and SSL functions using SSL_set_bio.

After the received data is processed, the routine will perform write to the created write end point of the pipe from routines. This will trigger the necessary functions such as showing the Notification with is BBM tone, etc.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: