Create an account


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[SOLVED] Not attempting to generate keys | FreeBSD server

#1
I have installed the Xonotic server via the ports system on FreeBSD. For the most part, the server works fine, and all 32 slots were filled last night and I had no real issues.

However, I have noticed that I don't have a public or private key for the server. I believe this is used for the AES network traffic encryption, and maybe possibly also for stats submission?

Below is an extract from the server startup process on FreeBSD:

Code:
execing autoexec/empty.cfg
execing autoexec.cfg
Server using port 26000
Server listening on address 0.0.0.0:26000

And here is an extract from the same part of the startup process on debian:
Code:
execing autoexec/empty.cfg
execing autoexec.cfg
Loaded public key key_0.d0pk (fingerprint: Xon//KssdlzGkFKdnnN4sgg8H+koTbBn5JTi37BAW1Q=)
Generated private ID key_0.d0pk (public key fingerprint: FOLKWGz4AezBLgGwkjLP0kya20DAq3NUkIqMCuG2+o8=)
Saved unsigned key to key_0.d0si
Signature generation in progress...
Server using port 26000
Server listening on address 0.0.0.0:26000

I noticed that the FreeBSD port doesn't install the public key (key_0.d0pk), so I tried renaming it on the debian install to see if that caused the same output. It did however show one key difference:

Code:
execing autoexec.cfg
there is no public key 0
Server using port 26000
Server listening on address 0.0.0.0:26000

Debian actually gives an error when it can't find a public key, so this leads me to believe that FreeBSD does not actually even attempt to generate keys, as it's not even looking for a public key.

Does anybody know what the issue is here, and what I might do to fix it?


I have just realised another difference between my FreeBSD Xonotic and my Debian xonotic.

On Debian, if I type "crypto_keygen" into the server console, I get the following output:

Code:
usage:
crypto_keygen id url

If I type the same on FreeBSD, I get:

Code:
Unknown command "crypto_keygen"

It's also worth noting that the port does install libd0* into the lib dir.
Reply

#2
The Xonotic command responsible for key generation is run from quake.rc and is the following:
Code:
crypto_keygen 0 http://ca.xonotic.org/?ca=0&key=

That command is pretty verbose, so I'm surprised to see no output from it in your first log extract.

Try to get back to the initial situation (move the public key from your Debian install out of the way). Can you see further down the log if there's anything? If not, can you try running the command I gave above manually?

EDIT: Ah, I did not see your edit. I'll have a look and double-post in this thread so that you may get a notification.
[Image:http://i.imgur.com/4XODR.png]640K ought to be enough for anybody.
     ― Linux Torvalds
Reply

#3
So, yeah. d0_blind_id is required for this to work obviously. It's statically linked in git builds and dynamically in releases. I suppose your Debian package is a release build, I don't know if d0_blind_id is included in the same package or separately.

Do you have libd0_blind_id.so ?

EDIT: Uh, wait. Why did it load the library successfully when you moved the public key into your install? I don't get it.
EDIT: Okay, I get it. The "no public key" came from Debian when you removed the pubkey.
[Image:http://i.imgur.com/4XODR.png]640K ought to be enough for anybody.
     ― Linux Torvalds
Reply

#4
Okay, with the help of Mr. Bougo in IRC I have successfully solved the issue. It turns out that the port was not install the crypto library. I will contact the port maintainer to see if it's possible to integrate this into the Xonotic port (not sure if that will be possible due to legal reasons) or whether we could have a standalone port for the library.

Instructions to install crypto library on FreeBSD:
Code:
- install "automake-wrapper-20131203" if you haven't got it already
- cd /usr/ports/games/xonotic && make install   #IMPORTANT, do not add "clean"
- cd work/Xonotic/source/d0_blind_id
- fetch https://raw.githubusercontent.com/divVerent/d0_blind_id/master/d0_rijndael.c
- chmod +x autogen.sh
- ./autogen.sh
- ./configure --with-openssl
- make
- make install
- cp /usr/ports/games/xonotic/work/Xonotic/key_0.d0pk /usr/local/share/xonotic/

A link to the full conversation can be found here: http://slexy.org/view/s21jsfxqm4
Reply



Possibly Related Threads...
Thread Author Replies Views Last Post
  RaspberryPi4 Server ablyveiled 1 270 08-10-2020, 11:51 PM
Last Post: Freddy
Rainbow Kotangєns' independent server Kotangens 0 240 07-30-2020, 06:22 AM
Last Post: Kotangens
  [NEED HELP] I can't create my server. Kotangens 11 670 07-22-2020, 04:42 AM
Last Post: Kotangens
Information [SOLVED] Server stops when I close command prompt on my PC Jewel 2 324 06-01-2020, 07:11 AM
Last Post: Jewel
  Server Hosting Issue Saevus 2 405 04-30-2020, 06:16 PM
Last Post: Saevus
  Server error "Weapon stats writing failed: -404" FlufyBuny 2 906 04-08-2020, 02:41 PM
Last Post: jwabbitt
  Docker Xonotic Dedicated Server ich777 13 1,939 04-02-2020, 02:59 PM
Last Post: FAF
  [NEED HELP] Server dont appear in server browser abslimit 0 445 03-15-2020, 04:13 AM
Last Post: abslimit
  How To Open Server? Lyviq 0 441 03-11-2020, 05:19 PM
Last Post: Lyviq
  [SOLVED] Opensuse Leap 15.1 and Server.cfg ldegroot 3 756 08-01-2019, 02:52 PM
Last Post: ldegroot

Forum Jump:


Users browsing this thread:
1 Guest(s)

Forum software by © MyBB original theme © iAndrew 2016, remixed by -z-