jhtimmins commented on a change in pull request #10594:
URL: https://github.com/apache/airflow/pull/10594#discussion_r481490675
##########
File path: airflow/api_connexion/security.py
##########
@@ -37,3 +37,32 @@ def decorated(*args, **kwargs):
return function(*args, **kwargs)
return cast(T, decorated)
+
+
+def requires_access(permissions: Sequence[Tuple[str, str]]) -> Callable[[T],
T]:
Review comment:
@houqp we do that, but there are times when authentication is needed,
but we don't tie it to a specific permission. Such as the Health and Configs
endpoints. We could add a semi-arbitrary permission for those cases
(`('Health', 'can_read')`), or similar with reading configs. Or we could allow
`requires_access()` to work without any permissions, in which case it only
requires authentication.
What do you think? @mik-laj curious about your thoughts as well.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]