Skip to content

Smartcam update_credentials#1661

Closed
Puxtril wants to merge 2 commits intopython-kasa:masterfrom
Puxtril:tapocam-update-credentials
Closed

Smartcam update_credentials#1661
Puxtril wants to merge 2 commits intopython-kasa:masterfrom
Puxtril:tapocam-update-credentials

Conversation

@Puxtril
Copy link
Copy Markdown
Contributor

@Puxtril Puxtril commented Feb 24, 2026

Newer Tapo cameras use changeAdminPassword to update admin credentials on the device. Tested on my C206.

As a note: it seems these devices limit functionality until the admin password is updated. I've noted on my C206 the Tapo camera stream would not load when provided default credentials, and my H200 hub would not find devices. The hub would respond successfully to API calls to start/stop scanning, but would not return any found devices. Only after updating credentials would it actually return found devices.


async def update_credentials(self, username: str, password: str) -> dict:
cur_pass = self.credentials.password if self.credentials.password else self.protocol._transport._default_credentials.password
cur_pass_hash = hashlib.sha256(cur_pass.encode()).hexdigest().upper()

Check failure

Code scanning / CodeQL

Use of a broken or weak cryptographic hashing algorithm on sensitive data High

Sensitive data (password)
is used in a hashing algorithm (SHA256) that is insecure for password hashing, since it is not a computationally expensive hash function.
Sensitive data (password)
is used in a hashing algorithm (SHA256) that is insecure for password hashing, since it is not a computationally expensive hash function.
async def update_credentials(self, username: str, password: str) -> dict:
cur_pass = self.credentials.password if self.credentials.password else self.protocol._transport._default_credentials.password
cur_pass_hash = hashlib.sha256(cur_pass.encode()).hexdigest().upper()
new_pass_hash = hashlib.sha256(password.encode()).hexdigest().upper()

Check failure

Code scanning / CodeQL

Use of a broken or weak cryptographic hashing algorithm on sensitive data High

Sensitive data (password)
is used in a hashing algorithm (SHA256) that is insecure for password hashing, since it is not a computationally expensive hash function.
@Puxtril
Copy link
Copy Markdown
Contributor Author

Puxtril commented Mar 1, 2026

Superseded by #1664

@Puxtril Puxtril closed this Mar 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant