Telegram C# C2 - A Command As Well As Command Tool For Telegram Bot Communication

Telegram C# C2 - A Command As Well As Command Tool For Telegram Bot Communication - Hi friends mederc, In the article that you read this time with the title Telegram C# C2 - A Command As Well As Command Tool For Telegram Bot Communication, We have prepared this article well for you to read and retrieve information from it. hopefully fill the posts Article Telegra_Csharp_C2, Article Telegram, Article Telegram C# C2, we write this you can understand. Alright, happy reading.

Title : Telegram C# C2 - A Command As Well As Command Tool For Telegram Bot Communication
link : Telegram C# C2 - A Command As Well As Command Tool For Telegram Bot Communication

ALSO READ


Telegram C# C2 - A Command As Well As Command Tool For Telegram Bot Communication


Command together with Control for C# Writing
Author: Leiothrix
Telegram: @Leiothrix
Twitter: @wh4am1
Team: QQ愛&Love

Install

Nuget download these package
using System.IO; using Telegram.Bot; using Telegram.Bot.Args; using Telegram.Bot.Types.InputFiles; using AForge.Video; using AForge.Controls; using AForge.Video.DirectShow;

Add related classes inwards 'References'
System.Drawing; System.Windows.Forms;

How to used

Modify your Token to the program
 static void Main(){             botClient = novel TelegramBotClient("token");  //Your Token             botClient.OnMessage += Bot_OnMessage;             botClient.StartReceiving();             Thread.Sleep(int.MaxValue); }


have adept fun.

Proxy

TelegramBotClient allows you lot to role a proxy for Bot API connections.

HTTP

You tin hand the axe overstep an IWebProxy to bot customer for HTTP Proxies.
 // using System.Net;   var httpProxy = novel WebProxy("https://example.org", 8080)  {       Credentials = novel NetworkCredential("USERNMAE", "PASSWORD")  };  var botClient = novel TelegramBotClient("YOUR_API_TOKEN", httpProxy);

SOCKS 5

You tin hand the axe role an external NuGet package: HttpToSocks5Proxy provided
// using MihaZupan;  var proxy = novel HttpToSocks5Proxy(Socks5ServerAddress, Socks5ServerPort);  // Or if you lot postulate credentials for your proxy server: var proxy = novel HttpToSocks5Proxy(   Socks5ServerAddress, Socks5ServerPort, "USERNAME", "PASSWORD" );  // Allows you lot to role proxies that are alone allowing connections to Telegram // Needed for around proxies proxy.ResolveHostnamesLocally = true;  var botClient = novel TelegramBotClient("YOUR_API_TOKEN", proxy);

How to compile

How to compile all DLL files into an EXE file

First,You postulate download ILMerge tool,this is a tool for merging all references to .NET programs.
ilmerge.exe /target:exe /out:TGbot.exe ConsoleApp1.exe  AForge.Controls.dll AForge.dll AForge.Imaging.dll AForge.Math.dll AForge.Video.DirectShow.dll AForge.Video.dll Newtonsoft.Json.dll Telegram.Bot.dll /targetplatform:v4

/target -> library=>DLL exe=>exe

/targetplatform:v4 -> Compiler platform is .net 4.0

/out -> Merged output file,Parameters are followed past times files that postulate to last merged
Finally, generate output inwards the directory specified past times the out parameter




Thus the article Telegram C# C2 - A Command As Well As Command Tool For Telegram Bot Communication

That's all the article Telegram C# C2 - A Command As Well As Command Tool For Telegram Bot Communication this time, hopefully can benefit you all. okay, see you in another article posting.

You are now reading the article Telegram C# C2 - A Command As Well As Command Tool For Telegram Bot Communication with the link address https://mederc.blogspot.com/2013/01/telegram-c-c2-command-as-well-as.html

Iklan Atas Artikel

Iklan Tengah Artikel 1

Iklan Tengah Artikel 2

Iklan Bawah Artikel