8000 🐛 Bug Report: Invalid argument (callbackUrlScheme): must be a valid URL scheme: "appwrite-callback-<project_id>" · Issue #5794 · appwrite/appwrite · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
8000

🐛 Bug Report: Invalid argument (callbackUrlScheme): must be a valid URL scheme: "appwrite-callback-<project_id>" #5794

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

Closed
2 tasks done
bhagn opened this issue Jul 10, 2023 · 6 comments
Labels
bug Something isn't working

Comments

@bhagn
Copy link
bhagn commented Jul 10, 2023

👟 Reproduction steps

Create a project with identifier that contains upper case characters - ex: MyProject, the web oauth login fails in flutter. There's a FluuterWebAuth2._assertCallbackScheme that validates the callback scheme against this regex:

static final RegExp _schemeRegExp = RegExp(r'^[a-z][a-z\d+.-]*$');

👍 Expected behavior

Appwrite console should validate and prevent users from creating invalid project identifiers.

👎 Actual Behavior

Appwrite console allows any value for a Project Id

🎲 Appwrite version

Appwrite Cloud

💻 Operating system

Linux

🧱 Your Environment

No response

👀 Have you spent some time to check if this issue has been raised before?

  • I checked and didn't find similar issue

🏢 Have you read the Code of Conduct?

@bhagn bhagn added the bug Something isn't working label Jul 10, 2023
@byawitz
Copy link
Member
byawitz commented Jul 10, 2023

It seems like Appwrite ID are case-insensitive so you can try to just rename your project to all lower-case in your project files, you can read more details here.

Also, track this issue #5670

@Haimantika
Copy link
Contributor

Thanks for raising this issue @bhagn, our team will look into it. Did you also try renaming as suggested by @byawitz ?

@bhagn
Copy link
Author
bhagn commented Jul 10, 2023

@Haimantika Thanks. Yes, I tried using the same id in lower case and it works.

@Haimantika
Copy link
Contributor

@Haimantika Thanks. Yes, I tried using the same id in lower case and it works.

Great to know that! Can I go ahead and close this issue then?

@bhagn
Copy link
Author
bhagn commented Jul 14, 2023

@Haimantika Yes, please.

@stnguyen90 stnguyen90 closed this as not planned Won't fix, can't repro, duplicate, stale Jul 19, 2023
@bhagn
Copy link
Author
bhagn commented Aug 9, 2023

@Haimantika I think this issue needs to be re-opened - as the work-around is not a solution. (works only on web).
This creates issues with mobile app oauth - where we set CFBundleURLSchemes to appwrite-callback-[PROJECT_ID]. Account.get() will always return 401. There needs to be a validation to check that users are not overriding the project ID with invalid characters.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants
0