Adds support for Telegram to Pidgin, Adium, Finch and other Libpurple based messengers.
Find a file
2015-08-25 21:58:58 +02:00
imgs Better icons 2014-11-24 23:01:58 +03:00
lodepng Move lodepng into separate folder 2015-01-02 22:03:47 +01:00
rpm Bump version 2015-08-25 21:58:58 +02:00
telegram-adium Remove makefile as dependency from XCode project, only caused trouble 2015-08-22 12:27:34 +02:00
tgl@126b42c6d2 Update libtgl and fix receiving file transfers of audio and video documents 2015-08-22 13:34:53 +02:00
.gitignore small bugfixes 2014-11-17 16:27:01 +03:00
.gitmodules Set submodule url back to upstream 2015-05-31 17:43:31 +02:00
CHANGELOG.md Update version 2015-05-31 16:01:09 +02:00
config.h.in Add support for displaying stickers in chats 2015-05-24 00:22:31 +02:00
configure Bump version 2015-08-25 21:58:58 +02:00
configure.ac Bump version 2015-08-25 21:58:58 +02:00
install-sh Updated to use subdirectory. Fixed buffer overflow in date format 2014-11-12 21:23:01 +03:00
m4_ax_check_openssl.m4 Updated to use subdirectory. Fixed buffer overflow in date format 2014-11-12 21:23:01 +03:00
m4_ax_check_zlib.m4 Updated to use subdirectory. Fixed buffer overflow in date format 2014-11-12 21:23:01 +03:00
Makefile.in Update to libtgl v2 2015-05-23 00:18:26 +02:00
Makefile.tgl Do not include unused net and timer objects in tgl 2015-05-29 19:47:29 +02:00
Makefile.tl-parser Fix submodule makefiles 2015-01-16 16:29:17 +01:00
mime.types Updated to latest version of libtgl 2014-11-18 17:45:19 +03:00
msglog.c Repository cleanup and housekeeping 2015-03-12 01:56:16 +01:00
msglog.h Repository cleanup and housekeeping 2015-03-12 01:56:16 +01:00
README.md Bump version 2015-08-25 21:58:58 +02:00
telegram-base.c Clean up and update README 2015-08-22 13:13:19 +02:00
telegram-base.h Update libtgl 2015-08-16 21:35:43 +02:00
telegram-purple.c Rework buddy list handling 2015-08-22 13:07:11 +02:00
telegram-purple.h Support for joining chats by invite link 2015-07-24 14:26:13 +02:00
tg-server.pub Slightly working version 2014-11-11 20:21:14 +03:00
tgp-2prpl.c Clean up and update README 2015-08-22 13:13:19 +02:00
tgp-2prpl.h Rework buddy list handling 2015-08-22 13:07:11 +02:00
tgp-chat.c fix bug 2015-07-24 14:28:18 +02:00
tgp-chat.h Repository cleanup and housekeeping 2015-03-12 01:56:16 +01:00
tgp-ft.c Try to fix secret chat corruption 2015-08-25 21:54:15 +02:00
tgp-ft.h Update libtgl and fix receiving file transfers of audio and video documents 2015-08-22 13:34:53 +02:00
tgp-msg.c Try to fix secret chat corruption 2015-08-25 21:54:15 +02:00
tgp-msg.h Repository cleanup and housekeeping 2015-03-12 01:56:16 +01:00
tgp-net.c remove unused functions and clean up 2015-07-11 17:44:49 +02:00
tgp-net.h Remove exponential timeouts to prevent segfaults 2015-01-09 11:56:03 +01:00
tgp-structs.c Improve error handling 2015-08-01 23:34:00 +02:00
tgp-structs.h Update libtgl and fix receiving file transfers of audio and video documents 2015-08-22 13:34:53 +02:00
tgp-timers.c Repository cleanup and housekeeping 2015-03-12 01:56:16 +01:00
tgp-timers.h Slightly working version 2014-11-11 20:21:14 +03:00
tgp-utils.c Revise media message handling 2015-07-30 11:45:50 +02:00
tgp-utils.h Revise media message handling 2015-07-30 11:45:50 +02:00

Telegram-Purple Unofficial (Beta 3)

Telegram-purple is a Libpurple plugin that adds support for the Telegram messenger.

Beta 2

- update to libtgl 2
- support two-factor authentication
- improve sticker support
- add option to control message read recipes
- many bugfixes

