-
Notifications
You must be signed in to change notification settings - Fork 1
fix: remaining bug fixes and missing features #66
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||
|---|---|---|---|---|---|---|---|---|
|
|
@@ -6,12 +6,11 @@ | |||||||
| before transmission (despite OAEP references in the Dart code — confirmed by | ||||||||
| live testing that PKCS1v15 is the actual padding used). | ||||||||
|
|
||||||||
| The RSA public key is bundled in the Yarbo app APK at: | ||||||||
| The RSA public key can be obtained from the Yarbo app and placed at: | ||||||||
| ``assets/rsa_key/rsa_public_key.pem`` | ||||||||
|
|
||||||||
| References: | ||||||||
| yarbo-reversing/yarbo/auth.py — original synchronous implementation | ||||||||
| yarbo-reversing/docs/API_ENDPOINTS.md — endpoint documentation | ||||||||
| Protocol documentation (API endpoint reference) | ||||||||
| """ | ||||||||
|
|
||||||||
| from __future__ import annotations | ||||||||
|
|
@@ -45,7 +44,7 @@ class YarboAuth: | |||||||
| base_url: REST API gateway base URL. | ||||||||
| username: User email address. | ||||||||
| password: Plaintext password (encrypted before transmission). | ||||||||
| rsa_key_path: Path to the RSA public key PEM extracted from the APK. | ||||||||
| rsa_key_path: Path to the RSA public key PEM. | ||||||||
| If not provided, falls back to the vendored key in the | ||||||||
| package (if available). | ||||||||
| session: Existing ``aiohttp.ClientSession`` to reuse. | ||||||||
|
|
@@ -83,7 +82,7 @@ def _default_key_path() -> Path: | |||||||
| .. warning:: | ||||||||
| The vendored key at ``src/yarbo/keys/rsa_public_key.pem`` is a | ||||||||
| **placeholder** — cloud auth will fail until it is replaced with | ||||||||
| the real key extracted from the Yarbo APK. | ||||||||
| the real key (see keys/README.md for instructions). | ||||||||
|
|
||||||||
| See ``src/yarbo/keys/README.md`` for extraction instructions, or | ||||||||
| supply the real key path via ``rsa_key_path`` at construction time. | ||||||||
|
|
@@ -181,7 +180,7 @@ def _load_public_key(self) -> object: | |||||||
| except FileNotFoundError as exc: | ||||||||
| raise YarboAuthError( | ||||||||
| f"RSA public key not found at {self._key_path}. " | ||||||||
| "Extract it from the Yarbo APK: assets/rsa_key/rsa_public_key.pem" | ||||||||
| "Obtain the key and place it at: assets/rsa_key/rsa_public_key.pem" | ||||||||
|
||||||||
| "Obtain the key and place it at: assets/rsa_key/rsa_public_key.pem" | |
| "Ensure the key exists on disk (default: src/yarbo/keys/rsa_public_key.pem) " | |
| "and see src/yarbo/keys/README.md for setup instructions." |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The module docstring says the RSA public key can be “placed at
assets/rsa_key/rsa_public_key.pem”, but that path is inside the APK; this library actually looks for the vendored key atsrc/yarbo/keys/rsa_public_key.pem(or a user-suppliedrsa_key_path). Reword this to clarify where the key is found in the app package vs where users should place it for this library.