refusedMessage

Builds the server's REFUSED <reason> reply (bare REFUSED if reason is blank). reason is trimmed and any control/newline/whitespace run collapsed to a single space so the reply stays one clean line - cosmetic, since it is a single datagram with no framing-injection risk.

Return

REFUSED <clean reason>, or a bare REFUSED when reason is blank

Parameters

reason

the human-readable refusal cause