question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Can't connect to app from iOS device using Basic Authentication

See original GitHub issue

Summary

I launched streamlit app by using ngrok. Almost device (like windows, mac, Android) can access to the app through ngrok link, but iOS device (iPhone & iPad) cannot access it. ( Freeze with text “Please wait …”. )

Steps to reproduce

  1. Run streamlit hello
  2. Access to ngrok link from iOS device

Expected behavior:

Access the hello-example in the browser on iOS device.

Actual behavior:

Freeze with text “Please wait …”. IMG_0025

Is this a regression?

no

Debug info

  • Streamlit version: 0.69.1
  • Python version: 3.8.5
  • Using Conda
  • OS version: iPadOS 14.4 , Windows 10 (server)
  • Browser version: chrome, safari

Additional information

I tried to setup config.toml like below, but it doesn’t work.

[server]
enableCORS = false
enableXsrfProtection = false

If I don’t set enableXsrfProtection = false, enableCORS is overwrited into true. reference : #443

Issue Analytics

  • State:open
  • Created 3 years ago
  • Reactions:2
  • Comments:11

github_iconTop GitHub Comments

3reactions
kmcgradycommented, Mar 28, 2021

Thanks for the response @raijin0704 That was really helpful. I see the issue when using the auth feature. This implements a Basic Authentication method on the http website.

Safari unfortunately does not forward the basic auth to the web socket connection. This can be confirmed that Safari doesn’t work, but it works on Chrome on macOS.

Reading https://stackoverflow.com/a/4361358 it seems that this may be more intentional in an attempt to deprecate Basic Authentication being very insecure. There might be a solution where we make a pretend request, observe the Auth Header sent, decode it, and connect to the web socket properly. Given the pain of the implementation for a very specific situation and the motivation of trying to discourage Basic Authentication, this is probably low in priority. I’ll leave this issue open in case we see more use cases pop up.

2reactions
jucorcommented, Apr 21, 2021

Hit the same problem here with both chrome and safari on iPadOS, stream lit 0.8.0 behind reverse proxy on nginx with basic auth. Works like a charm on macOS, on Windows, and on android. Seems that iPadOS network stack is the problem — even With chrome.

is there a workaround please? Some of my users use iPads and iPhones. Thanks for any idea!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Using Basic authentication with Outlook for iOS and Android
The Outlook app for iOS and Android is designed to bring together email, calendar, contacts, and other files, enabling users in your ...
Read more >
Two-factor authentication for Apple ID
Two-factor authentication is designed to make sure that you're the only person who can access your account. Learn how it works and how...
Read more >
Termination of basic auth with iOS devices using MDM - Reddit
If application passwords are being used for MFA (Multi Factor Authentication) along with basic auth as another auth mechanism, then when basic ...
Read more >
How to reconfigure Outlook on iPhone to use Modern ...
With Microsoft switching off basic authentication on Tenants, ... Changing from basic auth to modern auth connectivity on your Apple device.
Read more >
Exchange Online: Enabling Apple Mail App Clients for Modern ...
During this time all clients and apps that use Basic Auth in that tenant will be affected, and they will be unable to...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found