WhatsMiners were shown "locked/unauthenticated" even with their default login.
Two causes, both fixed:
- The access probe hit an Antminer-only endpoint (/cgi-bin/get_miner_conf.cgi via
curl --digest) for EVERY make; WhatsMiners answer 307 there, so the check was
always indeterminate. Added a real WhatsMiner check over its :4028 token API:
get_token (unauthenticated) -> derive the AES key from the password (md5crypt +
SHA256, the same scheme the vendored asic-rs whatsminer backend uses) -> send a
NON-mutating encrypted `summary`. An encrypted reply means the password was
accepted (unlocked); a plaintext "enc json load err" means rejected (locked).
probe_access now branches on the miner brand. Candidate passwords: a per-firmware
override (round 12 #13) if set, else the factory defaults admin (V1/V2) and super
(V3); all attempts are non-mutating so trying both is safe.
- The scan-time lock guess (!caps.any_control()) falsely marked older WhatsMiners
locked because they route to the asic-rs V1 backend, which declares no control
commands even though the miner is controllable via the token API. WhatsMiner
lock state is now left unknown at scan time and decided by the real probe.
Live-verified on the fleet: older 20220422.18.REL units (10.8.1.176, 10.7.1.196)
and newer M30S+ (10.8.1.45) all report UNLOCKED with the default admin login;
the Antminer digest path is unchanged (Z15 -> 200 with root/root -> unlocked).
Added a headless `ALKANE_ACCESS_PROBE="<ip> <make>"` diagnostic and a
deterministic AES unit test. Self-test passes.
Note: this is the access/lock half of #8b. Implementing the full reverse-
engineered WhatsMiner command set (control + monitoring over the token API) is
tracked separately.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Y8h447BPyJR4fioYZvQ9bh