If you migrate from an older version, the Telegram authentication files have been moved to .purple/telegram-purple. If you want to keep your old secret chats, please copy it manually from ~/.telegram-purple, otherwise you will be prompted for a new SMS code.

Build

Below, you will find instructions on how to build the libpurple protocol plugin. If you just want to use the plugin in Adium, download precompiled packages here..

1. Clone

This repository has submodules, so you need to clone recursively.

    git clone --recursive https://github.com/majn/telegram-purple
    cd telegram-purple

2. Fetch all dependencies

Fedora
    sudo yum install gcc openssl-devel glib2-devel libpurple-devel libwebp-devel
Debian / Ubuntu
    sudo apt-get install libssl-dev libglib2.0-dev libpurple-dev libwebp-dev
OpenSUSE
    sudo zypper install gcc glib glib-devel libpurple libpurple-devel zlib-devel openssl libopenssl-devel libwebp-devel

3. Compile and install

If libwebp is not available, you can disable sticker support by calling ./configure --disable-libweb instead.

    ./configure
    make
    sudo make install

Pulling Updates

This repository contains submodules and just a simple pull won't be enough to update all submodule files. Pull new changes with:

    git pull
    git submodule update --recursive

Usage

First Login

The username is your current phone number, including your full country prefix. For Germany, this would be '+49', resulting in a user name like '+49151123456'. Telegram will verify your phone number by sending you a code via sms. You will be prompted for this code, once that happens.

Buddy List

Like in the official Telegram apps, the displayed buddy list consists of all active conversations.

Foreign Users

Foreign users, like for example people you only know through a group chat but never had any conversation with, will not be part of your buddy list by default. You can add those users to the buddy list by clicking on "Add contact..." in the users context menu.

Using secret chats

You can use Telegram secret chats with this plugin, they will show up as a new buddy with a '!' in front of the buddy name.

One caveat of secret chats in Telegram is that they can only have one endpoint, this is a limitation of the protocol. This means that if you create a secret chat in Pidgin you will not be able to use that chat on your phone. You will be asked whether to accept each secret chat, so you can always choose to accept the chat on a different device if you want. You can set a default behavior for dealing with secret chats (Accept or Decline) in the account settings if you don't want that prompt to appear every time.

Self destructive messages will be ignored, since I don't know any way to delete them from the conversation and the history.

Confirming the key authenticity

Click on the buddy in the buddy list and click on "Show Info" to visualize the key fingerprint.

Confirm key authenticity

Initiate secret chats

To initiate a secret chat from Pidgin, click on a Buddy in the Buddy List and hit "Start Secret Chat"

Deleting secret chats

If you delete a secret chat from the buddy list, it will be terminated and no longer be usable.

Unicode Emojis for Pidgin

The Telegram phone applications for iOS and Android make use of standardized Unicode smileys (called Emojis). Pidgin does not display those smileys natively, but you can install a custom smiley theme like (https://github.com/stv0g/unicode-emoji) or (https://github.com/VxJasonxV/emoji-for-pidgin) and activate it under Settings > Themes > Smiley Theme.

Building the Adium Plugin

Compiling with XCode is a little bit problematic, since it requries you to compile Adium first to get the necessary framework files. My advice is to just use the prebuild bundle, but if you really want to do it, follow those steps.

  1. Get the Adium source, compile it with XCode and copy the build output into telegram-adium/Frameworks/Adium. It should contain at least Adium.framework, AdiumLibpurple.framework and AIUitilies.framework

  2. Open the Adium source code, go to ./Frameworks and copy libglib.framework and libpurple.framework into telegram-adium/Frameworks/Adium

  3. Build the tgl submodule and delete libtgl.so from libs/ (it should only contain libtgl.a)

  4. Install libwebp with homebrew, move into copy it into your project

    brew install webp cp /usr/local/Cellar/webp/0.4.3/lib/libwebp.a ./telegram-adium/Frameworks/

  5. Build the XCode-Project and execute the created bundle

Authors

Telegram-Purple was written by:

- Matthias Jentsch <mtthsjntsch@gmail.com>
- Vitaly Valtman
- Christopher Althaus <althaus.christopher@gmail.com>
- Markus Endres <endresma45241@th-nuernberg.de>

Acknowledgements

This software is based on the library Libtgl, which was written by Vitaly Valtman mail@vysheng.ru and others, see (http://github.com/vysheng/tgl)

For PNG rendering, it includes the lodepng library.

This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit. (http://www.openssl.org/)

This product includes cryptographic software written by Eric Young (eay@cryptsoft.com)