[GH-ISSUE #242] [BUG] Redirecting "Open in App" URL schemes for login purposes #219

Open
opened 2026-03-03 15:31:44 +03:00 by kerem · 18 comments
Owner

Originally created by @Software-Cat on GitHub (Dec 6, 2024).
Original GitHub issue: https://github.com/LiveContainer/LiveContainer/issues/242

Describe the bug

The login process for certain apps requires opening a website in the browser, then using the "Open in App" functionality to send the auth token to the app.

For instance, to log in to Winston for Reddit, you must perform some steps in the app, then open a website in the browser https://app.winston.cafe/auth-success?state=EXAMPLE_STATE&code=EXAMPLE_CODE, then click the "Jump to Winston" link, upon which the auth token is sent to the app.

Screenshot 2024-12-07 002800
<a href="winstonapp://auth-success?state=EXAMPLE_STATE&code=EXAMPLE_CODE"></a>

Here, the link has a special href beginning with winstonapp://, meaning it attempts to open Winston directly, not Winston in live container.

In an attempt to fix this, I ran a Nginx server hosting a link but with winstonapp:// replaced with livecontainer://. Upon clicking the link, I was indeed prompted to "Open in Livecontainer", however, the auth token did not get sent through to Winston running in livecontainer, thus making the app impossible to login.

Instructions to reproduce

  1. Install Winston for Reddit to livecontainer
  2. Follow the Reddit API app creation process
  3. Be prompted to "Authenticate", which links you to app.winston.cafe.
  4. TEST1: Directly clicking "Jump to Winston" does not work.
  5. Inspect the "Jump to Winston" element to determine its href
  6. Run a server hosting the link but replace winstonapp -> livecontainer
  7. TEST2: Click the link and observe that "Open in Livecontainer" works, BUT it still does not login

What version of LiveContainer are you using?

3.1.0-release (main/7b23e9e)

Other info

Related Issue: https://github.com/khanhduytran0/LiveContainer/issues/162

Originally created by @Software-Cat on GitHub (Dec 6, 2024). Original GitHub issue: https://github.com/LiveContainer/LiveContainer/issues/242 ### Describe the bug The login process for certain apps requires opening a website in the browser, then using the "Open in App" functionality to send the auth token to the app. For instance, to log in to [Winston for Reddit](https://winston.cafe/), you must perform some steps in the app, then open a website in the browser https://app.winston.cafe/auth-success?state=EXAMPLE_STATE&code=EXAMPLE_CODE, then click the "Jump to Winston" link, upon which the auth token is sent to the app. <img width="193" alt="Screenshot 2024-12-07 002800" src="https://github.com/user-attachments/assets/0c0788cd-584f-4ef7-b851-32225666e4c4"> ```html <a href="winstonapp://auth-success?state=EXAMPLE_STATE&code=EXAMPLE_CODE"></a> ``` Here, the link has a special href beginning with `winstonapp://`, meaning it attempts to open Winston directly, not Winston in live container. In an attempt to fix this, I ran a Nginx server hosting a link but with `winstonapp://` replaced with `livecontainer://`. Upon clicking the link, I was indeed prompted to "Open in Livecontainer", however, the auth token did not get sent through to Winston running in livecontainer, thus making the app impossible to login. ### Instructions to reproduce 1. Install [Winston for Reddit](https://winston.cafe/) to livecontainer 2. Follow the Reddit API app creation process 3. Be prompted to "Authenticate", which links you to app.winston.cafe. 5. **TEST1:** Directly clicking "Jump to Winston" does not work. 6. Inspect the "Jump to Winston" element to determine its href 7. Run a server hosting the link but replace winstonapp -> livecontainer 8. **TEST2:** Click the link and observe that "Open in Livecontainer" works, BUT it still does not login ### What version of LiveContainer are you using? 3.1.0-release (main/7b23e9e) ### Other info Related Issue: https://github.com/khanhduytran0/LiveContainer/issues/162
Author
Owner

@hugeBlack commented on GitHub (Dec 7, 2024):

There's a link button on the top right corner of LiveContainer so you can use that to open your login url scheme

<!-- gh-comment-id:2524844548 --> @hugeBlack commented on GitHub (Dec 7, 2024): There's a link button on the top right corner of LiveContainer so you can use that to open your login url scheme
Author
Owner

@Software-Cat commented on GitHub (Dec 7, 2024):

Thanks for your help!

Just attempted it. Winston opens correctly but after that in-app safari opens automatically and navigates to https://auth-success/?state=…&code=… A nonexistent website.

I have not personally seen any other app using this login method so probably low priority for now. Really excited by some of the updates coming out for 3.1

<!-- gh-comment-id:2525178001 --> @Software-Cat commented on GitHub (Dec 7, 2024): Thanks for your help! Just attempted it. Winston opens correctly but after that in-app safari opens automatically and navigates to https://auth-success/?state=…&code=… A nonexistent website. I have not personally seen any other app using this login method so probably low priority for now. Really excited by some of the updates coming out for 3.1
Author
Owner

@hugeBlack commented on GitHub (Dec 7, 2024):

In 3.1.0 I made some changes to how "open in app", you can have a try. I didn't do before this because I think extracting url schemes from Safari is quite difficult to preform on-device.

  1. open the app and try to login
  2. finish the login
  3. construct live container's "open in app" url scheme with reference to this shortcut: https://www.icloud.com/shortcuts/44ea82ce7ed8469ea24198c375db09a0
  4. Open the constructed url scheme (leave the app open) and see if login completes
<!-- gh-comment-id:2525186763 --> @hugeBlack commented on GitHub (Dec 7, 2024): In 3.1.0 I made some changes to how "open in app", you can have a try. I didn't do before this because I think extracting url schemes from Safari is quite difficult to preform on-device. 1. open the app and try to login 2. finish the login 3. construct live container's "open in app" url scheme with reference to this shortcut: https://www.icloud.com/shortcuts/44ea82ce7ed8469ea24198c375db09a0 4. Open the constructed url scheme (leave the app open) and see if login completes
Author
Owner

@Mspy1 commented on GitHub (Dec 9, 2024):

I tried to replicate this for Regram authentication, however. Pressing login on the regram website tries to redirect you to official instagram app. I tried to redirect it to Livecontainer with the shortcut but no luck. Deleting instagram results in app throwing ‘’Safari cannot open this app because the adress is invalid”.

<!-- gh-comment-id:2526568779 --> @Mspy1 commented on GitHub (Dec 9, 2024): I tried to replicate this for Regram authentication, however. Pressing login on the regram website tries to redirect you to official instagram app. I tried to redirect it to Livecontainer with the shortcut but no luck. Deleting instagram results in app throwing ‘’Safari cannot open this app because the adress is invalid”.
Author
Owner

@hugeBlack commented on GitHub (Dec 9, 2024):

you should send the url scheme you extracted to the shortcut, not the website. We cannot intercept url schemes (the thing redirects you to the official app) inside safari.

If you don't know how to extract, try another way of login.

<!-- gh-comment-id:2526610163 --> @hugeBlack commented on GitHub (Dec 9, 2024): you should send the url scheme you extracted to the shortcut, not the website. We cannot intercept url schemes (the thing redirects you to the official app) inside safari. If you don't know how to extract, try another way of login.
Author
Owner

@Mspy1 commented on GitHub (Dec 9, 2024):

I only changed href to redirect the app authentication to LiveContainer instead of the Instagram app. But it did not work as the app doesn’t see it. Also, I think I might not know how to do it properly. Thanks for the long reply anyway.

<!-- gh-comment-id:2527205128 --> @Mspy1 commented on GitHub (Dec 9, 2024): I only changed href to redirect the app authentication to LiveContainer instead of the Instagram app. But it did not work as the app doesn’t see it. Also, I think I might not know how to do it properly. Thanks for the long reply anyway.
Author
Owner

@hugeBlack commented on GitHub (Dec 9, 2024):

@Mspy1 Alright, it seems you didn't get my point. Let me give you an example:

  1. Finish login in safari.
  2. You extract your url scheme and it may look like this: instagram://login=xxxxx
  3. Base64 encode it, it now becomes this: aW5zdGFncmFtOi8vbG9naW49eHh4eHg=
  4. Construct live container's "open in app" url : livecontainer://open-url?url=aW5zdGFncmFtOi8vbG9naW49eHh4eHg=
  5. Open this url in safari and it will jump to LiveContainer. LiveContainer then convert the url back to original one and send it to Instagram.
<!-- gh-comment-id:2527233730 --> @hugeBlack commented on GitHub (Dec 9, 2024): @Mspy1 Alright, it seems you didn't get my point. Let me give you an example: 1. Finish login in safari. 2. You extract your url scheme and it may look like this: `instagram://login=xxxxx` 3. Base64 encode it, it now becomes this: `aW5zdGFncmFtOi8vbG9naW49eHh4eHg=` 4. Construct live container's "open in app" url : `livecontainer://open-url?url=aW5zdGFncmFtOi8vbG9naW49eHh4eHg=` 5. Open this url in safari and it will jump to LiveContainer. LiveContainer then convert the url back to original one and send it to Instagram.
Author
Owner

@Mspy1 commented on GitHub (Dec 9, 2024):

I managed to login. Thanks for the help.

<!-- gh-comment-id:2527258591 --> @Mspy1 commented on GitHub (Dec 9, 2024): I managed to login. Thanks for the help.
Author
Owner

@michael1900 commented on GitHub (Dec 10, 2024):

I managed to login. Thanks for the help.

What procedure did you use to extract the url scheme? Thanks

<!-- gh-comment-id:2529909971 --> @michael1900 commented on GitHub (Dec 10, 2024): > I managed to login. Thanks for the help. What procedure did you use to extract the url scheme? Thanks
Author
Owner

@Software-Cat commented on GitHub (Dec 10, 2024):

I managed to login. Thanks for the help.

Regram login was very inconsistent for me.

  • Using "Open in Livecontainer" Shortcut with livecontainer://open-url?url=...
    • nothing happens
  • Using "Open in Livecontainer" Shortcut with livecontainer://open-web-page?url=...
    • nothing happens for both keep current app open and close current app
  • Closing Regram, using the link icon on top right corner.
    • WORKS

Tested on newest build at time of writing: github.com/hugeBlack/LiveContainer@386ae51841

<!-- gh-comment-id:2531736813 --> @Software-Cat commented on GitHub (Dec 10, 2024): > I managed to login. Thanks for the help. Regram login was very inconsistent for me. - Using "Open in Livecontainer" Shortcut with `livecontainer://open-url?url=...` - nothing happens - Using "Open in Livecontainer" Shortcut with `livecontainer://open-web-page?url=...` - nothing happens for both keep current app open and close current app - Closing Regram, using the link icon on top right corner. - **WORKS** Tested on newest build at time of writing: https://github.com/hugeBlack/LiveContainer/commit/386ae51841550930f6ac10d29cfae08bd06ac944
Author
Owner

@Software-Cat commented on GitHub (Dec 10, 2024):

What procedure did you use to extract the url scheme? Thanks

Procedure for Brave Browser iOS:

  1. Make sure the sideloaded app only exists in livecontainer and is not sideloaded normally
  2. Begin login from app, in app safari will open
  3. Click the safari icon on top right corner of in-app safari to open the same web page but in your default browser (Brave)
  4. Complete login from web page in brave
  5. Brave asks you whether to switch apps, click Allow.
  6. Since the app doesn't actually exist, brave opens a new page using the URL schema instead, because it assumes the URL schema is a website.
  7. Copy the schema from the URL box.

1663569267-529050-c00a43c3-5b4e-4710-aaab-ae8200f88652

<!-- gh-comment-id:2531751322 --> @Software-Cat commented on GitHub (Dec 10, 2024): > What procedure did you use to extract the url scheme? Thanks Procedure for Brave Browser iOS: 1. Make sure the sideloaded app only exists in livecontainer and is not sideloaded normally 2. Begin login from app, in app safari will open 3. Click the safari icon on top right corner of in-app safari to open the same web page but in your default browser (Brave) 4. Complete login from web page in brave 5. Brave asks you whether to switch apps, click Allow. 6. Since the app doesn't actually exist, brave opens a new page using the URL schema instead, because it assumes the URL schema is a website. 7. Copy the schema from the URL box. ![1663569267-529050-c00a43c3-5b4e-4710-aaab-ae8200f88652](https://github.com/user-attachments/assets/5ee167c6-a9c8-4950-8d5f-206e7e0db405)
Author
Owner

@dnfanjos commented on GitHub (Dec 16, 2024):

I tried all of these methods with Dragalia Lost (Private Server) and could not do anything
It uses the pop-up window login instead of a browser and only allow login whilst that popup window is open
Trying to log in using another browser, or getting the schema and using the link button does not work and just opens the app as normal.
Thankfully the game is playable without an account, but it would be cool to sync my progress (and there must be games out there that require login)

<!-- gh-comment-id:2545503828 --> @dnfanjos commented on GitHub (Dec 16, 2024): I tried all of these methods with Dragalia Lost (Private Server) and could not do anything It uses the pop-up window login instead of a browser and only allow login whilst that popup window is open Trying to log in using another browser, or getting the schema and using the link button does not work and just opens the app as normal. Thankfully the game is playable without an account, but it would be cool to sync my progress (and there must be games out there that require login)
Author
Owner

@Impure2411 commented on GitHub (Jan 1, 2025):

@Mspy1 Alright, it seems you didn't get my point. Let me give you an example:

  1. Finish login in safari.
  2. You extract your url scheme and it may look like this: instagram://login=xxxxx
  3. Base64 encode it, it now becomes this: aW5zdGFncmFtOi8vbG9naW49eHh4eHg=
  4. Construct live container's "open in app" url : livecontainer://open-url?url=aW5zdGFncmFtOi8vbG9naW49eHh4eHg=
  5. Open this url in safari and it will jump to LiveContainer. LiveContainer then convert the url back to original one and send it to Instagram.

Thanks, it works for Winston.

  1. Choose Advanced
  2. Follow instructions
  3. Extract "auth-success?state=EXAMPLE_STATE&code=EXAMPLE_CODE" part from the url and add "winstonapp://" before it (winstonapp://auth-success?state=EXAMPLE_STATE&code=EXAMPLE_CODE)
  4. Encode it
  5. Add it to "livecontainer://open-url?url=" and open it in your browser
<!-- gh-comment-id:2567079335 --> @Impure2411 commented on GitHub (Jan 1, 2025): > @Mspy1 Alright, it seems you didn't get my point. Let me give you an example: > > 1. Finish login in safari. > 2. You extract your url scheme and it may look like this: `instagram://login=xxxxx` > 3. Base64 encode it, it now becomes this: `aW5zdGFncmFtOi8vbG9naW49eHh4eHg=` > 4. Construct live container's "open in app" url : `livecontainer://open-url?url=aW5zdGFncmFtOi8vbG9naW49eHh4eHg=` > 5. Open this url in safari and it will jump to LiveContainer. LiveContainer then convert the url back to original one and send it to Instagram. Thanks, it works for Winston. 1. Choose Advanced 2. Follow instructions 3. Extract "auth-success?state=EXAMPLE_STATE&code=EXAMPLE_CODE" part from the url and add "winstonapp://" before it (winstonapp://auth-success?state=EXAMPLE_STATE&code=EXAMPLE_CODE) 4. Encode it 5. Add it to "livecontainer://open-url?url=" and open it in your browser
Author
Owner

@mateusrez commented on GitHub (May 29, 2025):

I’m having the same issue with Abode Lightroom app. How can I make “https://auth.services.adobe.com/…“ redirect me to the app loaded in LiveContainer

<!-- gh-comment-id:2919716559 --> @mateusrez commented on GitHub (May 29, 2025): I’m having the same issue with Abode Lightroom app. How can I make “https://auth.services.adobe.com/…“ redirect me to the app loaded in LiveContainer
Author
Owner

@aasutossh commented on GitHub (Jul 19, 2025):

I recorded a video if anyone is feeling hard. No audio or text overlays. I hope it’s helpful. Sorry about the keyboard noise.
https://youtu.be/acfpdXPCfaE?feature=shared

<!-- gh-comment-id:3091363890 --> @aasutossh commented on GitHub (Jul 19, 2025): I recorded a video if anyone is feeling hard. No audio or text overlays. I hope it’s helpful. Sorry about the keyboard noise. https://youtu.be/acfpdXPCfaE?feature=shared
Author
Owner

@Charliefr3sh commented on GitHub (Sep 6, 2025):

Can some try and login to AutoCAD

<!-- gh-comment-id:3263283708 --> @Charliefr3sh commented on GitHub (Sep 6, 2025): Can some try and login to AutoCAD
Author
Owner

@Okabeh commented on GitHub (Sep 23, 2025):

@Mspy1 Alright, it seems you didn't get my point. Let me give you an example:

  1. Finish login in safari.
  1. You extract your url scheme and it may look like this: instagram://login=xxxxx
  1. Base64 encode it, it now becomes this: aW5zdGFncmFtOi8vbG9naW49eHh4eHg=
  1. Construct live container's "open in app" url : livecontainer://open-url?url=aW5zdGFncmFtOi8vbG9naW49eHh4eHg=
  1. Open this url in safari and it will jump to LiveContainer. LiveContainer then convert the url back to original one and send it to Instagram.

Thanks, it works for Winston.

  1. Choose Advanced

  2. Follow instructions

  3. Extract "auth-success?state=EXAMPLE_STATE&code=EXAMPLE_CODE" part from the url and add "winstonapp://" before it (winstonapp://auth-success?state=EXAMPLE_STATE&code=EXAMPLE_CODE)

  4. Encode it

  5. Add it to "livecontainer://open-url?url=" and open it in your browser

I know this is an 9 months old post but.. I tried this for Narwhal and couldn't get through it. It opens LiveContainer but nothing happens.

<!-- gh-comment-id:3324829740 --> @Okabeh commented on GitHub (Sep 23, 2025): > > @Mspy1 Alright, it seems you didn't get my point. Let me give you an example: > > > > > > 1. Finish login in safari. > > > 2. You extract your url scheme and it may look like this: `instagram://login=xxxxx` > > > 3. Base64 encode it, it now becomes this: `aW5zdGFncmFtOi8vbG9naW49eHh4eHg=` > > > 4. Construct live container's "open in app" url : `livecontainer://open-url?url=aW5zdGFncmFtOi8vbG9naW49eHh4eHg=` > > > 5. Open this url in safari and it will jump to LiveContainer. LiveContainer then convert the url back to original one and send it to Instagram. > > > > Thanks, it works for Winston. > > > > 1. Choose Advanced > > 2. Follow instructions > > 3. Extract "auth-success?state=EXAMPLE_STATE&code=EXAMPLE_CODE" part from the url and add "winstonapp://" before it (winstonapp://auth-success?state=EXAMPLE_STATE&code=EXAMPLE_CODE) > > 4. Encode it > > 5. Add it to "livecontainer://open-url?url=" and open it in your browser I know this is an 9 months old post but.. I tried this for Narwhal and couldn't get through it. It opens LiveContainer but nothing happens.
Author
Owner

@immabky commented on GitHub (Feb 18, 2026):

Can you also help me to log into the game "last day on earth"? Thank you!

<!-- gh-comment-id:3919284404 --> @immabky commented on GitHub (Feb 18, 2026): Can you also help me to log into the game "last day on earth"? Thank you!
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/LiveContainer#219
No description provided.