# XMPP over Tor with ejabberd

**URL:** https://discuss.freedombox.org/t/xmpp-over-tor-with-ejabberd/198
**Category:** Support
**Created:** [June 9, 2019, 11:30am UTC](https://discuss.freedombox.org/t/xmpp-over-tor-with-ejabberd/198 "2019-06-09T11:30:42Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![dgj](https://discuss.freedombox.org/letter_avatar_proxy/v4/letter/d/7c8e57/32.png) [@dgj](https://discuss.freedombox.org/u/dgj)
#### Post date: [June 9, 2019, 11:30am UTC](https://discuss.freedombox.org/t/xmpp-over-tor-with-ejabberd/198/1 "2019-06-09T11:30:42Z")

</div>

My FreedomBox is only accessible as a Tor hidden service, therefore I am interested in running as many apps over Tor as possible.

Problem: I am unable to connect to ejabberd over Tor with Pidgin. Any assistance would be appreciated.

What I did:

In order to use XMPP, I had to set a domain name for my FreedomBox under System \> Configure, e.g., EXAMPLE.freedombox.rocks, after which ejabberd is enabled and running. (Note that my ISP does not provide a public-facing IP address, so the domain name is set only so I can configure ejabberd.)

In the chat client Pidgin, I have followed this guide from [riseup.net](http://riseup.net) for using Pidgin with a Tor hidden service, but it did not work.

> **[Pidgin - riseup.net](https://riseup.net/en/chat/clients/pidgin#tor-with-pidgin-configuration)**
>
> Configuring XMPP clients for use with Riseup's chat service.

To sum up what I did.

Under Basic:

- Protocol: XMPP
- Username: my FBX username
- Domain: EXAMPLE.freedombox.rocks
- Resource: empty
- password: my FBX username password

Under Advanced:

- Connection Security: Require encryption
- Connect Port: 5222
- Connect Server: my FBX onion address
- File Transfer Proxies: empty

Under Proxy:

- Proxy type: tried both SOCKS 5 and Tor/Privacy (SOCKS5)
- Host: 127.0.0.1
- Port: tried both 9050 and 9150 with Tor Browser Bundle running

Pidgin says “Unable to connect”.

I was, however, able to use ejabberd with the web client JSXC in Tor Browser Bundle with security level set at “Standard” (i.e., javascript is allowed, etc), but the user interface is unusable.

Anyone able to help?

---

<div class="post-metadata">

### Author: ![bebop](https://discuss.freedombox.org/letter_avatar_proxy/v4/letter/b/f07891/32.png) [@bebop](https://discuss.freedombox.org/u/bebop)
#### Post date: [October 27, 2019, 12:36am UTC](https://discuss.freedombox.org/t/xmpp-over-tor-with-ejabberd/198/2 "2019-10-27T00:36:32Z")

</div>

I do not know the answer, but I would like to do the same thing as you.

Searching the web for ideas, I did find one reference that suggests you may need to have TOR running on your client machine to make this work. I cannot say whether this makes sense or not… but perhaps. This suggestion comes from darknetstats: `https://www.darknetstats.com/tutorial-xmpp-jabber-otr-over-tor/`

---

<div class="post-metadata">

### Author: ![dgj](https://discuss.freedombox.org/letter_avatar_proxy/v4/letter/d/7c8e57/32.png) [@dgj](https://discuss.freedombox.org/u/dgj)
#### Post date: [November 9, 2019, 3:01pm UTC](https://discuss.freedombox.org/t/xmpp-over-tor-with-ejabberd/198/3 "2019-11-09T15:01:18Z")

</div>

I never did get this to work. I even posted to the Pidgin mailing list but got no response:

[https://lists.pidgin.im/pipermail/support/2019-June/030613.html](https://lists.pidgin.im/pipermail/support/2019-June/030613.html)

If you manage to get it to work, let me know. Tor is running on my laptop.

---

<div class="post-metadata">

### Author: ![nyxnor](https://discuss.freedombox.org/letter_avatar_proxy/v4/letter/n/e495f1/32.png) [@nyxnor](https://discuss.freedombox.org/u/nyxnor)
#### Post date: [August 24, 2021, 2:31am UTC](https://discuss.freedombox.org/t/xmpp-over-tor-with-ejabberd/198/4 "2021-08-24T02:31:15Z")

</div>

@dgj @bebop  
Prosody XMPP Server on a Hidden Service for Debian with OTR/OMEMO.  
I am testing this repo [GitHub - nyxnor/prosody-hidden-service](https://github.com/nyxnor/prosody-hidden-service). Would be good if Freedombox allowed custom services to have an onion service.

---

<div class="post-metadata">

### Author: ![zippy99](https://discuss.freedombox.org/letter_avatar_proxy/v4/letter/z/278dde/32.png) [@zippy99](https://discuss.freedombox.org/u/zippy99)
#### Post date: [August 24, 2021, 12:43pm UTC](https://discuss.freedombox.org/t/xmpp-over-tor-with-ejabberd/198/5 "2021-08-24T12:43:41Z")

</div>

I use Psi+ with Tor from FBX server and is working fine.  
I also use Gajim through Tor and is working fine. Both with OMEMO encryption.

 ![Captură de ecran la 2021-08-24 15-40-09](https://discuss.freedombox.org/uploads/default/original/1X/f3a164a8b163a4ca1fd46ad8539dcc9565bd11cc.png)
