This documentation was converted from the KDE UserBase Kopete/Jabber page.
2010-12-05
&kde; SC 4.6

# Jabber Handbook

## About Jabber XMPP

XMPP or Jabber (these words actually mean the same) is the name of an open, decentral network protocol which is used for instant messaging. It is designed as a server-client-infrastructure with many servers all over the Internet, where everyone can get an account. The servers are normally connected to many clients on one side and to other XMPP-servers of the Internet on the other side. Let's invent a small example to explain how it's working:

Romeo loves Juliet and wants to communicate with her through the Jabber network. He can write messages from his client (which is connected with `montague.net`) to his girlfriend, whose client is connected to a server called `capulet.com`.

When he registered an account on a server, he chose a so-called JID (Jabber-Identifier). This JID works basically like an E-Mail-Address and is connected to the server's name with an @. An example for Romeo's valid JID is `romeo@montague.net`.

In order to talk to other people, Romeo has to add their JIDs to his contact list. They may be connected to the same server (&eg; `bob@montague.net`) as well as they can originate from another server (&eg; `peter@wasinet.org` or, of course, `juliet@capulet.com`).

Visualization of the Jabber network

Visualization of the Jabber network

Jabber/XMPP is of course capable of a lot more services (&eg; end-to-end encryption of the messages, voice- and videochat, groupchat), which the tutorial will partly introduce later.

Two very big instant messaging providers use Jabber/XMPP on their servers in the background: Google Talk and facebook chat. Accounts within these systems can be used just like normal Jabber accounts in &kopete;. Details will be explained later or can be found at these provider's websites.

With this information we can begin with the main part tutorial: How to set up a working jabber-client and which nice features &kopete; has got.

## First steps

### Get Kopete

Icon of Kopete

Icon of Kopete

Of course, you have to get &kopete; first before you will be able to work with it. If you use a GNU/Linux-system there are very good chances you can find &kopete; already installed (if you have already installed the KDE Software Compilation) or it will be in one of your distribution's repositories.

Now install &kopete; and start it for the first time.

## Create your Jabber account

When you now start &kopete; you will see an empty window.

Empty Kopete window

Empty Kopete window

In the bottom section it says Click here to add an account. Click there or open Settings Configure... to create a new account. We actually want to create a Jabber-account, so we select the menu-item Jabber and click Next. After clicking on Register new account, a new window opens where we can write in a Jabber-server, where the account shall be created.

Configure Kopete

Configure Kopete

You can either manually write it into the textbox Jabber server or select it from the provided list, which appears after clicking on the button Choose...

Server selection dialog

Server selection dialog

After selecting a server you are able to complete your desired Jabber-ID, &ie; your username. Add your preferred name in front of the @ in the field Desired Jabber ID. After filling in your password and repeating it you should tick the checkbox Use protocol encryption (SSL) for having an encrypted client-server connection.

Create your account

Create your account

Some servers might not be capable of this option, but most of them are. Now click on Register to finish the registration.

Congratulations, you have now registered a new account on a Jabber server!

## Fill in your account data in Kopete

You now own an account on a Jabber server and &kopete; asks you for Step two: Account information. &kopete; adds your Jabber ID and your password into the required fields automatically. If you want &kopete; to remember your password in order to not type it in every time you connect with your server, check Remember password.

If you want to use your existing accounts of Google Talk or Facebook chat in &kopete; (these are actually Jabber servers, too), use your GMail address or your facebook account data (explained here) to connect to these servers.

Optionally you can check Exclude from connect all. This advises &kopete; not to go online when you go online with all of your &kopete; accounts (as &kopete; is a multimessenger with support for many other protocols like ICQ or MSN). When you checked this, you will later have to go online explicitly for this one account every time you want to connect with your server.

Your &kopete; should now look like this:

Account information window

Account information window

Click on the Tab Connection to check additional options. Especially selecting Use protocol encryption and the unselection of Allow plain-text password authentication should be chosen for basic security reasons.

The default server information should be okay, if you are in a normal home network without special firewall configuration.

The section Location Settings is another specialty of Jabber: You can set so-called Resources to identify where you chat from. For example if you log in to Jabber from your mobile phone and your notebook at the same time (yes, you can do that) the resource explains your contacts where you are. So you could call it Notebook or Android, depending on which device you're installing Kopete. Remember that your resources can be seen from your chat partners (they will be added to the JID like this: `romeo@montague.net/Notebook`), so you might consider privacy issues while choosing your resource name.

