mirror of
https://github.com/hansjone/netx.git
synced 2026-10-09 03:10:46 +08:00
Clarify lab UME TLS verify after default flipped to true.
Point .env.example at NETX_UME_VERIFY_TLS=false for self-signed UME and surface the same hint on certificate verify login failures. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
parent
20c2fcd496
commit
0ebf137776
2 changed files with 13 additions and 3 deletions
|
|
@ -305,7 +305,17 @@ class UMEClient:
|
|||
self._lock_releaser()
|
||||
except Exception:
|
||||
pass
|
||||
raise RuntimeError(f"ume_login_failed:{str(exc)[:240]}") from exc
|
||||
detail = str(exc)[:240]
|
||||
if self.verify_tls and (
|
||||
"CERTIFICATE_VERIFY_FAILED" in detail
|
||||
or "certificate verify failed" in detail.lower()
|
||||
or "SSLCertVerificationError" in type(exc).__name__
|
||||
):
|
||||
detail = (
|
||||
f"{detail} (hint: set NETX_UME_VERIFY_TLS=false for lab "
|
||||
"self-signed UME, or pin a CA; restart API after change)"
|
||||
)
|
||||
raise RuntimeError(f"ume_login_failed:{detail}") from exc
|
||||
|
||||
token, ttl = self._extract_token_and_ttl(data)
|
||||
if not token:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue