mirror of
https://github.com/xcat2/confluent.git
synced 2026-08-03 16:07:00 +00:00
ca81907d25
The old WebConnection.request() added a 'Content-Type: application/x-www-form-urlencoded' header to any POST carrying a body, but grab_response_with_status() only sets a content type for dict payloads, so the SMM login and every /data form POST now go out as text/plain. This is not a fix for an observed failure: an SMM running FPC variant 38 was measured accepting a text/plain login exactly as readily as a urlencoded one. It restores the header the synchronous code always sent and that the TSM and IMM handlers still set explicitly, rather than relying on every SMM firmware level being equally lax about what it will parse. Also stop hard failing on responses the synchronous code discarded on purpose. 'set=securityrollback:1' is only understood by newer SMM2 firmware. And /data/logout answers 401 once the session is gone, as measured on that same SMM, so raising on a non-200 there turns a completed hostname, domain or NTP operation into a spurious error.