aws / aws/amazon-redshift-python-driver

Is`OktaCredentialsProvider.handle_saml_assertion` compatible with SageMaker instances?

Aperta
#266 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub
Lingua principale
Python
Stelle
220
Fork
86
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

I'm encountering an issue when using `redshift_connector` with Okta-based authentication inside my organisation's SageMaker environment.

In `OktaCredentialsProvider.handle_saml_assertion` I receive an error [okta_credentials_provider.py#L158](https://github.com/aws/amazon-redshift-python-driver/blob/fd81061c4dfee9ed3001be039f6b1826d8366302/redshift_connector/plugin/okta_credentials_provider.py#L158) despite receiving a 200 OK and a response of length > 2k.

Upon investigating the logs it seems to be down to a browser or Javascript issue? I've tried on both SageMaker Studio Code Editor and SageMaker Notebook instances and get the same issue.

It's also strange that `OktaCredentialsProvider.okta_authentication` works perfectly and I'm able to retrieve the `okta_session_token`, but the later step fails.

The same identical code works perfectly on my local machine.

I've attached the relevant part of the response below:

```
...



Javascript is required


Javascript is disabled on your browser. Please enable Javascript and refresh this page.


Refresh






Your OneDrive version is not supported


Upgrade now by installing the OneDrive for Business Next Generation Sync Client to login to Okta



Learn how to upgrade



Cookies are required


Cookies are disabled on your browser. Please enable Cookies and refresh this page.



Refresh




...







The page has timed out


If this page does not reload automatically, please refresh your browser.




Guida per i contributori

Apri la guida per i contributori

Direzione di ricerca

Inizia in redshift_connector/plugin/okta_credentials_provider.py, all'interno di handle_saml_assertion, in particolare alla riga 158, e confronta la gestione della risposta tra una macchina locale e SageMaker. Conferma se la risposta di SageMaker può essere gestita in modo compatibile e documenta un test riproducibile o il comportamento previsto per la correzione.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
aws, python
Ambito
authentication, databases
Tipo di issue
Bug
Difficoltà
4/5
Tempo stimato
3-5 giorni
Stato di attività
Ferma
Chiarezza
Da chiarire
Idoneità per principianti
35/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.