mirror of
https://github.com/python-kasa/python-kasa.git
synced 2026-02-27 05:09:58 +00:00
Add support for tapo login_version 3 in sslaestransport (#1638)
Updates to get_default_credentials and DEFAULT_CREDENTIALS for handling a new default password for encryption_type 3 in TAPOCAMERA devices that use encryption_type 3. This adds support for devices like TC40.
This commit is contained in:
@@ -95,8 +95,12 @@ class SslAesTransport(BaseTransport):
|
||||
not self._credentials or self._credentials.username is None
|
||||
) and not self._credentials_hash:
|
||||
self._credentials = Credentials()
|
||||
if self._login_version == 3:
|
||||
_default_credentials = DEFAULT_CREDENTIALS["TAPOCAMERA_LV3"]
|
||||
else:
|
||||
_default_credentials = DEFAULT_CREDENTIALS["TAPOCAMERA"]
|
||||
self._default_credentials: Credentials = get_default_credentials(
|
||||
DEFAULT_CREDENTIALS["TAPOCAMERA"]
|
||||
_default_credentials
|
||||
)
|
||||
self._http_client: HttpClient = HttpClient(config)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user