I trying to use Azure AD B2C to authenticate with ShinyProxy and I believe this is possible. I have tested by Azure AD B2C set via https://jwt.ms/ and another application so I think my issue does not lie on the Azure AD B2C side
==============================================================
2023-06-26 17:40:30.192 ERROR 2608 --- [XNIO-1 task-2] e.o.c.a.i.OpenIDAuthenticationBackend : org.springframework.security.oauth2.core.OAuth2AuthenticationException: [invalid_token_response] An error occurred while attempting to retrieve the OAuth 2.0 Access Token Response: Error while extracting response for type [class org.springframework.security.oauth2.core.endpoint.OAuth2AccessTokenResponse] and content type [application/json;charset=utf-8]; nested exception is org.springframework.http.converter.HttpMessageNotReadableException: An error occurred reading the OAuth 2.0 Access Token Response: tokenValue cannot be empty; nested exception is java.lang.IllegalArgumentException: tokenValue cannot be empty
2023-06-26 17:40:30.195 INFO 2608 --- [XNIO-1 task-2] io.undertow.request.dump :
----------------------------REQUEST---------------------------
My application.yml is here:
proxy:
port: 8080
authentication: openid
openid:
auth-url: https://my-tenant/B2C_1_signin_signup/oauth2/v2.0/authorize
token-url: https://my-tenant/B2C_1_signin_signup/oauth2/v2.0/token
jwks-url: https://my-tenant/B2C_1_signin_signup/discovery/v2.0/keys
client-id: 53.....
client-secret: 5sH....
docker:
url: http://localhost:2375
specs:
- id: 01_hello
display-name: Hello Application
description: Application which demonstrates the basics of a Shiny app
container-cmd: ["R", "-e", "shinyproxy::run_01_hello()"]
container-image: openanalytics/shinyproxy-demo
- id: 06_tabsets
container-cmd: ["R", "-e", "shinyproxy::run_06_tabsets()"]
container-image: openanalytics/shinyproxy-demo
logging:
requestdump: true
file:
name: shinyproxy.log
Given my lack of familiarity with springframework or Spring Boot, I would appreciate confirmation, to the extent that it is possible, that the error suggests a problem either with shinyproxy/springframework or an incompatibility between shinyproxy and Azure AD B2C. I am trying to determine if the issue lies with the configuration of the Azure AD B2C tenant or a problem within the application.yml file.
If anyone has experience in this area and could provide suggestions for a potential workaround, it would be greatly appreciated.