Update to quickstart SSO w/ python & MSAL for anyone using FastAPI instead of Flask
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 3/5
- Geschätzter Aufwand
- 1-2 Tage
- Anfängerfreundlichkeit
- 35/100
- Issue-Typ
- Dokumentation
- Klarheit
- Größtenteils klar
- Aktivitätsstatus
- Veraltet
- Bereich
- authentication, documentation
Rechercherichtung
The issue links to the FastAPI authentication demo repository and the Microsoft Python web app quickstart. Read both to compare the FastAPI example with the Flask quickstart, including its port and callback URL setup. Done means the quickstart offers a clear FastAPI reference for signing in with Microsoft and calling the Graph API.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
New way to use another framework to Add sign-in with Microsoft to a Python web app.
Note: This is a very simple demo - to keep it easy to understand for anyone getting started.
Reason i posted this is that a good friend was having some issues following the getting started with Azure SSO & Flask since the example is in flask only. Thus, I borrowed the flask demo referenced from the quick start guide here. The repo handles redirect to SSO, azure auth, and redirect back to the callback url which eventually gets the JWT(s), and allows you to make calls to the graph api. There are some subtle nuances and conversion is not as easy as one would think, so i wanted to post this in case anyone is looking or a super simple reference repository for doing the same thing from the original guide, but with a really awesome concurrent python library. You get checkout FastAPI here.
The repository demo can be found at https://github.com/AndrewJHart/Azure-FastAPI-Auth-Example
The link to the original guide is below. You will need to follow the guide to get started and create your web app. The only
difference in the setup steps is that the repo i'm sharing runs on port 9000 and the cb url is/oauthinstead of port 5000
and cb beinggetAToken(all of which is configurable). The project layouts are almost identical as well.
This will work in a multi-tenant situation as well. I hope this is helpful. Thanks!
Perhaps it would behoove Azure to use this or a similar example to demonstrate how to do something similar without requiring Flask or Django.
Thanks very much,
- Vorherrschende Sprache
- Python
- Sterne
- 971
- Forks
- 223
- Ø Merge
- 13 Std. 48 Min.
- Gemergte PRs (30 T.)
- 2
Entwicklungsumgebung
- Kein Dockerfile und keine Docker-Compose-Datei
- Keine Pull-Request-Vorlage
- Beitragsleitfaden lesen
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus AzureAD/microsoft-authentication-library-for-python
-
needs attention untriaged
Schwierigkeit 4/5 3-5 Tage Anfängerfreundlichkeit 48/100
-
AzureSDK bug P1
Schwierigkeit 4/5 3-5 Tage Anfängerfreundlichkeit 48/100
-
http_client docstring does not say that timeout, verify and proxies only configure the default sessionEvtl. vergeben @HardMax71 hat das vor 39 Tagen übernommen. Offen
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 25/100
-
[Bug] The built-in retry never retries the token POST: HTTPAdapter(max_retries=1) keeps urllib3's default allowed_methodsEvtl. vergeben @HardMax71 hat das vor 46 Tagen übernommen. Offenbug untriaged
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 35/100
AzureAD/microsoft-authentication-library-for-python#957 · 3 Kommentare ·
-
public-client untriaged
Schwierigkeit 5/5 Über eine Woche Anfängerfreundlichkeit 25/100
Alle Issues in AzureAD/microsoft-authentication-library-for-python
Ähnliche Issues
-
wr.dynamodb.read_items returns [{}] for a single partition value that does not existEvtl. vergeben @auraseb hat das heute übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 84/100
aws/aws-sdk-pandas#3520 ·
Maintainer antworten meist innerhalb von 2 Tagen
-
requires triage typing
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
sqlalchemy/sqlalchemy#13704 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Edit tool converts CRLF files to LFEvtl. vergeben @RaphaelFakhri hat das heute übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 68/100
huggingface/tau#774 ·
Maintainer antworten meist innerhalb von 1 Tag
-
show ignores the row limit when a column or table name contains "limit"Evtl. vergeben @RaphaelFakhri hat das heute übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 88/100
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 67/100
linebender/resvg#1179 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 2 Tagen