Stars: 180
Forks: 42
Pull Requests: 225
Issues: 22
Watchers: 14
Last Updated: 2023-05-15 10:23:14
Telegram scenario-based API aimed at OSINT
License: MIT License
Languages: PHP, Shell, JavaScript, Dockerfile
A lot of Telegram API libraries around, but none of them demonstrates how to execute complex scenarios like draining all photos from channels, monitor users presence or register new account. This projects aims to correct situation: now you can easily create new scenarios and one-click execute existing ones.
Using Telegram API from official Android client.
Telegram protocol https://core.telegram.org/ has technically thorough and detailed documentation, but does not cover usage scenarios. Our goal is to make a library that implements some real-life OSINT usage scenarios, including:
First of all, add library to your app user composer:
composer require postuf/telegram-api-lib
To check out usage examples, go to examples
dir.
You need auth keys generated, run php registration.php
to get this.
Now you are all set, you can run any of examples, for example, php parseGroupMembers.php
, and check the output.
Verbose logging (all messages sent/received) is enabled by default, add --info
to arguments to suppress it.
docker build -t telegram-osint-lib .
docker run -d -t --name tg-osint-lib telegram-osint-lib
docker exec -it tg-osint-lib /bin/bash
php examples/registration.php
When you get AuthKey in registration script, you can use it the following way:
docker exec --env BOT=your-auth-key -i tg-osint-lib php examples/monitorNumbers.php -n 123123123
# if you save key to file
docker exec --env BOT=@auth-key-filename-in-docker -i tg-osint-lib php examples/monitorNumbers.php -n 123123123
2FA not supported.