1 | = Skype plugin for BitlBee |
---|
2 | Miklos Vajna <vmiklos-at-vmiklos-dot-hu> |
---|
3 | |
---|
4 | == Status |
---|
5 | |
---|
6 | [quote, Wilmer van der Gaast (author of BitlBee)] |
---|
7 | ____ |
---|
8 | Okay, this exists now, with lots of thanks to vmiklos for his *excellent* |
---|
9 | work!! |
---|
10 | |
---|
11 | It's not in the main BitlBee and it'll never be for various reasons, but |
---|
12 | because it's a plugin that shouldn't be a problem. |
---|
13 | ____ |
---|
14 | |
---|
15 | One day I browsed the BitlBee bugtracker and found |
---|
16 | http://bugs.bitlbee.org/bitlbee/ticket/82[this] ticket. Then after a while I |
---|
17 | returned and saw that it was still open. So I wrote it. |
---|
18 | |
---|
19 | It's pretty stable, I use it for my daily work. Being a plug-in, no patching |
---|
20 | is required, you can just install it after installing BitlBee itself. |
---|
21 | |
---|
22 | NOTE: You will see that this implementation of the Skype plug-in still requires |
---|
23 | a Skype instance to be running. This is because I'm not motivated to reverse |
---|
24 | engineer Skype's |
---|
25 | http://en.wikipedia.org/wiki/Skype_Protocol#Obfuscation_Layer[obfuscation |
---|
26 | layer]. (Not mentioning that you should ask your lawyer about if it is legal or |
---|
27 | not..) |
---|
28 | |
---|
29 | == Requirements |
---|
30 | |
---|
31 | * Skype >= 1.4.0.99. The latest version I've tested is 2.0.0.68. |
---|
32 | * BitlBee >= 1.2.1. Use old versions (<=0.5.1) if you have 1.2 or |
---|
33 | 1.1.1dev installed. |
---|
34 | * Skype4Py >= 0.9.28.7. Previous versions won't work due to API changes. |
---|
35 | |
---|
36 | NOTE: I had not had time to add support for 1.x yet. |
---|
37 | |
---|
38 | * Python >= 2.5. Skype4Py does not work with 2.4. |
---|
39 | * PyGObject >= 2.8.0. Older versions are part of PyGTK. (And you don't want to |
---|
40 | install GTK for nothing, right?) |
---|
41 | * pyopenssl or python-gnutls. |
---|
42 | |
---|
43 | `bitlbee-skype` has been tested under Linux and Mac OS X. Skype and Skype4py is |
---|
44 | available under Windows, too, so it probably works, but this has not been tested. |
---|
45 | |
---|
46 | == How to set it up |
---|
47 | |
---|
48 | Before you start. The setup is the following: BitlBee can't connect directly to |
---|
49 | Skype servers (the company's ones). It needs a running Skype client to do so. |
---|
50 | In fact BitlBee will connect to `skyped` (a tcp server, provided in this |
---|
51 | package) and `skyped` will connect to to your Skype client. |
---|
52 | |
---|
53 | The benefit of this architecture is that you can run Skype and `skyped` |
---|
54 | on a machine different to the one where you run BitlBee (it can be even |
---|
55 | a public server) and/or your IRC client. |
---|
56 | |
---|
57 | NOTE: The order is important. First `skyped` starts Skype. Then `skyped` |
---|
58 | connects to Skype, finally BitlBee can connect to `skyped`. |
---|
59 | |
---|
60 | === Installing under Frugalware |
---|
61 | |
---|
62 | - Install the necessary packages: |
---|
63 | |
---|
64 | ---- |
---|
65 | # pacman-g2 -S bitlbee-skype |
---|
66 | ---- |
---|
67 | |
---|
68 | and you don't have to compile anything manually. |
---|
69 | |
---|
70 | === Installing under Debian |
---|
71 | |
---|
72 | - Install the necessary development package: |
---|
73 | |
---|
74 | ---- |
---|
75 | # apt-get install bitlbee-dev |
---|
76 | ---- |
---|
77 | |
---|
78 | and you have to install `bitlbee-skype` and `skype4py` from source. |
---|
79 | |
---|
80 | === Installing from source |
---|
81 | |
---|
82 | - You need the latest stable BitlBee release: |
---|
83 | |
---|
84 | ---- |
---|
85 | $ wget http://get.bitlbee.org/src/bitlbee-1.2.tar.gz |
---|
86 | $ tar xf bitlbee-1.2.tar.gz |
---|
87 | $ cd bitlbee-1.2 |
---|
88 | ---- |
---|
89 | |
---|
90 | NOTE: You no longer need additional patches, as of version 1.1.1dev. |
---|
91 | |
---|
92 | - Now compile and install it: |
---|
93 | |
---|
94 | ---- |
---|
95 | $ ./configure |
---|
96 | $ make |
---|
97 | # make install install-dev |
---|
98 | ---- |
---|
99 | |
---|
100 | - Get the plugin code (in an empty dir, or whereever you want, it does |
---|
101 | not matter): |
---|
102 | |
---|
103 | ---- |
---|
104 | $ wget http://vmiklos.hu/project/bitlbee-skype/bitlbee-skype-@VERSION@.tar.gz |
---|
105 | $ tar xf bitlbee-skype-@VERSION@.tar.gz |
---|
106 | $ cd bitlbee-skype-@VERSION@ |
---|
107 | ---- |
---|
108 | |
---|
109 | - Compile and install it: |
---|
110 | |
---|
111 | ---- |
---|
112 | $ ./configure |
---|
113 | $ make |
---|
114 | # make install |
---|
115 | ---- |
---|
116 | |
---|
117 | This will install the plugin to where BitlBee expects them, which is |
---|
118 | `/usr/local/lib/bitlbee` if you installed BitlBee from source. |
---|
119 | |
---|
120 | - To install http://skype4py.sourceforge.net/[Skype4Py] from source: |
---|
121 | |
---|
122 | ---- |
---|
123 | $ tar -zxvf Skype4Py-x.x.x.x.tar.gz |
---|
124 | $ cd Skype4Py-x.x.x.x |
---|
125 | # python setup.py install |
---|
126 | ---- |
---|
127 | |
---|
128 | === Configuring |
---|
129 | |
---|
130 | - Edit `/usr/local/etc/skyped/skyped.conf`: adjust `username` and `password`. The |
---|
131 | `username` should be your Skype login and the `password` can be whatever you |
---|
132 | want, but you will have to specify that one when adding the Skype account to |
---|
133 | BitlBee (see later). |
---|
134 | |
---|
135 | NOTE: Here, and later - `/usr/local/etc` can be different on your installation |
---|
136 | if you used the `--sysconfdir` switch when running bitlbee-skype's `configure`. |
---|
137 | |
---|
138 | - Generate the SSL pem files: |
---|
139 | |
---|
140 | ---- |
---|
141 | # cd /usr/local/etc/skyped |
---|
142 | # openssl req -new -x509 -days 365 -nodes -config skyped.cnf -out skyped.cert.pem \ |
---|
143 | -keyout skyped.key.pem |
---|
144 | ---- |
---|
145 | |
---|
146 | NOTE: Maybe you want to adjust the permissions in the `/usr/local/etc/skyped` |
---|
147 | dir. For example make it readable by just your user. |
---|
148 | |
---|
149 | - If both pyopenssl and python-gnutls are available, then python-gnutls |
---|
150 | will be used. This behaviour can be overwritten by: |
---|
151 | |
---|
152 | ---- |
---|
153 | $ export SKYPED_NO_GNUTLS=1 |
---|
154 | ---- |
---|
155 | |
---|
156 | - Start `skyped` (the tcp server): |
---|
157 | |
---|
158 | ---- |
---|
159 | $ skyped |
---|
160 | ---- |
---|
161 | |
---|
162 | - Start your `IRC` client, connect to BitlBee and add your account: |
---|
163 | |
---|
164 | ---- |
---|
165 | account add skype <user> <pass> |
---|
166 | account set skype/server localhost |
---|
167 | ---- |
---|
168 | |
---|
169 | <user> should be your Skype account name, <pass> should be the one you declared |
---|
170 | in `skyped.conf`. If you want to run skyped on a remote machine, replace |
---|
171 | `localhost` with the name of the machine. |
---|
172 | |
---|
173 | If you are running skyped on a custom port: |
---|
174 | |
---|
175 | ---- |
---|
176 | account set skype/port <port> |
---|
177 | ---- |
---|
178 | |
---|
179 | If you want to set your full name (optional): |
---|
180 | |
---|
181 | ---- |
---|
182 | account set skype/display_name "John Smith" |
---|
183 | ---- |
---|
184 | |
---|
185 | If you want to see your skypeout contacts online as well (they are |
---|
186 | offline by default): |
---|
187 | |
---|
188 | ---- |
---|
189 | account set skype/skypeout_offline false |
---|
190 | ---- |
---|
191 | |
---|
192 | == Setting up Skype in a VNC server (optional) |
---|
193 | |
---|
194 | Optionally, if you want to run Skype on a server, you might want to setup up |
---|
195 | a `VNC` server as well. I used `tightvnc` but probably other `VNC` servers will |
---|
196 | work, too. |
---|
197 | |
---|
198 | First run |
---|
199 | |
---|
200 | ---- |
---|
201 | $ vncpasswd ~/.vnc/passwd |
---|
202 | ---- |
---|
203 | |
---|
204 | and create a password. You will need it at least once. |
---|
205 | |
---|
206 | Now create `~/.vnc/xstartup` with the following contents: |
---|
207 | |
---|
208 | ---- |
---|
209 | #!/bin/sh |
---|
210 | |
---|
211 | twm |
---|
212 | ---- |
---|
213 | |
---|
214 | Adjust the permissions: |
---|
215 | |
---|
216 | ---- |
---|
217 | $ chmod +x ~/.vnc/xstartup |
---|
218 | ---- |
---|
219 | |
---|
220 | Then start the server: |
---|
221 | |
---|
222 | ---- |
---|
223 | $ vncserver |
---|
224 | ---- |
---|
225 | |
---|
226 | Then connect to it, start an `xterm`, set up Skype (username, password, |
---|
227 | enable X11 API and allow the `Skype4Py` client), quit from Skype, and |
---|
228 | start `skyped`. If you want to watch its traffic, enable debug messages |
---|
229 | and foreground mode: |
---|
230 | |
---|
231 | ---- |
---|
232 | $ skyped -n -d |
---|
233 | ---- |
---|
234 | |
---|
235 | == Features |
---|
236 | |
---|
237 | - Download nicks and away statuses from Skype |
---|
238 | |
---|
239 | - Noticing joins / parts while we're connected |
---|
240 | |
---|
241 | - Sending messages |
---|
242 | |
---|
243 | - Receiving messages |
---|
244 | |
---|
245 | - Receiving away status changes |
---|
246 | |
---|
247 | - `skyped` (the tcp daemon that is a gateway between Skype and tcp) |
---|
248 | |
---|
249 | - Error handling when `skyped` is not running and when it exits |
---|
250 | |
---|
251 | - Marking received messages as seen so that Skype won't say there are unread messages |
---|
252 | |
---|
253 | - Adding / removing contacts |
---|
254 | |
---|
255 | - Set away state when you do a `/away`. |
---|
256 | |
---|
257 | - When you `account off`, Skype will set status to `Offline` |
---|
258 | |
---|
259 | - When you `account on`, Skype will set status to `Online` |
---|
260 | |
---|
261 | - Detect when somebody wants to add you and ask for confirmation |
---|
262 | |
---|
263 | - Detect when somebody wants to transfer a file |
---|
264 | |
---|
265 | - Group chat support: |
---|
266 | |
---|
267 | * Detect if we're invited |
---|
268 | |
---|
269 | * Send / receive group chat messages |
---|
270 | |
---|
271 | * Invite others (using `/invite <nick>`) |
---|
272 | |
---|
273 | * Part from group chats |
---|
274 | |
---|
275 | * Starting a group chat (using `/j #nick`) |
---|
276 | |
---|
277 | - Topic changes in group chats: |
---|
278 | |
---|
279 | * Show the current topic (if any) on join |
---|
280 | |
---|
281 | * Notice when someone changes the topic |
---|
282 | |
---|
283 | * Support changing the topic using `/topic` |
---|
284 | |
---|
285 | - Viewing the profile using the `info` command. |
---|
286 | |
---|
287 | - Handling skype actions (when the `CHATMESSAGE` has `EMOTED` type) |
---|
288 | |
---|
289 | - Setting your display name using the `nick` command. |
---|
290 | |
---|
291 | - Running Skype on a machine different to BitlBee is possible, the |
---|
292 | communication is encrypted. |
---|
293 | |
---|
294 | - Managing outgoing calls (with call duration at the end, including |
---|
295 | SkypeOut calls if you use a phone number instead of a nick): |
---|
296 | |
---|
297 | * `account set skype/call nick` |
---|
298 | * `account set -del skype/call` |
---|
299 | |
---|
300 | - Managing incoming calls via questions, just like when you add / remove |
---|
301 | contacts. |
---|
302 | |
---|
303 | - Querying the current SkypeOut balance: |
---|
304 | |
---|
305 | * `account set skype/balance query` |
---|
306 | |
---|
307 | == What needs to be done (aka. TODO) |
---|
308 | |
---|
309 | - Notice if foo invites bar. Currently you can see only that bar joined. |
---|
310 | |
---|
311 | - Public chats. See |
---|
312 | link:https://developer.skype.com/jira/browse/SCL-381[this feature |
---|
313 | request], this is because it is still not possible (under Linux) to |
---|
314 | `join_chat` to a public chat.. |
---|
315 | |
---|
316 | - Add `--disable-skyped` and `--disable-plugin` switches in case one wants to |
---|
317 | build `bitlbee-skype` only for a public server or only for use with a public |
---|
318 | server. |
---|
319 | |
---|
320 | == I would like to have support for ... |
---|
321 | |
---|
322 | If something does not work and it's not in the TODO section, then please |
---|
323 | contact me! Please also try the link:HACKING[git version] before reporting a bug, your |
---|
324 | problem may be already fixed there. |
---|
325 | |
---|
326 | In fact, of course, I wrote this documentation after figured out how to do this |
---|
327 | setup, so maybe I left out some steps. If you needed 'any' additional tricks, |
---|
328 | then it would be nice to include them here. |
---|
329 | |
---|
330 | == Known bugs |
---|
331 | |
---|
332 | - None at this time. |
---|
333 | |
---|
334 | == Screenshots |
---|
335 | |
---|
336 | You can reach some screenshots link:shot[here]. |
---|
337 | |
---|
338 | == Additional resources |
---|
339 | |
---|
340 | You can reach the Changelog link:Changelog[here], and a gitweb interface |
---|
341 | http://vmiklos.hu/gitweb/?p=bitlbee-skype.git[here]. |
---|
342 | |
---|
343 | The Skype API documentation is |
---|
344 | https://developer.skype.com/Docs/ApiDoc[here] if you're interested. |
---|
345 | |
---|
346 | |
---|
347 | == Testimonials |
---|
348 | |
---|
349 | ---- |
---|
350 | 00:56 < scathe> vmiklos: I like your skype plugin :) |
---|
351 | ---- |
---|
352 | |
---|
353 | ---- |
---|
354 | It's really working great so far. |
---|
355 | |
---|
356 | Good Job and thank you! |
---|
357 | Sebastian |
---|
358 | ---- |
---|
359 | |
---|
360 | ---- |
---|
361 | Big respect for your work, i really appreciate it. |
---|
362 | |
---|
363 | Martin |
---|
364 | ---- |
---|
365 | |
---|
366 | ---- |
---|
367 | Thanks for bitlbee-skype. As a blind Linux user, I cannot use the |
---|
368 | skype GUI client because qt apps ar not accessible yet with the |
---|
369 | available screen readers. bitlbee-skype allows me to make use of skype |
---|
370 | without having to interact much with the GUI client, which helps me a |
---|
371 | lot. |
---|
372 | |
---|
373 | Lukas |
---|
374 | ---- |
---|
375 | |
---|
376 | ---- |
---|
377 | 02:12 < newton> i must say, i love this little bee ;) |
---|
378 | 02:15 < newton> tried it out today with the skype plugin, good work! |
---|
379 | ---- |
---|
380 | |
---|
381 | == Thanks |
---|
382 | |
---|
383 | for the following people: |
---|
384 | |
---|
385 | * Wilmer van der Gaast, for answering questions about the BitlBee plugin interface |
---|
386 | |
---|
387 | * Arkadiusz Wahlig, author of skype4py, for making suggestions to skyped |
---|
388 | |
---|
389 | * Gabor Adam Toth (tg), for noticing extra code is needed to handle multiline |
---|
390 | messages |
---|
391 | |
---|
392 | * Cristobal Palmer (tarheelcoxn), for helping to testing the plugin in a |
---|
393 | timezone different to mine |
---|
394 | |
---|
395 | * Risko Gergely, for his SkypeOut ideas |
---|
396 | |
---|
397 | * people on `#bitlbee` for feedback |
---|
398 | |
---|
399 | Back to my link:/projects[projects page]. |
---|
400 | |
---|
401 | // vim: ft=asciidoc |
---|