Core: iCloud keeps on asking for 2fa key on my mobile device

Created on 17 Apr 2020  路  4Comments  路  Source: home-assistant/core

The problem

Since a reboot and upgrade to home assistant 0.108.5 I constantly get a request for a 2fa key on my mobile device, but I do not get an option to enter this somewhere.

Can I avoid this by setting up an app-specific password on my Apple iCloud account? If so, can this be documented?

Environment

  • Home Assistant Core release with the issue: 0.108.5
  • Last working Home Assistant Core release (if known): 0.108.4
  • Operating environment (Home Assistant/Supervised/Docker/venv): Home Assistant
  • Integration causing this issue: iCloud
  • Link to integration documentation on our website:

Problem-relevant configuration.yaml


Traceback/Error logs


Additional information

icloud

Most helpful comment

I followed the procedure and that worked.

I also tried with a app-specific password generated on the Apple Id management page, but that was not accepted, so I had to use my personal password.

To be honest I think that it should accept the app-specific password, because that is the solution that Apple offers for these kind of cases.

Kind regards,
Marcel

All 4 comments

Hey there @Quentame, mind taking a look at this issue as its been labeled with a integration (icloud) you are listed as a codeowner for? Thanks!

Hi !

Try to :

  • remove the iCloud integration(s)
  • go to [HA-config]/.storage (invisible folder)
  • remove the icloud folder
  • restart HA
  • add your iCloud integration(s) again

No modification were made on iCloud integration from 0.107.0 as I remember.

Thanks for reporting the issue 馃槉

I followed the procedure and that worked.

I also tried with a app-specific password generated on the Apple Id management page, but that was not accepted, so I had to use my personal password.

To be honest I think that it should accept the app-specific password, because that is the solution that Apple offers for these kind of cases.

Kind regards,
Marcel

Actually we can't use app-specific password, since the underlying library uses the iCloud API (same as the iCloud.com website), so it needs same credentials as you connect to the iCloud website.

But sure, I totally agree that unique password per app/website is way better for security purpose. If you have the skills and find a way to add it, a PR is very welcomed on https://github.com/picklepete/pyicloud :blush:

Solved, closing the issue.

Was this page helpful?
0 / 5 - 0 ratings