repos
/
irgramd
/ annotate_shade
README update
Annotate for file README.md
2020-10-31 E.
1
# irgramd - IRC <-> Telegram Gateway
2019-07-17 Peter
2
2020-10-31 E.
3
irgramd is a gateway that allows connecting from an [IRC] client to
2022-02-23 E.
4
[Telegram] as a regular user (not bot).
2020-10-31 E.
5
01:11:52 '
6
irgramd is written in [python] (version 3), it acts as an IRC server
'
7
where an IRC client can connect and on the other side it's a Telegram client
2022-02-23 E.
8
using the [Telethon] library.
19:32:39 '
9
2023-04-26 E.
10
**[irgramd primary repository] is in [darcs] version control system, github
19:20:04 '
11
is used as [project management and secondary repository]**
'
12
'
13
**irgramd was forked from [pbui/irtelegramd], was heavily modified and
'
14
currently is a project on its own**
'
15
2024-08-31 E.
16
**irgramd is under active development, though usable, several
2023-04-26 E.
17
planned features are not implemented yet**
2022-02-23 E.
18
19:32:39 '
19
## How it works
'
20
'
21
Configure your IRC client to connect to irgramd (running on the same host or
'
22
on a remote host) then you will see in your IRC client the Telegram groups
'
23
as IRC channels and Telegram users as IRC users, if you send a message to a
'
24
user or channel in IRC it will go to the corresponding user or group in
'
25
Telegram, and the same from Telegram to IRC.
'
26
'
27
The users on Telegram using the official or other clients will see you with
'
28
your regular Telegram user account and will be indistinguishable for them
'
29
whether you are using irgramd or another Telegram client.
'
30
'
31
Several IRC clients can connect to irgramd but they will see the same
'
32
Telegram account, this allows connecting to the same Telegram account from
'
33
different IRC clients on different locations or devices, so one irgramd
'
34
instance only connects to one Telegram account, if you want to connect to
2023-12-07 E.
35
several Telegram accounts you will need to run several irgramd instances. If
20:16:12 '
36
all IRC clients are disconnected, irgramd will remain connected to Telegram.
'
37
'
38
irgramd can also be seen as a kind of bouncer ([BNC]), with the difference
'
39
that instead of talking IRC protocol on the client side, it talks Telegram
'
40
protocol (MTProto), and can hide the IP and location of the IRC client (if
'
41
executed in a different host).
2020-10-31 E.
42
2023-04-26 E.
43
## Features
19:20:04 '
44
'
45
- Channels, groups and private chats
'
46
- Users and channels mapped in IRC
'
47
- Messages (receive, send)
2024-04-21 E.
48
- Media in messages (receive, download, upload)
2023-06-26 E.
49
- Replies (receive, send)
2024-04-07 E.
50
- Forwards (receive, send)
2023-07-20 E.
51
- Deletions (receive, do)
2023-07-16 E.
52
- Editions (receive, do)
2024-10-20 E.
53
- Reactions (receive, send, remove)
2023-10-10 E.
54
- Polls (receive, show)
2023-11-28 E.
55
- Actions [pin message, channel photo] (receive)
2023-04-26 E.
56
- Dialogs management
2023-09-17 E.
57
- History
2023-04-26 E.
58
- Authentication and TLS for IRC
19:20:04 '
59
- Multiple connections from IRC
'
60
2023-04-27 E.
61
## Requirements
21:01:01 '
62
2023-05-06 E.
63
- [python] (>= v3.9)
2023-04-27 E.
64
- [telethon] (tested with v1.28.5)
21:01:01 '
65
- [tornado] (tested with v6.1.0)
'
66
- [aioconsole] (tested with v0.6.1)
2023-06-26 E.
67
- [pyPAM] (optional, tested with v0.4.2-13.4 from deb, [legacy web](https://web.archive.org/web/20110316070059/http://www.pangalactic.org/PyPAM/))
20:55:35 '
68
2023-07-09 E.
69
## Instalation
22:56:15 '
70
'
71
### From darcs
'
72
'
73
darcs clone https://src.presi.org/repos/darcs/irgramd
'
74
chmod +x irgramd/irgramd
'
75
'
76
### From git
'
77
'
78
git clone https://github.com/prsai/irgramd.git
'
79
chmod +x irgramd/irgramd
'
80
'
81
## Configuration
'
82
'
83
From irgramd directory `./irgramd --help` will show all configuration
'
84
options available, these options can be used directy in the command line or
'
85
in a file.
'
86
'
87
When used in command line the separator is `-` (dash) with two leading
'
88
dashes, example: `--api-hash`.
'
89
'
90
When used in a file the separator is `_` (underscore) without two leading
'
91
dashes nor underscores, example: `api_hash`. The syntax of this file is just
'
92
Python so strings are surrounded by quotes (`'`) and lists by brackets (`[]`).
'
93
'
94
A sample of the configuration file is provided, copy it to the default
'
95
configuration location:
'
96
'
97
mkdir -p ~/.config/irgramd
'
98
cp irgramd/irgramdrc.sample ~/.config/irgramd/irgramdrc
'
99
'
100
And modified it with your API IDs and preferences.
'
101
'
102
## Usage
'
103
'
104
From irgramd directory, in foreground:
'
105
'
106
./irgramd
'
107
2023-12-31 E.
108
In background (with logs):
00:26:30 '
109
'
110
./irgramd --log-file=irgramd.log &
2023-07-09 E.
111
2023-06-26 E.
112
## Notes
20:55:35 '
113
'
114
PAM authentication: it allows to authenticate IRC users from the system in
'
115
Unix/Linux. The user that executes irgramd must have permissions to use PAM
2023-07-09 E.
116
(e.g. in Linux be in the shadow group or equivalent). The dependency is
2023-06-27 E.
117
totally optional, if not used, the module pyPAM is not needed.
2023-04-27 E.
118
2024-04-28 E.
119
## Inspired by
11:16:24 '
120
'
121
- [telegramircd]
'
122
- [ibotg]
'
123
- [bitlbee]
'
124
2022-02-20 E.
125
## License
01:25:27 '
126
2023-07-16 E.
127
Copyright (c) 2019 Peter Bui <pbui@bx612.space>
2024-04-07 E.
128
Copyright (c) 2020-2024 E. Bosch <presidev@AT@gmail.com>
2022-02-20 E.
129
01:25:27 '
130
Use of this source code is governed by a MIT style license that
'
131
can be found in the LICENSE file included in this project.
'
132
2019-10-04 ãÂÂ
133
[IRC]: https://en.wikipedia.org/wiki/Internet_Relay_Chat
2020-10-31 E.
134
[Telegram]: https://telegram.org/
01:11:52 '
135
[python]: https://www.python.org/
'
136
[Telethon]: https://github.com/LonamiWebs/Telethon
2022-02-23 E.
137
[irgramd primary repository]: https://src.presi.org/darcs/irgramd
19:32:39 '
138
[darcs]: http://darcs.net
2023-04-26 E.
139
[project management and secondary repository]: https://github.com/prsai/irgramd
2020-10-31 E.
140
[pbui/irtelegramd]: https://github.com/pbui/irtelegramd
2023-04-27 E.
141
[python]: https://www.python.org
21:01:01 '
142
[tornado]: https://www.tornadoweb.org
'
143
[aioconsole]: https://github.com/vxgmichel/aioconsole
2023-06-26 E.
144
[pyPAM]: https://packages.debian.org/bullseye/python3-pam
2023-12-07 E.
145
[BNC]: https://en.wikipedia.org/wiki/BNC_(software)
2024-04-28 E.
146
[telegramircd]: https://github.com/prsai/telegramircd
11:16:24 '
147
[ibotg]: https://github.com/prsai/ibotg
'
148
[bitlbee]: https://www.bitlbee.org