In our example, the Resource will be set to Laptop. The priority is mainly useful when you handle multiple devices and tells your partner's client which of your devices being online at the moment (&eg; your mobile phone or your laptop) to contact in this case. The highest priority number of your resources being online receives the message.

Set the account configuration

Set the account configuration

The next tab, File Transfer, is normally not affected when setting up a Jabber account in a normal network.

Finally, there are some privacy configurations in the tab Privacy, they are mostly self-explanatory. The option Use old inline PGP format for signed and encrypted messages (read here what PGP means) is not recommended, because there exists a method to do this with the built-in OTR, which will be explained later in this tutorial.

At this point you can click Next again and your account is configured now. You can choose an optional color for your account and when you feel ready to connect the very first time to your Jabber server, the checkbox Connect now has to be ticked.

Last step of configuration

Last step of configuration

Now you can finish the configuration.

Otherwise you can manually connect to the server by clicking Status Online in the Kopete main window or by right-clicking the Kopete symbol in your tray and selecting Set status Online. If you chose the option Exclude from connect all earlier, you will have to log in by right-clicking on the Kopete tray icon and selecting yourJID@example.org Online.

Going online

Going online

## Adding friends

After your first login, your &kopete; window is quite empty. There might be a default contact added by your server which perhaps sends you a welcome message, but there are no real contacts in your roster (this is by the way the word for contact list in the Jabber world). The first step for adding friends in Jabber is, of course, asking them for their Jabber ID. When you got one, you can immediately add it to &kopete;. You can either click Add yourJID@example.org or File Add Contact yourJID@example.org. A new window appears asking for the Jabber ID we want to add to our roster. Just type it in and click OK. The Group option is used, when you specified groups of contacts (&eg; family and work). A connection to your KAddressBook can be established with Address book entry, so that you can exchange information like profile pictures between the two applications.

Adding a friend

Adding a friend

Now you've added your first friend to your roster. But before you can start writing messages to him or her, your contact has to authorize your request. Until this happens, the contact appears with a small yellow exclamation mark on the right side of his contact field.

Your contact

Your contact

When your friend authorized your request or added you to his or her roster, its icon will appear colored when online. The exact meanings of the different icons (Online, Away &etc;) can be seen at Status where you can set them yourself, too. You receive a notification when you are authorized.

Normally, your friend will put you also to his or her contact list, so you have to authorize this request by yourself, too. &kopete; notifies about that at the bottom with a green flag and the description of the request. Click on Authorize to accept. The notification area can be closed by clicking on the cross on the upper-right side of the area.

You're now added by your contact

You're now added by your contact

After that procedure you should see a contact list like in the next image.

Your contact is fully authorized

Your contact is fully authorized

You successfully added your first contact to your roster now.

## Messaging and sending files

You can start chatting with a contact by clicking on the name. A new window will open and you can type in messages into the smaller field at the bottom, where the cursor already resides. When you want to send your text, hit &Enter; or press the Send button. You and your partner can communicate now via Jabber.

Your first chat

Your first chat

### Transfer files

To transfer files via Jabber click on Send File and select the file you want to send in the popup window. You will be notified when the transaction is complete or failed for some reason.

This may not work in some cases due to incompatible configurations of some servers

### Group chat

Jabber is not only capable of communicating with one person. You can use Group Chat to do an IRC style discussion, where many people can talk with each other. To use Group Chat, you have to right-click on the &kopete; systray icon, and select yourJID Join Groupchat..., where yourJID stands for your own Jabber ID. A new window appears where you can join a chatroom.

Groupchat

Groupchat

Click on Query to show the list of existing chatrooms on your Jabber server. Select one and press &Enter; to enter this room.

Alternatively you can type in and create your own chatroom by writing its name into the line Room. Then press &Enter; or click Join to join.

After you created the chatroom, you'll see a new field appearing in your &kopete; window with the JID chatroomname@jabber.example.org. Treat it as a normal contact, &ie; you have to click on this JID to chat &etc;

At this point you have set up a working Jabber client and are in principle able to chat with your contacts. But for a better experience of &kopete;, you are able to configure the application for your best needs. A set of Useful configuration hints is the content of the next page in this tutorial.

## Useful configuration hints

These hints all refer to &kopete;'s main configuration window residing under Settings Configure.... Be sure to click on Apply or OK if you want your changes to be saved.

All adjustments affecting your account setup and configuration of multiple accounts in &kopete; (Jabber/XMPP as well as ICQ, MSN and many other messaging protocols) can be found under the tab Accounts. If you want to set your personal information or are willing to use a contact photo, click on Modify Identity... and make your settings. A photo can be uploaded by clicking on the small icon on the left hand side at the bottom of the image area.

