QtCraft API C++ classes QML types Handbook

QcMsg::LoginChallenge Struct

struct QcMsg::LoginChallenge

Server -> client after Hello from a remote client: what the server needs for the login. More...

Header: #include <common/protocol/QcLoginMessages.h>

Public Variables

bool identityKnown
qint32 maxViewDistance
QString motd
QByteArray nonce
QList<QcPackFingerprint> packs
bool passwordRequired
QByteArray salt
QString serverName

Static Public Members

const qsizetype maxPacks
const qsizetype maxTextLength
const qsizetype nonceBytes
const qsizetype saltBytes

Detailed Description

The client answers with LoginResponse; local players of the in-process host get Welcome at once.

Member Variable Documentation

bool LoginChallenge::identityKnown

Whether the server knows an identity for the player's name; when not, the client registers one with its response (trust on first use).

const qsizetype LoginChallenge::maxPacks

The most packs of a challenge or response; the decoder refuses more.

const qsizetype LoginChallenge::maxTextLength

The longest server name and message of the day.

qint32 LoginChallenge::maxViewDistance

The largest view distance the server streams, in chunks.

QString LoginChallenge::motd

The server's message of the day.

QByteArray LoginChallenge::nonce

Fresh random bytes of this connection: the proofs of the response are bound to them.

QList<QcPackFingerprint> LoginChallenge::packs

The server's content packs.

bool LoginChallenge::passwordRequired

Whether the server asks for a password.

QByteArray LoginChallenge::salt

The server's salt for the password key and the player identity (QcLoginCrypto).

QString LoginChallenge::serverName

The server's name.