Skip to content

[19.0][FIX] webservice: authorization URL and scope required for the web application flow - #199

Closed
parabol123654 wants to merge 1 commit into
OCA:19.0from
parabol123654:19.0-fix-webservice-web-application-required
Closed

parabol123654 wants to merge 1 commit into
OCA:19.0from
parabol123654:19.0-fix-webservice-web-application-required

Conversation

@parabol123654

Copy link
Copy Markdown

Forward port of #197 (merged on 18.0).

In webservice/views/webservice_backend.xml, the required attribute of oauth2_scope and oauth2_authorization_url checks oauth2_flow == 'authorization_code'. That value does not exist: the selection values are backend_application and web_application. As a result, the two fields are never required, although the authorization redirect needs them. The fix uses 'web_application'.

Test: test_web_application_required_fields_with_ui, the same test as in #197. It fails without the fix on 18.0. I could not run it locally on 19.0 (no test environment on this machine right now); CI runs it here.

@OCA-git-bot

Copy link
Copy Markdown
Contributor

Hi @etobella,
some modules you are maintaining are being modified, check this out!

…plication flow

The required condition of the authorization URL and the scope used the
flow value 'authorization_code', which does not exist (the value is
'web_application'), so they were never required although the
authorization redirect needs them.

Forward port of OCA#197.
@parabol123654
parabol123654 force-pushed the 19.0-fix-webservice-web-application-required branch from 3b63b64 to c836596 Compare November 3, 2026 18:16
@OCA-git-bot OCA-git-bot added the mod:webservice_server_env Module webservice_server_env label Nov 3, 2026
@MiquelRForgeFlow

Copy link
Copy Markdown

@parabol123654 I think the forward port in #198 it's better, because I put the test in webservice_server_env (because the web dependency).

@parabol123654

Copy link
Copy Markdown
Author

Agreed, #198 forward-ports the same fix together with the other commits, so I'm closing this one in favour of it. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

mod:webservice_server_env Module webservice_server_env mod:webservice Module webservice series:19.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants