|
1 | | -##Telegram messenger for Android |
| 1 | +[](https://github.com/Telegram-FOSS-Team/Telegram-FOSS/releases/latest) |
| 2 | +[](https://t.me/tfossofftopics) |
| 3 | + |
| 4 | +[](https://liberapay.com/Telegram-FOSS/) or <imgsrc="https://en.bitcoin.it/w/images/en/c/cb/BC_Logotype.png"alt="Bitcoin"height="25px" />`1P8kNcifVAkBWtWmjKY4RvVLy5QwruE2LQ` |
| 5 | + |
| 6 | +#Telegram-FOSS |
2 | 7 |
|
3 | 8 | [Telegram](https://telegram.org) is a messaging app with a focus on speed and security. It’s superfast, simple and free. |
4 | | -This repo contains the official source code for[Telegram App for Android](https://play.google.com/store/apps/details?id=org.telegram.messenger). |
5 | 9 |
|
6 | | -##Creating your Telegram Application |
| 10 | +This is an unofficial, FOSS-friendly fork of the original[Telegram App for Android](https://github.com/DrKLO/Telegram). |
| 11 | + |
| 12 | +This version of Telegram is available on FDroid: |
| 13 | + |
| 14 | +[<img src="https://f-droid.org/badge/get-it-on.png" |
| 15 | + alt="Get it on F-Droid" |
| 16 | + height="80">](https://f-droid.org/app/org.telegram.messenger) |
| 17 | + |
| 18 | +##Current Maintainers |
| 19 | + |
| 20 | +-[thermatk](https://github.com/thermatk) |
| 21 | +- you? :) |
| 22 | + |
| 23 | +##Contributors |
| 24 | + |
| 25 | +-[slp](https://github.com/slp) |
| 26 | +-[Bubu](https://github.com/Bubu) |
| 27 | +-[Sudokamikaze](https://github.com/Sudokamikaze) |
| 28 | +-[l2dy](https://github.com/l2dy) |
| 29 | +-[maximgrafin](https://github.com/maximgrafin) |
| 30 | +-[vn971](https://github.com/vn971) |
| 31 | +-[theel0ja](https://github.com/theel0ja) |
| 32 | +-[AnXh3L0](https://github.com/AnXh3L0) |
| 33 | +-[noplanman](https://github.com/noplanman) |
| 34 | +-[vk496](https://github.com/vk496) |
| 35 | +-[verdulo](https://github.com/verdulo) |
| 36 | +-[anupritaisno1](https://github.com/anupritaisno1) |
| 37 | +-[nekohasekai](https://github.com/nekohasekai) |
| 38 | +-[kdrag0n](https://github.com/kdrag0n) |
| 39 | +-[terachad](https://github.com/terachad) |
| 40 | +-[ppnplus](https://github.com/ppnplus) |
| 41 | +-[luvletter2333](https://github.com/luvletter2333) |
| 42 | +-[23rd](https://github.com/23rd) |
| 43 | +-[proletarius101](https://github.com/proletarius101) |
| 44 | +-[CWJamieson](https://github.com/CWJamieson) |
| 45 | +-[verdulo](https://github.com/verdulo) |
| 46 | +-[tehcneko](https://github.com/tehcneko) |
| 47 | + |
| 48 | +##Discussion |
| 49 | + |
| 50 | +Join the[Telegram-FOSS Offtopics group](https://t.me/tfossofftopics) |
| 51 | + |
| 52 | +You can also join`#telegram-foss:matrix.org` via[matrix](https://matrix.to/#/#telegram-foss:matrix.org) or`#telegram-foss` on freenode. |
| 53 | + |
| 54 | +##Changes: |
7 | 55 |
|
8 | | -We welcome all developers to use our API and source code to create applications on our platform. |
9 | | -There are several things we require from**all developers** for the moment. |
| 56 | +*Replacement of non-FOSS, untrustworthy or suspicious binaries or source code:* |
| 57 | +- Do location sharing with OpenStreetMap(osmdroid) instead of Google Maps |
| 58 | +- Use Noto emoji set instead of Apple's emoji |
| 59 | +- Google Play Services GCM replaced with Telegram's push service |
| 60 | +-[Has to show a notification on Oreo+, ask Google](Notifications.md) |
| 61 | +-**SECURITY:** BoringSSL prebuilts are replaced with recent upstream source code built at compile time |
| 62 | +-**SECURITY:** FFmpeg prebuilts are replaced with recent upstream source code built at compile time |
| 63 | +-**SECURITY:** libvpx prebuilts are replaced with recent upstream source code built at compile time |
| 64 | +-**SECURITY:** Bundled libWebP is updated |
10 | 65 |
|
11 | | -1.[**Obtain your own api_id**](https://core.telegram.org/api/obtaining_api_id) for your application. |
12 | | -2. Please**do not** use the name Telegram for your app — or make sure your users understand that it is unofficial. |
13 | | -3. Kindly**do not** use our standard logo (white paper plane in a blue circle) as your app's logo. |
14 | | -3. Please study our[**security guidelines**](https://core.telegram.org/mtproto/security_guidelines) and take good care of your users' data and privacy. |
15 | | -4. Please remember to publish**your** code too in order to comply with the licences. |
| 66 | +*Removal of non-FOSS, untrustworthy or suspicious binaries or source code and their functionality:* |
| 67 | +- Google Vision face detection and barcode scanning (Passport) |
| 68 | +- Google Wallet and Android Pay integration |
| 69 | +- Google Voice integration |
| 70 | +- HockeyApp crash reporting and self-updates |
| 71 | +- Google SMS retrieval |
| 72 | +- Google ML Kit |
16 | 73 |
|
17 | | -###API, Protocol documentation |
| 74 | +*Other:* |
| 75 | +- Added the ability to parse locations from intents containing a`geo:<lat>,<lon>,<zoom>` string |
| 76 | +- Force static map previews from Telegram |
| 77 | +- No content restrictions |
| 78 | + |
| 79 | +##Versioning |
| 80 | + |
| 81 | +This repository contains tags to make tracking versions easier. |
| 82 | + |
| 83 | +Versions are in form "v$UPSTREAM$RELEASE" where: |
| 84 | + |
| 85 | +* $UPSTREAM is the public, visible version of upstream. |
| 86 | +* $RELEASE is a letter ([a-z]) indicating minor releases between official versions (sometimes, upstream is updated without relating the changes to an specific version). |
| 87 | + |
| 88 | +##API, Protocol documentation |
18 | 89 |
|
19 | 90 | Telegram API manuals:https://core.telegram.org/api |
20 | 91 |
|
21 | 92 | MTproto protocol manuals:https://core.telegram.org/mtproto |
22 | 93 |
|
23 | | -###Compilation Guide |
| 94 | +##Building |
| 95 | + |
| 96 | +**NOTE: Building on Windows is, unfortunately, not supported. |
| 97 | +Consider using a Linux VM or dual booting.** |
| 98 | + |
| 99 | + |
| 100 | +**Important:** |
| 101 | + |
| 102 | +1. You need the Android NDK, Go(Golang) and[Ninja](https://ninja-build.org/) to build the apk. |
| 103 | + |
| 104 | +2. Don't forget to include the submodules when you clone: |
| 105 | +-`git clone --recursive https://github.com/Telegram-FOSS-Team/Telegram-FOSS.git` |
| 106 | + |
| 107 | +3. Build native FFmpeg and BoringSSL dependencies: |
| 108 | +- Go to the`TMessagesProj/jni` folder and execute the following (define the paths to your NDK and Ninja): |
| 109 | + |
| 110 | +``` |
| 111 | + export NDK=[PATH_TO_NDK] |
| 112 | + export NINJA_PATH=[PATH_TO_NINJA] |
| 113 | + ./build_libvpx_clang.sh |
| 114 | + ./build_ffmpeg_clang.sh |
| 115 | + ./patch_ffmpeg.sh |
| 116 | + ./patch_boringssl.sh |
| 117 | + ./build_boringssl.sh |
| 118 | + ``` |
24 | 119 |
|
25 | | -**Note**: In order to support[reproducible builds](https://core.telegram.org/reproducible-builds), this repo contains dummy release.keystore, google-services.json and filled variables inside BuildVars.java. Before publishing your own APKs please make sure to replace all these files with your own. |
| 120 | +4. If you want to publish a modified version of Telegram: |
| 121 | + - You should get **your own API key** here: https://core.telegram.org/api/obtaining_api_id and create a file called `API_KEYS` in the source root directory. |
| 122 | + The contents should look like this: |
| 123 | + ``` |
| 124 | + APP_ID = 12345 |
| 125 | + APP_HASH = aaaaaaaabbbbbbccccccfffffff001122 |
| 126 | + ``` |
| 127 | + - Do not use the name Telegram and the standard logo (white paper plane in a blue circle) for your app — or make sure your users understand that it is unofficial |
| 128 | + - Take good care of your users' data and privacy |
| 129 | + - **Please remember to publish your code too in order to comply with the licenses** |
26 | 130 |
|
27 | | -You will require Android Studio 3.4, AndroidNDK rev. 20 and Android SDK 8.1 |
| 131 | +The project can be built with AndroidStudio or from the command line with gradle: |
28 | 132 |
|
29 | | -1. Download the Telegram source code fromhttps://github.com/DrKLO/Telegram ( git clonehttps://github.com/DrKLO/Telegram.git ) |
30 | | -2. Copy your release.keystore into TMessagesProj/config |
31 | | -3. Fill out RELEASE_KEY_PASSWORD, RELEASE_KEY_ALIAS, RELEASE_STORE_PASSWORD in gradle.properties to access your release.keystore |
32 | | -4. Go tohttps://console.firebase.google.com/, create two android apps with application IDs org.telegram.messenger and org.telegram.messenger.beta, turn on firebase messaging and download google-services.json, which should be copied to the same folder as TMessagesProj. |
33 | | -5. Open the project in the Studio (note that it should be opened, NOT imported). |
34 | | -6. Fill out values in TMessagesProj/src/main/java/org/telegram/messenger/BuildVars.java – there’s a link for each of the variables showing where and which data to obtain. |
35 | | -7. You are ready to compile Telegram. |
| 133 | +`./gradlew assembleAfatRelease` |
36 | 134 |
|
37 | | -###Localization |
| 135 | +# DIGITAL RESISTANCE |
38 | 136 |
|
39 | | -We moved all translations tohttps://translations.telegram.org/en/android/. Please use it. |
| 137 | + |