source: skype/README @ c7000bb

Last change on this file since c7000bb was c7000bb, checked in by Miklos Vajna <vmiklos@…>, at 2010-12-11T15:14:12Z

Use internal ssl module instead of pyopenssl or python-gnutls

This results in shorter code and is available on Windows as well.

  • Property mode set to 100644
File size: 12.7 KB
Line 
1= Skype plugin for BitlBee
2Miklos Vajna <vmiklos-at-vmiklos-dot-hu>
3
4== Status
5
6[quote, Wilmer van der Gaast (author of BitlBee)]
7____
8Okay, this exists now, with lots of thanks to vmiklos for his *excellent*
9work!!
10
11It's not in the main BitlBee and it'll never be for various reasons, but
12because it's a plugin that shouldn't be a problem.
13____
14
15One day I browsed the BitlBee bugtracker and found
16http://bugs.bitlbee.org/bitlbee/ticket/82[this] ticket. Then after a while I
17returned and saw that it was still open. So I wrote it.
18
19It's pretty stable (one day I wanted to restart it because of an upgrade
20and just noticed it was running for 2+ months without crashing), I use
21it for my daily work. Being a plug-in, no patching is required, you can
22just install it after installing BitlBee itself.
23
24NOTE: You will see that this implementation of the Skype plug-in still requires
25a Skype instance to be running. This is because I'm not motivated to reverse
26engineer Skype's
27http://en.wikipedia.org/wiki/Skype_Protocol#Obfuscation_Layer[obfuscation
28layer]. (Not mentioning that you should ask your lawyer about if it is legal or
29not..)
30
31== Requirements
32
33* Skype >= 1.4.0.99. The latest version I've tested is 2.1.0.81.
34* BitlBee >= 1.2.6. The lastest version I've tested is @BITLBEE_VERSION@. Use
35  old versions (see the NEWS file about which one) if you have older BitlBee
36  installed.
37* Skype4Py >= 0.9.28.7. Previous versions won't work due to API changes.
38  The latest version I've tested is 1.0.32.0.
39
40* Python >= 2.5. Skype4Py does not work with 2.4.
41* PyGObject >= 2.8.0. Older versions are part of PyGTK. (And you don't want to
42  install GTK for nothing, right?)
43
44`bitlbee-skype` has been tested under Linux and Mac OS X. Skype and Skype4py is
45available under Windows, too, so it probably works, but this has not been tested.
46
47== How to set it up
48
49Before you start. The setup is the following: BitlBee can't connect directly to
50Skype servers (the company's ones). It needs a running Skype client to do so.
51In fact BitlBee will connect to `skyped` (a tcp server, provided in this
52package) and `skyped` will connect to to your Skype client.
53
54The benefit of this architecture is that you can run Skype and `skyped`
55on a machine different to the one where you run BitlBee (it can be even
56a public server) and/or your IRC client.
57
58NOTE: The order is important. First `skyped` starts Skype. Then `skyped`
59connects to Skype, finally BitlBee can connect to `skyped`.
60
61=== Installing under Frugalware or Debian
62
63- Install the necessary packages:
64
65----
66# pacman-g2 -S bitlbee-skype
67----
68
69or
70
71----
72# apt-get install skyped bitlbee-plugin-skype
73----
74
75(the later from the unstable repo)
76
77and you don't have to compile anything manually.
78
79=== Installing under OS X
80
81- Install the necessary packages from ports:
82
83NOTE: You have to edit the Portfile manually to include the install-dev target,
84just append install-dev after install-etc.
85
86----
87# port -v install bitlbee
88# port -v install py25-gobject
89----
90
91and you have to install `bitlbee-skype` and `skype4py` from
92source.
93
94=== Installing from source
95
96NOTE: bitlbee-skype by default builds and installs skyped and the
97plugin. In case you just want to install the plugin for a public server
98or you want to use skyped with a public server (like
99`bitlbee1.asnetinc.net`), you don't need both.
100
101- You need the latest stable BitlBee release (unless you want to use a
102  public server):
103
104----
105$ wget http://get.bitlbee.org/src/bitlbee-@BITLBEE_VERSION@.tar.gz
106$ tar xf bitlbee-@BITLBEE_VERSION@.tar.gz
107$ cd bitlbee-@BITLBEE_VERSION@
108----
109
110- Now compile and install it:
111
112----
113$ ./configure
114$ make
115# make install install-dev
116----
117
118- To install http://skype4py.sourceforge.net/[Skype4Py] from source
119  (unless you want to install the plugin for a public server):
120
121----
122$ tar -zxvf Skype4Py-x.x.x.x.tar.gz
123$ cd Skype4Py-x.x.x.x
124# python setup.py install
125----
126
127- Get the plugin code (in an empty dir, or whereever you want, it does
128  not matter):
129
130----
131$ wget http://vmiklos.hu/project/bitlbee-skype/bitlbee-skype-@VERSION@.tar.gz
132$ tar xf bitlbee-skype-@VERSION@.tar.gz
133$ cd bitlbee-skype-@VERSION@
134----
135
136- Compile and install it:
137
138----
139$ ./configure
140$ make
141# make install
142----
143
144This will install the plugin to where BitlBee expects them, which is
145`/usr/local/lib/bitlbee` if you installed BitlBee from source.
146
147=== Configuring
148
149- Set up `~/.skyped/skyped.conf`: Create the `~/.skyped` directory, copy
150  `skyped.conf` and `skyped.cnf` from
151  `/usr/local/etc/skyped/skyped.conf` to `~/.skyped`, adjust `username`
152  and `password`. The `username` should be your Skype login and the
153  `password` can be whatever you want, but you will have to specify that
154  one when adding the Skype account to BitlBee (see later).
155
156NOTE: Here, and later - `/usr/local/etc` can be different on your installation
157if you used the `--sysconfdir` switch when running bitlbee-skype's `configure`.
158
159- Generate the SSL pem files:
160
161----
162# cd ~/.skyped
163# openssl req -new -x509 -days 365 -nodes -config skyped.cnf -out skyped.cert.pem \
164        -keyout skyped.key.pem
165----
166
167NOTE: Maybe you want to adjust the permissions in the `~/.skyped`
168dir. For example make it readable by just your user.
169
170TIP: In case you have difficulties generating `skyped.cert.pem` /
171`skyped.key.pem` and you just want to experiment, you can copy&paste the
172contents of those files from
173http://code.google.com/p/gdata-python-client/source/browse/src/gdata/oauth/rsa.py#87[here].
174
175- Start `skyped` (the tcp server):
176
177----
178$ skyped
179----
180
181- Start your `IRC` client, connect to BitlBee and add your account:
182
183----
184account add skype <user> <pass>
185account skype set server localhost
186----
187
188<user> should be your Skype account name, <pass> should be the one you declared
189in `skyped.conf`. If you want to run skyped on a remote machine, replace
190`localhost` with the name of the machine.
191
192If you are running skyped on a custom port:
193
194----
195account skype set port <port>
196----
197
198If you want to set your full name (optional):
199
200----
201account skype set display_name "John Smith"
202----
203
204If you want to see your skypeout contacts online as well (they are
205offline by default):
206
207----
208account skype set skypeout_offline false
209----
210
211== Setting up Skype in a VNC server (optional)
212
213Optionally, if you want to run Skype on a server, you might want to setup up
214a `VNC` server as well. I used `tightvnc` but probably other `VNC` servers will
215work, too.
216
217First run
218
219----
220$ vncpasswd ~/.vnc/passwd
221----
222
223and create a password. You will need it at least once.
224
225Now create `~/.vnc/xstartup` with the following contents:
226
227----
228#!/bin/sh
229
230blackbox
231----
232
233Adjust the permissions:
234
235----
236$ chmod +x ~/.vnc/xstartup
237----
238
239Then start the server:
240
241----
242$ vncserver
243----
244
245Then connect to it, start an `xterm`, set up Skype (username, password,
246enable X11 API and allow the `Skype4Py` client), quit from Skype, and
247start `skyped`. If you want to watch its traffic, enable debug messages
248and foreground mode:
249
250----
251$ skyped -n -d
252----
253
254== Features
255
256- Download nicks and away statuses from Skype
257
258- Noticing joins / parts while we're connected
259
260- Sending messages
261
262- Receiving messages
263
264- Receiving away status changes
265
266- `skyped` (the tcp daemon that is a gateway between Skype and tcp)
267
268- Error handling when `skyped` is not running and when it exits
269
270- Marking received messages as seen so that Skype won't say there are unread messages
271
272- Adding / removing contacts
273
274- Set away state when you do a `/away`.
275
276- When you `account off`, Skype will set status to `Offline`
277
278- When you `account on`, Skype will set status to `Online`
279
280- Detect when somebody wants to add you and ask for confirmation
281
282- Detect when somebody wants to transfer a file
283
284- Group chat support:
285
286  * Detect if we're invited
287
288  * Send / receive group chat messages
289
290  * Invite others (using `/invite <nick>`)
291
292  * Part from group chats
293
294  * Starting a group chat (using `/j #nick`)
295
296- Topic changes in group chats:
297
298  * Show the current topic (if any) on join
299
300  * Notice when someone changes the topic
301
302  * Support changing the topic using `/topic`
303
304- Viewing the profile using the `info` command.
305
306- Handling skype actions (when the `CHATMESSAGE` has `EMOTED` type)
307
308- Setting your display name using the `nick` command.
309
310- Running Skype on a machine different to BitlBee is possible, the
311  communication is encrypted.
312
313- Managing outgoing calls (with call duration at the end, including
314  SkypeOut calls if you use a phone number instead of a nick):
315
316  * `account skype set call nick`
317  * `account skype set -del skype/call`
318
319- Managing incoming calls via questions, just like when you add / remove
320  contacts.
321
322- Querying the current SkypeOut balance:
323
324  * `account skype set balance query`
325
326- For debug purposes, it's possible to send any command to `skyped`. To
327  achieve this, you need to:
328
329  * `account skype set skypeconsole true`
330
331  * then writing `skypeconsole: <command>` will work in the control
332    channel.
333
334  * `account skype set skypeconsole_receive true` will make the
335    `skypeconsole` account dump all the recieved raw traffic for you
336
337- If you want to automatically join bookmarked groupchats right after
338  you logged in, do:
339
340  * `account skype set auto_join true`
341
342- Edited messages are shown with the `EDIT:` prefix. If you don't like
343  this, you can set your own prefix using:
344
345  * `account skype set edit_prefix "updated message:"`
346
347- The `echo123` test account is hidden by default. If you want to see it:
348
349  * `account skype set test_join true`
350
351- Mood texts are not shown by default. If you want to see it:
352
353  * `account skype set show_moods true`
354
355== What needs to be done (aka. TODO)
356
357- Notice if foo invites bar. Currently you can see only that bar joined.
358
359- Public chats. See
360  link:https://developer.skype.com/jira/browse/SCL-381[this feature
361  request], this is because it is still not possible (under Linux) to
362  `join_chat` to a public chat..
363
364- Add yasrd (Yet Another Skype-Related Daemon) to allow using a public
365  server for users who are behind NAT.
366
367== I would like to have support for ...
368
369If something does not work and it's not in the TODO section, then please
370contact me! Please also try the link:HACKING[git version] before reporting a bug, your
371problem may be already fixed there.
372
373In fact, of course, I wrote this documentation after figured out how to do this
374setup, so maybe I left out some steps. If you needed 'any' additional tricks,
375then it would be nice to include them here.
376
377== Known bugs
378
379- File transfers are view-only from BitlBee. Quoting the
380  https://developer.skype.com/Docs/ApiDoc/FILETRANSFER_object[relevant
381  documentation]: 'File transfers cannot be initiated nor accepted via
382  API commands.' So it's not something I can add support for, sadly.
383
384== Screenshots
385
386You can reach some screenshots link:shot[here].
387
388== Additional resources
389
390You can reach the Changelog link:Changelog[here], and a gitweb interface
391http://vmiklos.hu/gitweb/?p=bitlbee-skype.git[here].
392
393The Skype API documentation is
394http://developer.skype.com/resources/public_api_ref.zip[here] if you're
395interested.
396
397
398== Testimonials
399
400----
40100:56 < scathe> I like your skype plugin :)
402----
403
404----
405It's really working great so far.
406
407Good Job and thank you!
408Sebastian
409----
410
411----
412Big respect for your work, i really appreciate it.
413
414Martin
415----
416
417----
418Thanks for bitlbee-skype. As a blind Linux user, I cannot use the
419skype GUI client because qt apps ar not accessible yet with the
420available screen readers. bitlbee-skype allows me to make use of skype
421without having to interact much with the GUI client, which helps me a
422lot.
423
424Lukas
425----
426
427----
42802:12 < newton> i must say, i love this little bee ;)
42902:15 < newton> tried it out today with the skype plugin, good work!
430----
431
432----
43318:10 < miCSu> it works fine
434----
435
436----
43713:56 < seo> i just want to thank you :)
43813:56 < seo> for bitlbee-skype
43913:57 < seo> it's working very well, so, again, thank you for your work, and for sharing it
440----
441
442----
44322:16 < ecraven> vmiklos: thanks a lot for the skype plugin for bitlbee!
444----
445
446----
447I'm blind and so I have to use a screen reader, in my case Gnome-Orca.
448But since Skype is written in QT, while Orca uses gtk+, I have no direct
449access to the Skype interface. That's why I desided to use Skyped and
450Erc.
451The text console is fully accessible.
452Thank you very much.
453
454Hermann
455----
456
457----
458i love that bitlbeeplugin. big thx for that.
459
460michael
461----
462
463----
46423:47 < krisfremen> thanks for creating this fabulous piece of software vmiklos :)
465----
466
467== Thanks
468
469to the following people:
470
471* Wilmer van der Gaast, for answering questions about the BitlBee plugin interface
472
473* Arkadiusz Wahlig, author of skype4py, for making suggestions to skyped
474
475* Gabor Adam Toth (tg), for noticing extra code is needed to handle multiline
476  messages
477
478* Cristobal Palmer (tarheelcoxn), for helping to testing the plugin in a
479  timezone different to mine
480
481* Risko Gergely, for his SkypeOut ideas
482
483* people on `#bitlbee` for feedback
484
485Back to my link:/projects[projects page].
486
487// vim: ft=asciidoc
Note: See TracBrowser for help on using the repository browser.