-
Notifications
You must be signed in to change notification settings - Fork 573
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Authentication Fix: Merge updated auth flow from pyicloud #734
Authentication Fix: Merge updated auth flow from pyicloud #734
Conversation
This seems a lot more reasonable vs having to patch in changes (domain selection, library selection) into #733. Now that it's more clear about what was originally missing within the authentication area, I imagine this PR is more appropriate. Regarding tests, on the |
Looking over the tests in an attempt to update them and the VCR cassettes. Based on the new It would appear the initial It will take some time to go through all of this. For now, this solution appears to more or less work for my needs. I'll try to clean up this PR over time. If anyone else wants to tackle getting the tests cleaned up and uncovering any other potential issues feel free to work on the branch. If you do, please note you'll have to use your own username/pass to rerecord the VCR's - DO NOT commit anything until you're confident you've scrubbed the tests and VCR's of this info, replacing with the |
icloudpd: Refactor: 2SA prompt requires device selection to send code icloudpd: Feat: New --auth-only flag to trigger log in, 2SA/2FA, and set session/cookie file. Future log in will validate the tokens without running through full signin flow. Can be used to validate the session tokens are still good without having to ping the photo endpoints. pyicloud_ipd: Clean: Removed unused imports pyicloud_ipd: Fix: Capture additional header data pyicloud_ipd: Fix: Invalid Username/Password correctly caught now pyicloud_ipd: Fix: Changes in certain error responses now captured pyicloud_ipd: Fix: Bypass 2sv/trust when using 2SA Tests: Refactored authentication tests Tests: Refactored two_step_auth tests (TODO: Add 2FA tests) Tests: Updated/Created additional VCRs for auth tests
pyicloud_ipd: Fix: Correct exception reference for API and NoStoredPassword errors Tests: Refactor: All remaining tests now pass Tests: Refactor: Update corresponding VCRs for new auth flow Tests: Cookie/Session files stored in individual test fixtures for running tests independently
icloudpd: Style: Format update (scripts/format)
docs: Update CHANGELOG.md and README.md
Tests updated with 100% passing. Code coverage at 99% (matching master - missing 1 line in Likely still edge cases to address as separate issues. This branch should now resolve the core |
@scaraebeus |
87d3394
into
icloud-photos-downloader:master
Potential alternative fix for recent auth issue #729.
As in PR #733 - I have not followed all guidelines at this time aside from format and lint.
Purpose
Attempted minimal approach to merge strictly the authentication flow from the 1.0.0
pyicloud
release. TheAUTH_ENDPOINT
appears to be the missing piece in the currentpyicloud_ipd
release.This PR also attempts to retain the
DOMAIN
andLIBRARY
features implemented in thepyicloud_ipd
fork.Summary
pyicloud/base.py
topyicloud_ipd/base.py
utils.py
andexceptions.py
to merge changes needed in updated auth codeicloudpd/authentication.py
to take advantage of 2FATODO
scripts/test
- majority are failing - likely outdated/broken?CHANGELOG.md
if this is deemed an appropriate path to resolutionDOMAIN
functionality forCN
is retainedbase.py
importsexceptions.py