Nexus DocsCurrent release 1.1.0Deutsch

Sign agent requests

Construct the exact signed envelope for progress and renewal.

Canonical message

POST /api/v1/hosting/progress and /renew use a signed JSON envelope, not Basic or the original pairing token. All envelope fields are strings:

Field Encoding
enrollment_id Public identity returned at enrolment
timestamp Decimal Unix seconds, maximum clock difference 300 seconds
nonce Fresh 32 random bytes as 64 lowercase hexadecimal characters
payload Standard base64 of UTF-8 JSON; encoded field at most 65536 bytes
signature Standard base64 of an OpenSSL SHA-256 private-key signature

Sign the LF-joined values enrollment_id, action (progress/renew), timestamp, nonce, payload, with no trailing LF. Sign the encoded payload string, not decoded or re-serialised JSON. Use the enrolled key, not HMAC.

import base64, json, secrets, time, subprocess
from pathlib import Path
action = "progress"
payload = base64.b64encode(json.dumps({"step":"installed"}, separators=(",", ":")).encode()).decode()
e = {"enrollment_id":"RETURNED_ID", "timestamp":str(int(time.time())), "nonce":secrets.token_hex(32), "payload":payload}
message = "\n".join([e["enrollment_id"], action, e["timestamp"], e["nonce"], payload]).encode()
sig = subprocess.run(["openssl","dgst","-sha256","-sign","/protected/server.key"], input=message, capture_output=True, check=True).stdout
e["signature"] = base64.b64encode(sig).decode()
Path("request.json").write_text(json.dumps(e))
curl --fail-with-body -H 'Content-Type: application/json' --data-binary @request.json \
  "$HOSTING_ORIGIN/api/v1/hosting/progress"

Replay and progress

Nonces are single-use and retained ten minutes. Transport retries need a fresh nonce, timestamp and signature. A malformed decoded payload can consume a nonce. The outer body is at most 131072 bytes. Authentication also requires valid enrolled certificate, active/unarchived inventory and approved assigned address.

Progress payload step: configuring, starting, installed, failed. Success is {"accepted":true}. Failure stores a fixed safe diagnostic, not remote logs. Acknowledgement is not a successful live health check.

The enrolled CSR key must be RSA with at least 2048 bits. A CSR is limited to 16384 bytes. OpenSSL dgst -sha256 -sign uses the RSA signature format accepted by the server.