update demo/oauth2-azure.r to oauth2/v2.0
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 65/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Stale
- Tech stack
- r
- Domain
- authentication
Research direction
Start with demo/oauth2-azure.r and inspect the Azure endpoint examples around the referenced lines. Then trace httr::oauth_endpoints("azure") to find where its endpoint values are defined. Done means the demo uses the /oauth2/v2.0/authorize and /oauth2/v2.0/token URLs and the Azure helper no longer returns the legacy endpoints.
Written by the indexing model from the issue text.
Description
In the azure demo, it suggests using a legacy endpoint.
https://github.com/r-lib/httr/blob/df11e216f5e1a30f1bc8df8118e7cd983d9066f9/demo/oauth2-azure.r#L18-L24
It needs to be updated to the below, as outlined in Microsoft guide https://learn.microsoft.com/en-us/entra/identity-platform/v2-oauth2-auth-code-flow
endpoint <- httr::oauth_endpoint(
authorize = sprintf("https://login.windows.net/%s/oauth2/v2.0/authorize", tenant_id), # changed here by adding /v2.0/
access = sprintf("https://login.windows.net/%s/oauth2/v2.0/token", tenant_id))
In addition httr::oauth_endpoints("azure") gives "https://login.windows.net/common/oauth2/authorize", which is no longer supported since 2018 I believe.
I can confirm this change is required.
- Dominant language
- R
- Stars
- 981
- Forks
- 2k
- PR merge metrics
- No merged PRs in 30d
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from r-lib/httr
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
Release httr 1.4.8 Open
Difficulty 1/5 Under an hour Newbie friendliness 45/100
-
httr::set_config(config(ssl_verifypeer = 0L, ssl_verifyhost = 0L)) is empty for older curl version Open
Difficulty 3/5 1-2 days Newbie friendliness 35/100
-
Difficulty 3/5 1-2 days Newbie friendliness 45/100
-
Difficulty 3/5 1-2 days Newbie friendliness 35/100
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
r-lib/pkgdepends#485 · 3 comments ·
-
Difficulty 1/5 Under an hour Newbie friendliness 92/100
-
beginners blocker
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
enviPathR OpenBuild Error Build OK Build Warning policies-accepted pre-review precheck-passed
Difficulty 1/5 Under an hour Newbie friendliness 84/100
Bioconductor/BiocContributions#207 · 6 comments ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
datacarpentry/semester-biology#1255 ·