Setting identity

Setting identity

The next tab in the vertical list at the left hand side is Contact List. These settings are mainly self-explanatory and it seems useful to enable Use contact photos when available. The other three horizontal tabs (Colors & Fonts, Advanced and Layout) include quite special settings you will perhaps fine-tune when you have used &kopete; for a few weeks.

The Status configurations enable you to set your default status messages when you're set as Online, Away, Invisible &etc;

Clicking on Behavior opens a quite detailed set of configuration. The most interesting ones, that can be found in the tab General are Message Handling and Initial Status. The first one decides if incoming messages from your contacts open instantly a new window or if they are queued until you open &kopete; yourself. The second one tells &kopete; if it shall go online when you start the program. When you set this, you are always available for your contacts once you run &kopete;. The tab Events lets you set in what cases &kopete; notifies you via your computer's notification system (in most cases KNotify). When you want &kopete; to set your status automatically to Away, open the tab Away Settings and enable the first checkbox. You can set the time that has to pass after your last action (keyboard input or mouse movement) that &kopete; will set you as away. The default value is 10 minutes. Options located in Chat are again self-explanatory and already set to useful values.

The next item in the vertical row on the left is Chat Window. The first tab in there, Style, can be used to set another appearance than the default one. You can also install your own styles or download new ones from the Internet by clicking on Get New.... When you type in an Emoticon during a conversation, &kopete; will convert it into a graphical emoticon by default. To disable this feature or to use another set of emoticons go to Emoticons. The last tab, Colors & Fonts is again self-explanatory and configures these preferences of your chat window.

Webcams are supported in &kopete;, but at the moment (November 2010) there are still some difficulties concerning video chat, so settings in Video are made at your own responsibility, because it's quite possible it doesn't work in the right way. The KDE Forums may be helpful while dealing with webcam issues.

## Plugins

A very powerful feature of &kopete; is the capability of using plugins. There is a set of plugins pre-installed (new ones can be installed for example with your &Linux; distro's package manager) and they can be enabled and configured under Plugins. You can enable them by setting the tick into the respective checkbox. Most of them are again self-explanatory, but the most useful ones will be explained here anyway. A very helpful plugin is the History. With this option enabled, Kopete will log all your chats and write it onto your hard disk. You can read it in your chat window, when you select the View History icon or you open it with Tools View History.

### OTR

One of the most important plugins considering privacy issues is OTR. This piece of software encrypts your entire conversation from one end to the other and makes it impossible for third persons to read your conversation. After you enabled the plugin, you have to open its settings (click on the wrench icon) and Generate a key.

Generate an OTR key

Generate an OTR key

This may take a while and you have to wait until &kopete; finished. After that close the OTR window with OK and Apply the changes. You eventually will have to restart &kopete; after this. Then open a chat window of the contact you want to safely communicate with. Go to Tools OTR Settings Start OTR Session or use the icon OTR Encryption Start OTR Session. &kopete; will start the session if your contact is capable of OTR, otherwise you'll receive an error message.

First use of OTR

First use of OTR

To ensure your added contact is really the one he or she is pretending, it's necessary to authenticate him or her one time. You can do this by calling Tools OTR Settings Authenticate contact. You may choose between three options:

- The first one is to ask your chat partner a question whose answer can only be known by him or her and you.

- The next possibility is a secret passphrase your partner has to know (you may consider giving the secret to him or her via another secure communication channel, &eg; telephone).

- Thirdly, there's the option of manually checking the OTR fingerprint. This is the most secure option, but it's not very handy and if you can choose one of the others it may be more comfortable and faster. When checking the fingerprint, you have to ask your partner for his or her OTR fingerprint over a secure connection (&eg; telephone or encrypted E-Mail) so that the fingerprint can be checked.

Let's assume we choose option one and ask our partner a question. Type it into the field and define the expected answer your partner has to give, so that he or she can be authenticated.

Asking a secret question

Asking a secret question

When we continue, your partner will see the question and if the answer is correct, OTR is set up ready now.

Finished OTR setup

Finished OTR setup

Your partner may do the same thing in return, so when you see a window asking you for authentication just answer the question and you are an authenticated user in your friend's contact list, too.

OTR authentication

OTR authentication

Every time you communicate safely, you'll see the green armored keylock icon at the top of your chat window. To finish the secure connection, you can either close your chat window or click on OTR Encryption End OTR Session.