H'uru server.ini keys for MOSS

Discussions About MOSS (Myst Online Server Software)

Moderators: a'moaca', rarified

Post Reply
cjkelly1
Member
Posts: 67
Joined: Mon Dec 29, 2008 6:08 am

H'uru server.ini keys for MOSS

Post by cjkelly1 »

Making a new thread, so as not to necro a 9 year old thread.

In this thread, Christian Walther posted a python script to convert MOSS public keys into the server.ini format. The input files you want are as he said, the output files of make_cyan_dh -c. Below is an attempt to update the script for Python 3, as Ubuntu 20.04 does not come with Python 2 by default.

Usual disclaimer : It works for me. YMMV.


Like the original, this assumes the file names for the keys are "auth_pub", "game_pub", and "gatekeeper_pub" and are in the same directory as the python script.

Note that the H'uru client uses the MOULa default generators if you do not specify otherwise:

Auth server G = 41
Game server G = 73
Gatekeeper server G = 4


If you generated your MOSS server keys with different generators, you will need to specify those generators in your server.ini file. Please note that if you did not specify a generator on the command line for make_cyan_dh ( using -g ) when you generated your MOSS keys, you have this situation. They will have all defaulted to "4". If you did this and do not want to regenerate your keys, you can specify the generators in the server.ini.

For example, if you used make_cyan_dh defaults, you will need to add the following to the generated server.ini.

Server.Auth.G "4"
Server.File.G "4"
Server.Gate.G "4"

Also, probably a good idea to use your own server's IP address in the below, unless by chance your server's IP is the same as mine. :-)

Happy Uru-ing! :-D

makeserverini.py

Code: Select all

#!/usr/bin/env python3

import base64

def printkey(infile, outname):
        with open(infile, "rb") as f:
                n = list(f.read(64))
                n.reverse()
                n64 = base64.b64encode(bytes(n))
                x = list(f.read(64))
                x.reverse()
                x64 = base64.b64encode(bytes(x))
                print('Server.' + outname + '.N "' + n64.decode() + '"')
                print('Server.' + outname + '.X "' + x64.decode() + '"')

printkey("game_pub", "Game")
print()
printkey("gatekeeper_pub", "Gate")
print('Server.Gate.Host "192.168.10.204"')
print()
printkey("auth_pub", "Auth")
print('Server.Auth.Host "192.168.10.204"')
print()
print('Server.DispName "Moss"')
print('Server.Status ""')
print('Server.Signup ""')
Last edited by cjkelly1 on Thu Apr 08, 2021 6:58 pm, edited 1 time in total.
Reason: Fix script link to point to specific post
Post Reply

Return to “MOSS”